mirror of
https://github.com/DanielnetoDotCom/YouPHPTube
synced 2025-10-03 09:49:28 +02:00
15 lines
389 B
PHP
15 lines
389 B
PHP
<?php
|
|
//streamer config
|
|
require_once '../videos/configuration.php';
|
|
|
|
if (!isCommandLineInterface()) {
|
|
return die('Command Line only');
|
|
}
|
|
|
|
ob_end_flush();
|
|
|
|
$file = Video::getStoragePath().'mysqldump-'.date('YmdHis').'.sql';
|
|
|
|
passthru("mysqldump --opt -u '{$mysqlUser}' -p'{$mysqlPass}' -h {$mysqlHost} {$mysqlDatabase} > {$file}");
|
|
|
|
echo PHP_EOL."Dump file created at {$file}".PHP_EOL;
|