Backup your MySQL(MariaDB) to Google Drive automatically
- Initialize gdrive
$ gdrive
Go to the following link in your browser: https://accounts.google.com/o/oauth2/auth?client_id=...
Enter verification code:
- Edit config.json
$ vim config.json
- Change permission
$ chmod 777 /path/to/DBAutoBackup -R
- Add cron
$ crontab -e
# DBAutoBackup(Everyday PM 16:00)
0 16 * * * /path/to/DBAutoBackup/start.sh 1> /dev/null 2> /dev/null
$ openssl aes-256-cbc -d -in my_db.gz.enc -out my_db.gz -pass pass:09c9ea1ca79842da94df882d20887bb6
- what is "period" ?
old backup file delete period.
default is 14 days.