Strapi mongo administration - kwantu/platformconfiguration GitHub Wiki

back

Administration of Mongodb and Strapi

Mongo backup

Make a backup of the full database to the backups directory and copy it over to the production server

mongodump -d cms -o /var/backups/mongodb/ --gzip
scp -r /var/backups/mongodb/cms [email protected]:mongodb/

Mongodb restore

To restore, we need to pass the correct parameters to overwright existing objects.

mongorestore /home/willem/mongodb/ --drop --preserveUUID --gzip