We are maintaining a large website based on Lotus Notes, running on Domino Server 8.5.3. Recently we have been fed up with the lack of source control in our project, so we thought we would try to Git things up a little. But how to do this right?
For various reasons that I will not get into here, we cannot run our applications locally on the development PCs. We can only run them on the development, staging and production servers. (Local Domino server running on the development PCs is not an option, unfortunately.)
This figure illustrates the current situation:
In production (and staging) there are multiple web sites that all have the same functionality. They are basically the same site with the same design, but with different content. Each site consists of a number of Notes databases (News, Archive, Discussion etc). The design of these databases is the same for all sites, so they all inherit their design from the same set of master templates (NewsTemplate, ArchiveTemplate, DiscussionTemplate etc).
A set of replicas of the master templates resides on the Development server. When we deploy new functionality, the required code changes are added to the templates on the Dev. server (more details on this below). Then these templates are replicated to the Staging server for testing, and finally to the production server. This part works quite well.
The problems may be found in the lower part of the figure. We are currently two developers, and we both work in the same set of dev. databases (News, Archive, Discussion etc) on the dev. server. Naturally we keep tripping over each others' work, which is quite frustrating. When it is time to deploy, the code that is to be deployed is selectively copied/pasted from the set of dev. databases to the dev. templates. This is done manually, and thus the risk of mistakes is high. We cannot simply replace the design of the templates with that of the dev. databases, because the dev. databases at all times contain code that is under development. So we must take great care to only deploy code that is "finished". Also, we have no history of changes. This is a horrible, horrible, horrible (add as many horribles as you see fit) way to do software development, and we know it.
Now, using Git, local replicas, database copies or whatnot, what would be the best way to achieve a more streamlined development and deployment scheme?