Multisite Installations in Multiple Environments
|Reported by:||wesrice||Owned by:|
Assume that there are four environments that a site needs to exist in: local, dev, uat and live.
For single sites, it is (fairly) easy to control url settings (WP_SITEURL and WP_HOME) that vary from environment to environment, based on facts about the environment obtained via $_SERVER properties. This allows for defining all environment based settings in single file that can be track via version control and pushed up through local, dev, uat and live.
However, since multisite environments ignore WP_SITEURL and WP_HOME definitions, developers have to manipulating the database when switching from environment to environment. Moreover, these changes are typically not reflected in any version control system that might be in place for the build.
I believe these site settings should be allowed to be overridden in files before checking with the database. Beefing up environment based configurations needs some love in general, but especially for multisite installations.
Before I dig into this, I'd like reassurance that this is indeed an area that is lacking and needs improvement in. Also, if there are any suggested ways of handling this, please make suggestions.