MyShaarli/doc/md/Backup-and-restore.md
2021-08-22 21:58:52 +08:00

571 B

Backup and restore

All data and configuration is kept in the data directory. Backup this directory:

rsync -avzP my.server.com:/var/www/shaarli.mydomain.org/data ~/backups/shaarli-data-$(date +%Y-%m-%d_%H%M)

It is strongly recommended to do periodic, automatic backups to a separate machine. You can automate the command above using a cron job or full-featured backup solutions such as rsnapshot

To restore a backup, simply put back the data/ directory in place, overwriting any existing files.