I want to automate cloning my production WP to a testing WP install. I am good enough with Unix to get into trouble so I was hoping some guru’s can tell me if this sudo-code for a cron job is sane or not.
cp WP Production to WP Test on it’s own subdomain
sed replace database name
mysql overwrite tables on WP Test from WP Productions DB dump
Would it be better to just use the restore functionality built into DH?
Does the “Copy the backup files to /home/indolering/cpw3.dreamhosters.com_TIMESTAMP” option create another DB or would it overwrite the production database?