Release Management

The production website has a clone of the central FSP website git repository in /var/local/websitesrc. This repository is updated with the remote central repository during a release, and then a release is generated using git archive.

Release numbering

Major releases, containing new features, are sequentially numbered. The release branch and directory name on the production server are of the form:

release-XXX

with XXX the release number.

Minor releases, containing hotfixes for bugs, etc., are numbered as extensions of the last major release:

release-XXX.Y

with Y the sequential minor release number, starting at 1.

Release script

The release is executed using a script, /usr/local/bin/wsrelease, with a parameter indicating the release tag name (e.g. release_6-21). The release destination is /var/www/release_X-YY.

The script does the following:

  1. Takes both sites (FSP & Porcfest) offline
  2. Fetches the master branch from the repository to a local repository
  3. Exports (via git archive) the release tag specified on the command line
  4. Extracts the export into a directory named after the tag
  5. Relinks the website folder to the new release
  6. Brings the sites up again, with drush

See the release script for more information.

Preparation

  1. Document the new release at the top of the release notes in /dev/release-notes.txt, incrementing the release number appropriately.
  2. Push all local changes on the development system (master branch) to the central repository: git push
  3. Tag the release, with the next release number: git tag release_X-Y
  4. Push the tag to the central repository: git push origin --tag

Release

  1. SSH into the web server
  2. As root, run: wsrelease <release-tag> (e.g. sudo wsrelease release_6-21)

Roll-back

If an error occurred during rollout, roll back to the previous release, and clean out the partial release:

  1. If needed, link /var/www/www.freestateproject.org back to the previous release, e.g:
      cd /var/www; rm www.freestateproject.org; ln -s release_6-20 www.freestateproject.org
  2. Remove the partial release directory: rm -rf /var/www/release_6-21

Note that the release script will throw an error if a directory with the same release tag is found.

Post-release

Send a notice of the release to the fsp-it group, with a link to the release notes.