4 ms·
I put a client's site in a git repo once, but I never figured out how to safely and effectively git the database too. Kudos to VersionPress! I've only learned a
by kixpanganiban 11y ago
I put a client's site in a git repo once, but I never figured out how to safely and effectively git the database too. Kudos to VersionPress! I've only learned about them today but they seem to be doing a really solid job.
- deleted 11y ago[deleted]
- gumby 11y agoDepends how often it changes. In my case I had a db that was a small number of slowly-changing configuration records (a typical web site would probably also be similar) and a large number of log records. I just serialized it once a day and checked everything but the log records into a git repo. The log records were just saved like standard syslog records in two places. Worked fine the one time we needed to restore.
- deepnet 11y agosql's mysqldump CLI command locally or phpmyadmin > export produce a text based db backup in SQL and version that file in git. If it is a huge site split the tables into separate files but 1 file is pretty good for most medium sized clients. Git merging db's can be gnarly if changed significantly, (rollbacks are trivial). This looks very useful and GPL just like Wordpress - excellent!
- sumoboy 11y agobasically do the same with drupal also.