Improve Staging and SafeUpdates secondary sites reliability
Not sure if I'm missing something, but it seems that there are multiple potential serious issues that can be caused by the Staging (and SafeUpdates) process, particularly for WordPress/WooCommerce sites, which might break the Live site when pushed from the Staging/Test sites.
1) Themes/plugins that enforce license validation on a per-domain basis, may get deactivated even with the search-and-replace. This may be particularly worse when the domain changes into the cloudways domain, and may be a bit better by using a subdomain instead of the cloudways domain.
- For this, suggests to add simple options on the Cloudways console for Staging and SafeUpdates to use subdomains. E.g., staging.maindomain.com and safeupdates.maindomain.com, instead of the cloudways URL.
- And add a brief info on the required A record to add into the DNS.
- Currently it's possible at least for the Staging site, to use the Domain Management, but unclear for the SafeUpdates.
2) Perhaps a more fatal/serious issue is when there are activities such as new database records being generated on the Live site, while process is on-going on the Staging or SafeUpdates sites, which may include updates on the database. In this case, when the changes are pushed to the Live site, the database will be missing the latest data on the Live site.
- Not sure what's the best way to handle this, perhaps when it's about to be Pushed to the Live site, to take a snapshot of the Live site, temporarily lock the Live site into "maintenance mode", do a "diff" with the latest version of the Staging/SafeUpdates site, then require at least some manual review to select which of the "diff" to change on the Live site, and only make those changes (nothing more).
- Or perhaps there is a better way to do this?
Not sure if I'm missing something, but it seems that the 2 above issues could be serious enough that it may break the entire site, and it's unclear how to avoid it without some mechanisms to handle it.
Any thoughts/ideas/insights are very welcome.
Thanks!