The following steps should be taken when fixing a bug, committing, and pushing to production.
git clone https://github.com/UCSC-MedBook/MedBook
cd MedBook && ./init.sh- Make the necessary changes in the app submodules
- For each app submodule:
- Merge to the
developbranch, push
- Make sure the build passes on CircleCI
- Decide on a release tag:
tag=v0.9.4 git checkout master && git merge --no-ff develop- the merge commit message should be: "$tag: [summary of changes]"
git tag -a TAG -m TAGgit push origin master --tags
- Merge to the
- Edit
docker-compose.ymlwith the new tags for each app git add -A, commit, and push
- Connect to the production server.
- Connect to the prod tmux session:
tmux a -t prod - Locate the parent MedBook repository:
cd ~/MedBook - Update all code:
git fetchgit statusto confirm everything looks reasonablegit pullto actually updateinit.shto update the submodules.
- Run
./scripts/prepare_for_deploy.sh. This will pull all non-cached images from Docker Hub - Press Ctrl-C to stop the site. Once all containers are spun down,
docker-compose upto start it again. This system will cause a short downtime.