I am trying to bend my mind around getting silverstripe to work in a Software as a service configuration where essentially there is one set of silverstripe files, but many databases and different themes, i.e.
all share the same SS3 core files (inc mysite) but each has a different theme, asset folder and database.
The purpose is so that when we upgrade the software (i.e. our modules within mysite, etc) then we only have to do it to one location and not to 100 different locations. We can the run a batch /dev/build command to update every site.
No unfortunately not, needs to be separate DBs for a number of technical and legislation reasons.
Another thought I had, would be to make exact copies of the site (i.e. all the files, copied from a core packaged zip that gets unpacked), then have some sort of "patch" or "package~ updater that (a lot like wordpress) downloads the latest edition, unpacks it, uploads the files and runs a dev/build. Has this been done in SS?
I've not done anything like this, but we considered the SaaS approach for a previous project. The idea we had was to simply use our _ss_environment.php file to switch out which database and assets folder is being used based upon the current domain name. Something like:
$domain = getenv(DOMAIN_NAME); // 'setEnv DOMAIN_NAME www.sitex.com' in vhost config
Cool - sounds good. We will extend this to do a DB look up to get the switch statement (as there are going to be 100s of accounts) then probably store it in a session so we dont have double hit the DB everytime. Didnt even know that existed! Going to help our dev process too.