You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long. 14KB

  1. Release Process
  2. ====================
  3. Before every release candidate:
  4. * Update translations (ping wumpus on IRC) see [](
  5. * Update manpages, see [](
  6. Before every minor and major release:
  7. * Update []( to account for changes since the last release.
  8. * Update version in `` (don't forget to set `CLIENT_VERSION_IS_RELEASE` to `true`)
  9. * Write release notes (see below)
  10. * Update `src/chainparams.cpp` nMinimumChainWork with information from the getblockchaininfo rpc.
  11. * Update `src/chainparams.cpp` defaultAssumeValid with information from the getblockhash rpc.
  12. - The selected value must not be orphaned so it may be useful to set the value two blocks back from the tip.
  13. - Ai should be set some tens of thousands back from the tip due to reorgs there.
  14. - This update should be reviewed with a reindex-chainstate with assumevalid=0 to catch any defect
  15. that causes rejection of blocks in the past history.
  16. Before every major release:
  17. * Update hardcoded [seeds](/contrib/seeds/, see [this pull request]( for an example.
  18. * Update [`BLOCK_CHAIN_SIZE`](/src/qt/intro.cpp) to the current size plus some overhead.
  19. * Update `src/chainparams.cpp` chainTxData with statistics about the transaction count and rate.
  20. * Update version of `contrib/gitian-descriptors/*.yml`: usually one'd want to do this on master after branching off the release - but be sure to at least do it before a new major release
  21. ### First time / New builders
  22. If you're using the automated script (found in [contrib/](/contrib/, then at this point you should run it with the "--setup" command. Otherwise ignore this.
  23. Check out the source code in the following directory hierarchy.
  24. cd /path/to/your/toplevel/build
  25. git clone
  26. git clone
  27. git clone
  28. git clone
  29. ### Starwels maintainers/release engineers, suggestion for writing release notes
  30. Write release notes. git shortlog helps a lot, for example:
  31. git shortlog --no-merges v(current version, e.g. 0.7.2)..v(new version, e.g. 0.8.0)
  32. (or ping @wumpus on IRC, he has specific tooling to generate the list of merged pulls
  33. and sort them into categories based on labels)
  34. Generate list of authors:
  35. git log --format='%aN' "$*" | sort -ui | sed -e 's/^/- /'
  36. Tag version (or release candidate) in git
  37. git tag -s v(new version, e.g. 0.8.0)
  38. ### Setup and perform Gitian builds
  39. If you're using the automated script (found in [contrib/](/contrib/, then at this point you should run it with the "--build" command. Otherwise ignore this.
  40. Setup Gitian descriptors:
  41. pushd ./starwels
  42. export SIGNER=(your Gitian key, ie bluematt, sipa, etc)
  43. export VERSION=(new version, e.g. 0.8.0)
  44. git fetch
  45. git checkout v${VERSION}
  46. popd
  47. Ensure your gitian.sigs are up-to-date if you wish to gverify your builds against other Gitian signatures.
  48. pushd ./gitian.sigs
  49. git pull
  50. popd
  51. Ensure gitian-builder is up-to-date:
  52. pushd ./gitian-builder
  53. git pull
  54. popd
  55. ### Fetch and create inputs: (first time, or when dependency versions change)
  56. pushd ./gitian-builder
  57. mkdir -p inputs
  58. wget -P inputs
  59. wget -P inputs
  60. popd
  61. Create the OS X SDK tarball, see the [OS X readme]( for details, and copy it into the inputs directory.
  62. ### Optional: Seed the Gitian sources cache and offline git repositories
  63. By default, Gitian will fetch source files as needed. To cache them ahead of time:
  64. pushd ./gitian-builder
  65. make -C ../starwels/depends download SOURCES_PATH=`pwd`/cache/common
  66. popd
  67. Only missing files will be fetched, so this is safe to re-run for each build.
  68. NOTE: Offline builds must use the --url flag to ensure Gitian fetches only from local URLs. For example:
  69. pushd ./gitian-builder
  70. ./bin/gbuild --url starwels=/path/to/starwels,signature=/path/to/sigs {rest of arguments}
  71. popd
  72. The gbuild invocations below <b>DO NOT DO THIS</b> by default.
  73. ### Build and sign Starwels for Linux, Windows, and OS X:
  74. pushd ./gitian-builder
  75. ./bin/gbuild --num-make 2 --memory 3000 --commit starwels=v${VERSION} ../starwels/contrib/gitian-descriptors/gitian-linux.yml
  76. ./bin/gsign --signer $SIGNER --release ${VERSION}-linux --destination ../gitian.sigs/ ../starwels/contrib/gitian-descriptors/gitian-linux.yml
  77. mv build/out/starwels-*.tar.gz build/out/src/starwels-*.tar.gz ../
  78. ./bin/gbuild --num-make 2 --memory 3000 --commit starwels=v${VERSION} ../starwels/contrib/gitian-descriptors/gitian-win.yml
  79. ./bin/gsign --signer $SIGNER --release ${VERSION}-win-unsigned --destination ../gitian.sigs/ ../starwels/contrib/gitian-descriptors/gitian-win.yml
  80. mv build/out/starwels-*-win-unsigned.tar.gz inputs/starwels-win-unsigned.tar.gz
  81. mv build/out/starwels-*.zip build/out/starwels-*.exe ../
  82. ./bin/gbuild --num-make 2 --memory 3000 --commit starwels=v${VERSION} ../starwels/contrib/gitian-descriptors/gitian-osx.yml
  83. ./bin/gsign --signer $SIGNER --release ${VERSION}-osx-unsigned --destination ../gitian.sigs/ ../starwels/contrib/gitian-descriptors/gitian-osx.yml
  84. mv build/out/starwels-*-osx-unsigned.tar.gz inputs/starwels-osx-unsigned.tar.gz
  85. mv build/out/starwels-*.tar.gz build/out/starwels-*.dmg ../
  86. popd
  87. Build output expected:
  88. 1. source tarball (`starwels-${VERSION}.tar.gz`)
  89. 2. linux 32-bit and 64-bit dist tarballs (`starwels-${VERSION}-linux[32|64].tar.gz`)
  90. 3. windows 32-bit and 64-bit unsigned installers and dist zips (`starwels-${VERSION}-win[32|64]-setup-unsigned.exe`, `starwels-${VERSION}-win[32|64].zip`)
  91. 4. OS X unsigned installer and dist tarball (`starwels-${VERSION}-osx-unsigned.dmg`, `starwels-${VERSION}-osx64.tar.gz`)
  92. 5. Gitian signatures (in `gitian.sigs/${VERSION}-<linux|{win,osx}-unsigned>/(your Gitian key)/`)
  93. ### Verify other gitian builders signatures to your own. (Optional)
  94. Add other gitian builders keys to your gpg keyring, and/or refresh keys.
  95. gpg --import starwels/contrib/gitian-keys/*.pgp
  96. gpg --refresh-keys
  97. Verify the signatures
  98. pushd ./gitian-builder
  99. ./bin/gverify -v -d ../gitian.sigs/ -r ${VERSION}-linux ../starwels/contrib/gitian-descriptors/gitian-linux.yml
  100. ./bin/gverify -v -d ../gitian.sigs/ -r ${VERSION}-win-unsigned ../starwels/contrib/gitian-descriptors/gitian-win.yml
  101. ./bin/gverify -v -d ../gitian.sigs/ -r ${VERSION}-osx-unsigned ../starwels/contrib/gitian-descriptors/gitian-osx.yml
  102. popd
  103. ### Next steps:
  104. Commit your signature to gitian.sigs:
  105. pushd gitian.sigs
  106. git add ${VERSION}-linux/${SIGNER}
  107. git add ${VERSION}-win-unsigned/${SIGNER}
  108. git add ${VERSION}-osx-unsigned/${SIGNER}
  109. git commit -a
  110. git push # Assuming you can push to the gitian.sigs tree
  111. popd
  112. Codesigner only: Create Windows/OS X detached signatures:
  113. - Only one person handles codesigning. Everyone else should skip to the next step.
  114. - Only once the Windows/OS X builds each have 3 matching signatures may they be signed with their respective release keys.
  115. Codesigner only: Sign the osx binary:
  116. transfer starwels-osx-unsigned.tar.gz to osx for signing
  117. tar xf starwels-osx-unsigned.tar.gz
  118. ./ -s "Key ID"
  119. Enter the keychain password and authorize the signature
  120. Move signature-osx.tar.gz back to the gitian host
  121. Codesigner only: Sign the windows binaries:
  122. tar xf starwels-win-unsigned.tar.gz
  123. ./ -key /path/to/codesign.key
  124. Enter the passphrase for the key when prompted
  125. signature-win.tar.gz will be created
  126. Codesigner only: Commit the detached codesign payloads:
  127. cd ~/starwels-detached-sigs
  128. checkout the appropriate branch for this release series
  129. rm -rf *
  130. tar xf signature-osx.tar.gz
  131. tar xf signature-win.tar.gz
  132. git add -a
  133. git commit -m "point to ${VERSION}"
  134. git tag -s v${VERSION} HEAD
  135. git push the current branch and new tag
  136. Non-codesigners: wait for Windows/OS X detached signatures:
  137. - Once the Windows/OS X builds each have 3 matching signatures, they will be signed with their respective release keys.
  138. - Detached signatures will then be committed to the [starwels-detached-sigs]( repository, which can be combined with the unsigned apps to create signed binaries.
  139. Create (and optionally verify) the signed OS X binary:
  140. pushd ./gitian-builder
  141. ./bin/gbuild -i --commit signature=v${VERSION} ../starwels/contrib/gitian-descriptors/gitian-osx-signer.yml
  142. ./bin/gsign --signer $SIGNER --release ${VERSION}-osx-signed --destination ../gitian.sigs/ ../starwels/contrib/gitian-descriptors/gitian-osx-signer.yml
  143. ./bin/gverify -v -d ../gitian.sigs/ -r ${VERSION}-osx-signed ../starwels/contrib/gitian-descriptors/gitian-osx-signer.yml
  144. mv build/out/starwels-osx-signed.dmg ../starwels-${VERSION}-osx.dmg
  145. popd
  146. Create (and optionally verify) the signed Windows binaries:
  147. pushd ./gitian-builder
  148. ./bin/gbuild -i --commit signature=v${VERSION} ../starwels/contrib/gitian-descriptors/gitian-win-signer.yml
  149. ./bin/gsign --signer $SIGNER --release ${VERSION}-win-signed --destination ../gitian.sigs/ ../starwels/contrib/gitian-descriptors/gitian-win-signer.yml
  150. ./bin/gverify -v -d ../gitian.sigs/ -r ${VERSION}-win-signed ../starwels/contrib/gitian-descriptors/gitian-win-signer.yml
  151. mv build/out/starwels-*win64-setup.exe ../starwels-${VERSION}-win64-setup.exe
  152. mv build/out/starwels-*win32-setup.exe ../starwels-${VERSION}-win32-setup.exe
  153. popd
  154. Commit your signature for the signed OS X/Windows binaries:
  155. pushd gitian.sigs
  156. git add ${VERSION}-osx-signed/${SIGNER}
  157. git add ${VERSION}-win-signed/${SIGNER}
  158. git commit -a
  159. git push # Assuming you can push to the gitian.sigs tree
  160. popd
  161. ### After 3 or more people have gitian-built and their results match:
  162. - Create `SHA256SUMS.asc` for the builds, and GPG-sign it:
  163. ```bash
  164. sha256sum * > SHA256SUMS
  165. ```
  166. The list of files should be:
  167. ```
  168. starwels-${VERSION}-aarch64-linux-gnu.tar.gz
  169. starwels-${VERSION}-arm-linux-gnueabihf.tar.gz
  170. starwels-${VERSION}-i686-pc-linux-gnu.tar.gz
  171. starwels-${VERSION}-x86_64-linux-gnu.tar.gz
  172. starwels-${VERSION}-osx64.tar.gz
  173. starwels-${VERSION}-osx.dmg
  174. starwels-${VERSION}.tar.gz
  175. starwels-${VERSION}-win32-setup.exe
  176. starwels-${VERSION}
  177. starwels-${VERSION}-win64-setup.exe
  178. starwels-${VERSION}
  179. ```
  180. The `*-debug*` files generated by the gitian build contain debug symbols
  181. for troubleshooting by developers. It is assumed that anyone that is interested
  182. in debugging can run gitian to generate the files for themselves. To avoid
  183. end-user confusion about which file to pick, as well as save storage
  184. space *do not upload these to the server, nor put them in the torrent*.
  185. - GPG-sign it, delete the unsigned file:
  186. ```
  187. gpg --digest-algo sha256 --clearsign SHA256SUMS # outputs SHA256SUMS.asc
  188. rm SHA256SUMS
  189. ```
  190. (the digest algorithm is forced to sha256 to avoid confusion of the `Hash:` header that GPG adds with the SHA256 used for the files)
  191. Note: check that SHA256SUMS itself doesn't end up in SHA256SUMS, which is a spurious/nonsensical entry.
  192. - Upload zips and installers, as well as `SHA256SUMS.asc` from last step, to the server
  193. into `/var/www/bin/starwels-${VERSION}`
  194. - A `.torrent` will appear in the directory after a few minutes. Optionally help seed this torrent. To get the `magnet:` URI use:
  195. ```bash
  196. transmission-show -m <torrent file>
  197. ```
  198. Insert the magnet URI into the announcement sent to mailing lists. This permits
  199. people without access to `` to download the binary distribution.
  200. Also put it into the `optional_magnetlink:` slot in the YAML file for
  201. (see below for update instructions).
  202. - Update version
  203. - First, check to see if the maintainers have prepared a
  204. release:
  205. - If they have, it will have previously failed their Travis CI
  206. checks because the final release files weren't uploaded.
  207. Trigger a Travis CI rebuild---if it passes, merge.
  208. - If they have not prepared a release, follow the release
  209. instructions:
  210. - After the pull request is merged, the website will automatically show the newest version within 15 minutes, as well
  211. as update the OS download links. Ping @saivann/@harding (saivann/harding on Freenode) in case anything goes wrong
  212. - Announce the release:
  213. - starwels-dev and starwels-dev mailing list
  214. - Starwels announcements list
  215. - blog post
  216. - Update title of #bitcoin on Freenode IRC
  217. - Optionally twitter, reddit /r/Starwels, ... but this will usually sort out itself
  218. - Notify BlueMatt so that he can start building [the PPAs](
  219. - Archive release notes for the new version to `doc/release-notes/` (branch `master` and branch of the release)
  220. - Create a [new GitHub release]( with a link to the archived release notes.
  221. - Celebrate