I work for an internet company that creates custom web-based
applications for our clients. We recently finished a product that has
shown to be very successful. In fact, it is so successful that we have
many other clients that want the exact same thing. I guess we are
slowly making a move to become an applications service provider.
We want to be able to easily manage these applications since there
will be many copies of them. So far, we have taken this 1 application
an installed it on several servers for some of our clients. This works
great because each client wants tiny modifications to meet their
needs. However, when there is a bug fix, it is becoming a pain to
patch all the different copies of code. We are also having trouble
remembering which site has which features.
So to sum it up, we need the ability to easily manage many sites that
run the same application, which may also differ in the features they
offer. We must not neglect security.
Can someone offer some suggestions in how to set up and design
something that would solve this problem? We could have all the sites
hosted on the same server, but prefer not to because these will be
high traffic sites. Same thing for the database server. I have used
CVS before in deployable projects, but it seems hard to apply to a web
application since some days we will need a new feature coded and
installed on several sites almost immediately.
Here's what I've thought of so far:
-) Keep 1 central repository and have each site pull from the code via
"include" calls. This would require all sites to be hosted on the same
server (right?). In order to differentiate between sites, we would
have blocks of code like:
if($site1) //do this
else if ($site2) //do that...
This seems like it may be slow.
-) There is 1 central repository of code and have each site have their
own local copies. Every night a site will run a script that will
access this repository, check what new features apply to them, and
install them. This seems like it may be complicated.
-) use something like CVS - can this be set up across multiple
servers? Is there any way to place versioning control on a database
structure?
My boss envisions some kind of super administration program where we
can patch bugs or copy features to the sites with the click of a
button. Sounds almost impossible to me. Is it?
FYI - production environment is Linux, PHP, Apache, MySQL. We have
many servers available for use.
Thanks so much! |