Skip to content

Commit dba74c8

Browse files
authored
Merge pull request #424 from CodeForPhilly/issue-#421
Update to docs with references to new deployment process
2 parents 2f96066 + c3002d9 commit dba74c8

File tree

4 files changed

+45
-93
lines changed

4 files changed

+45
-93
lines changed

docs/SUMMARY.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,8 @@
99
- [Data Analysis](contributing/data-analysis.md)
1010
- [Operations Support](contributing/operations-support.md)
1111
- Operations
12-
- [Release Process](./operations/release-process.md)
12+
- [Preparing a new release](./operations/prepare-new-chime-release.md)
13+
- [Release Process](./operations/release=process.md)
1314
- [The `chime-live` Cluster](./operations/chime-live-cluster.md)
1415
- [Deploy to Heroku](./operations/heroku.md)
1516
- [Deploy with Chef Habitat](./operations/habitat.md)

docs/operations/chime-live-cluster.md

Lines changed: 1 addition & 86 deletions
Original file line numberDiff line numberDiff line change
@@ -28,89 +28,4 @@
2828

2929
```bash
3030
kubectl get pod --all-namespaces
31-
```
32-
33-
## Deploying a New CHIME Version
34-
35-
1. [Create a new release](release-process.md)
36-
2. Wait for the `Docker` GitHub Actions workflow to complete
37-
3. Verify the new version shows up at the top as "Latest version" here: https://github.com/CodeForPhilly/chime/packages/155340
38-
4. Open a new issue on GitHub titled "Deploy chime $VERSION" (ex: https://github.com/CodeForPhilly/chime/issues/98)
39-
* Note the PR in which the release was approved
40-
* Confirm that the tag for the version was created
41-
5. Create a local branch (based on "develop") to perform deploy time changed on, named "deploy/$VERSION"
42-
43-
```bash
44-
VERSION=1.2.3
45-
git rev-parse --abbrev-ref HEAD
46-
# develop
47-
git pull
48-
git checkout -b deploy/$VERSION
49-
```
50-
51-
6. Update the app.yaml manifest file
52-
53-
```bash
54-
VERSION=1.2.3
55-
sed -Ei "s/(- image: .*):(.*)/\1:$VERSION/" k8s/app.yaml
56-
git add -A
57-
# verify changes are as expected
58-
git diff --staged
59-
git commit -m "Deploy chime $VERSION"
60-
```
61-
62-
7. Push changes
63-
64-
```bash
65-
VERSION=1.2.3
66-
git push -u origin deploy/$VERSION
67-
```
68-
69-
8. Open PR on GitHub to merge changes back into develop, ideally with
70-
the review of another DevOps admin whenever possible. Ensure to link
71-
to the PR in the deployment issue previously opened on GitHub.
72-
73-
9. Run:
74-
75-
```bash
76-
kubectl apply -f k8s/app.yaml
77-
```
78-
79-
10. Watch rollout status:
80-
81-
```bash
82-
kubectl -n chime rollout status deployment.v1.apps/chime
83-
```
84-
85-
11. Confirm the expected version is running
86-
87-
```bash
88-
kubectl -n chime get deployment chime -o yaml | grep image:
89-
# - image: docker.pkg.github.com/codeforphilly/chime/penn-chime:$VERSION
90-
```
91-
92-
12. Paste the output from steps 11 & 12 into the previously opened deployment issue
93-
to document the successful deployment and close the issue
94-
13. $$$ PROFIT $$$
95-
96-
## Applying Changes to `k8s/` Manifests
97-
98-
After making changes to the manifests in `k8s/` that you want to apply, first review the diff for what you're about to change using an editor that wil color-code the output and make it easy to review:
99-
100-
```bash
101-
kubectl diff -Rf k8s/ | code -
102-
```
103-
104-
*Ignore any instances of `generation` being incremented*
105-
106-
Once you're satisfied with the results of the diff, you can apply a single manifest:
107-
108-
```bash
109-
kubectl apply -f k8s/infra/ingress-nginx.yaml
110-
```
111-
112-
Or the entire directory:
113-
114-
```bash
115-
kubectl apply -Rf k8s/
116-
```
31+
```
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
# Operations: Prepare New Chime Release
2+
3+
At the end of following this process you will have deployed a new CHIME version to https://penn-chime.phl.io
4+
5+
## Start Here
6+
7+
## Prepare Chime on the Develop Branch
8+
9+
1. Open a new issue on GitHub titled "Deploy chime $VERSION" (ex: https://github.com/CodeForPhilly/chime/issues/98)
10+
* Note the PR in which the release was approved
11+
* Confirm that the tag for the version was created
12+
2. Create a local branch (based on "develop") to perform deploy time changed on, named "deploy/$VERSION"
13+
14+
```bash
15+
export VERSION=x.x.x #set this to the release version you are releasing. (export VERSION=1.1.1 for version 1.1.1)
16+
git checkout develop
17+
git pull
18+
git checkout -b deploy/$VERSION # this will ultimately create a branch deploy/1.1.1 (from the reference above)
19+
```
20+
21+
3. Update the app.yaml manifest file using an editor. You will need to change the line that has: ```- image: docker.pkg.github.com/codeforphilly/chime/penn-chime:<insert versions here>```
22+
* After that is complete, update your branch.
23+
24+
```bash
25+
git add k8s/app.yml
26+
git diff --staged
27+
git commit -m "Deploy chime $VERSION"
28+
```
29+
30+
4. Push changes
31+
32+
```bash
33+
git push -u origin deploy/$VERSION
34+
```
35+
36+
5. [Open PR on GitHub](https://github.com/CodeForPhilly/chime/compare) to merge changes back into develop, ideally with
37+
the review of another DevOps admin whenever possible. Ensure to link
38+
to the PR in the deployment issue previously opened on GitHub.
39+
40+
6. One approved you will need to [create a release to auto deploy](release-process.md)

docs/operations/release-process.md

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
11
# Operations: Release Process
22

3-
1. Merge pull requests into `develop`
4-
2. Chose a new version number by incrementing the previous release according to [semver](https://semver.org/)
5-
- Do not bump the MAJOR version unless the team is ready to create a new `releases/v#` branch
6-
3. Open a pull request to merge `develop` into `releases/v1`
3+
1. Open a pull request to merge `develop` into `releases/v1`
74
- **Title**: `Release: CHIME v1.#.#`
85
- **Description**: Generate with this command:
96

@@ -21,5 +18,4 @@
2118
6. [Create a new release against `releases/v1`](https://github.com/CodeForPhilly/chime/releases/new?target=releases/v1)
2219
- **Tag version:** `v1.#.#`
2320
- **Release Title:** `CHIME v1.#.#`
24-
- **Description:** Copy release notes from pull request
25-
7. [Deploy to the `chime-live` cluster](chime-live-cluster.md)
21+
- **Description:** Copy release notes from pull request

0 commit comments

Comments
 (0)