After reading the documentation, I understood that the proper way (today) to backup a ghost instance on a VPS is:
- Export JSON file
- copy the content directory
For the first one, there is two ways: using the administration interface and with ghost-cli (command line).
As I would like to do auto-backups, I would like to use the second one. But it’s interactive and so I cannot script this command:
iero@xxx:/opt/ghost$ ghost export ~/ghost_backup.json
+ sudo systemctl is-active ghost_ghost-iero-org
? **Enter your Ghost administrator email address** xxx@xxx.xx
? **Enter your Ghost administrator password** *[hidden]*
Exporting content
Is it possible to pass user/pwd in the command line ?
Or maybe bypass the autorisation for this simple ‘read’ action ?
If not possible, I will dump the database as usual. But it could be a good improvement for a future update.