Syncing/mirroring/replicating local dev version to live server
-
This seems to be something that many people would like to do but it all seems very difficult to set up in an efficient manner.*
* Note that this is for a wordpress install that does not do any dynamic updating of the live system – no blog comments etc -that would make things very different)
I’ve got “WP Multi Network” working on my WP Dev’s iMac (see https://ww.wp.xz.cn/support/topic/cannot-get-it-to-work-on-localhost/ for some info on that).
I’ve set up so she can double click on a shell script (batch file) on the desktop, that quickly rsync’s the wordpress directory via SSH so the production server has the same directories and files as the dev machine (efficient as rsync just copies the changes, not the entire file system)
The only thing left to do now is replicating the mySQL database up to the production server.
This would be fairly simple (I think) as mySQL supports replication, where the slave (production server) reads the binary log file stored on the master (dev server) and simply plays back the changes made to the dev database, command by command, and does the same to the live DB.
The catch is, the domain names in the wordpress DB files on the dev machine are different than what they need to be for the production machine. I’ve never looked at the structure of the wordpress DB’s so have no idea how difficult this will be to change on the fly.
Ideally, a “Go live” wordpress plugin that had mappings for “dev system domain name” to “production system domain name”, that tracked the last time the DB was modified and made all the required changes to the live DB file, and rsync’d the directory structures afterward would be the way to go.
Is this do-able, or am I just banging my head against a brick wall?
The topic ‘Syncing/mirroring/replicating local dev version to live server’ is closed to new replies.