RPMs with web applications and version control

Any large web application requires version control. Whether it is subversion or CVS, ClearCase, or some other tool, a system must be in place to manage the software changes and updates, especially if more than one person is working on the code.

The organization of the code within the version control system should reflect the anticipated deployment approach. Many web applications have varying levels of functionality. One approach is to place th core code in a single directory. This includes the foundation architecture, default language and configuration, core functionality, and shared class definitions, as well as anything else that is required to support the system. Other modules can be in separate directories, which makes it easy to build RPMs.

Thus, the core RPM is created with the core files, and the other system components require the core for installation.

Since the RPMs use tar files to get the source, and tar files are a convenient way to update the code for development, scripts that generate the tar files, then the RPMs can support both development and distribution, by updating the internal/informal and external/formal deliverables. One script can extract the latest versions of the code from version control, create tar files, make them accessible to the RPMs and build the RPMs. The same script could also copy the new RPMs to a target server, which could then install them with little effort.

This approach may be too rigid for small applications or those that will be distributed to a larger community, as tar files are more flexible.