1# How to Release
2## Comparing branches or tags
3
4Execute branch.py to compare branches or tags.
5branch.py has 2 positional arguments:
6```
7  from_ref           the ref to show the path from
8  to_ref             the ref to show the path to
9```
10You can find more info by executing `branch.py -h`
11
12Example:
13`python branch.py v1.2 master` - this line compares the master branch with the release branch v1.2
14The output of this command will be as follows:
15```
16[- 5e000f4b] release v1.2
17[+ c000872d] satellite/payments: coupon value feature
18...
19[+ ec008dcf] build: Go 1.14.4
20```
21`-` sign means that commit not in the master branch(`from_ref`)
22`+` sign means that commit not in v1.2 branch(`to_ref`)
23
24From the above it follows that commits with a plus sign will be included in the next release v1.3
25
26## How to write github changelog
27
28the next step is to create the page on Confluence with our changelog for the release v1.3.
29Example: [Release v1.31](https://storjlabs.atlassian.net/wiki/spaces/ENG/pages/1812791357/Release%2Bv1.31)
30Here we need to highlight important changes for each topic(storj-sim, Uplink, Sattelite, Storage Node, General etc.)
31
32## Cutting release branch
33
34Then its time to cut the release branch:
35`git checkout -b v1.3` - will create and checkout branch v1.3
36`git push origin v1.3`- will push release branch to the repo
37
38The next step is to create tag using `tag-release.sh` which is in storj/scripts folder and push it.
39Example:
40`./scripts/tag-release.sh v1.3.0-rc`
41`git push origin v1.3.0-rc`
42Then verify that the Jenkins job of the build Storj V3 for such tag and branch has finished successfully.
43Together with that you need to create the same release branch for [tardigrade branding repo](https://github.com/storj/tardigrade-satellite-theme).
44
45## How to cherry pick
46
47If you need to cherry-pick something after the release branch has been created then you need to create point release.
48Make sure that you have the latest changes, checkout the release branch and execute cherry-pick:
49`git cherry-pick <your commit hash>`
50You need to create pull request to the release branch with that commit. After the pull request will be approved and merged you should create new release tag:
51`./scripts/tag-release.sh v1.3.1`
52and push the tag to the repo:
53`git push origin v1.3.1`
54Verify that the Jenkins job of the build Storj V3 for such tag has finished successfully.
55Double check that there was no change on the tardigrade branding in the meantime. Otherwise, the point release might get a broken tardigrade branding. If there are additional commits on the tardigrade branding it is better to create a release branch and revert them. You also have to update the Jenkins job to build from the release branch. Do not forget to change it back to master for the following regular release.
56```
57git clone git@github.com:storj/tardigrade-satellite-theme
58git reset --hard <your commit hash>
59git checkout -b release-v1.3
60git push origin release-v1.3
61```
62Update Jenkins job.
63
64## Where to find the release binaries and upload them to github
65
66The release binaries you can find [here](https://storj-v3-alpha-builds.storage.googleapis.com/index.html).
67Use search to find current release and open it.
68Here you will need to download 21 binaries
69```
70"identity_darwin_amd64.zip", "identity_freebsd_amd64.zip", "identity_linux_amd64.zip", "identity_linux_arm.zip", "identity_linux_arm64.zip",
712"identity_windows_amd64.zip", "storagenode-updater_linux_amd64.zip", "storagenode-updater_linux_arm.zip", "storagenode-updater_linux_arm64.zip",
723"storagenode-updater_windows_amd64.zip", "storagenode_freebsd_amd64.zip", "storagenode_linux_amd64.zip", "storagenode_linux_arm.zip", "storagenode_linux_arm64.zip",
734"storagenode_windows_amd64.msi.zip", "storagenode_windows_amd64.zip", "uplink_darwin_amd64.zip", "uplink_freebsd_amd64.zip", "uplink_linux_amd64.zip",
745"uplink_linux_arm.zip", "uplink_linux_arm64.zip", "uplink_windows_amd64.zip"
75```
76Then you will need to go to the storj repo on github and open  [releases](https://github.com/storj/storj/releases).
77Press button [draft new release](https://github.com/storj/storj/releases/new), select the tag and upload binaries.
78Also you will need to post here a changelog from the Confluence page, and press the button `Save draft`. You can look at examples from previous releases on GitHub.
79
80## Which tests do we want to execute
81Everything that could break production.
82From the perspective of a storage node operator the storage node needs to run stable, should not get disqualified or suspended, payout and usage data should be available on the dashboard, graceful exit, garbage collection. Everything that touches on of these topics is most likely worth a test.
83From the perspective of a satellite operator the durability, availability and accounting is important. This includes the audit and repair system. Also customer and storage node signups should work. Anything in these area is worth a test.
84For an uplink the network just needs to work. Node selection is critical. If we keep selecting full or bad nodes the uplink will have a hard time to upload enough pieces. It also affects performance.
85
86## Forum post changelog
87On the forum you need to highlight the most important changes for the storage node operators and describe it a little.
88
89## Useful links
90[Deployment documentation](https://storjlabs.atlassian.net/wiki/spaces/OPS/pages/153190401/Satellite+-+post+phoenix#satellite.qa.storj.io)
91[Storage node rollout process](https://storjlabs.atlassian.net/wiki/spaces/OPS/pages/138084357/Storagenode)
92