Looking at the code: https://github.com/heybigname/backup-manager/blob/master/src/Integrations/Laravel/DbBackupCommand.php it would seem that confirmation is only asked when not all required fields are filled. You seem to be missing destinationPath Otherwise create an issue in that repo.
Damn, I see it. Now I only would like to know how to create dynamic filenames.. any idea on this?
Hmm, not really. You could off course use a bash script or something to automate this. You could also check out https://github.com/indatus/dispatcher where you can schedule cronjobs with Laravel, so I guess you could just schedule a job where you set the arguments and call the command.
Yeah totally depends on how your running the script. I use dispatcher (link above) and love it.
But if your using crontab you can always set a variable and use that. For example I use the following for my old backup script TIMESTAMP=$(date +"%F")
then call it in the generation command. See below the old script I used for usage and example;
#! /bin/bash
TIMESTAMP=$(date +"%F")
BACKUP_DIR="$HOME/mysql-backup/$TIMESTAMP"
echo "Starting backup at $TIMESTAMP"
echo ""
echo "Backup DIR: $BACKUP_DIR"
echo ""
mkdir -p "$BACKUP_DIR"
databases=$(mysql -e "SHOW DATABASES;" | grep -Ev "(Database|information_schema)")
for db in $databases; do
mysqldump --force --opt --databases $db | gzip > "$BACKUP_DIR/$db.gz"
echo "Backup created: $BACKUP_DIR/$db.gz"
done
echo "Done!"
echo ""
That should support cronjobs + that package.
I am familiar with one of the best managed service providers to backup virtual machines, databases and servers to local / mapped network drive, locally hosted backup server, or online backup server hosted in datacenter. You can run virtualized backup server instance on public cloud such as Amazon S3 so that you don't need to maintain any server and storage hardware. Check Ahsay Backup Software .
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community