Skip to content

Instantly share code, notes, and snippets.

@wohali
Last active November 3, 2021 07:04
Show Gist options
  • Save wohali/9f159bbdb6ef2c51a50d1e2326fc1d5b to your computer and use it in GitHub Desktop.
Save wohali/9f159bbdb6ef2c51a50d1e2326fc1d5b to your computer and use it in GitHub Desktop.

How to do a binary CouchDB release without Joan

  • RPMs will need to be signed by someone else & docs updated accordingly (there can only be one signature per release, right now, and changing it requires clients manually import the new key)
  • You need Docker Hub creds to push to apache/couchdb - make an account there, then talk to Infra for access (PMC must approve)
  • You need Artifactory creds to push binaries there - talk to Infra for access (PMC must approve)
  • Someone else needs to set up a Windows build
    • Signing for Windows packages has not been worked through for the new signing authority; this will need to be restarted from scratch
    • Windows packages are maintained and published by Neighbourhoodie - will need to liaise with Jan L. for upload

  1. For .deb/.rpm pacakges, from a checked out copy of couchdb-pkg, on an Ubuntu 18.04 or 20.04 machine with all the needed deps (Docker primarily, but also apt install curl gpg rpm):
./build.sh couch-all <URL or TARBALL>
sudo chmod a+w pkgs/couch/centos-*/*.rpm
rpmsign --addsign pkgs/couch/centos-7/couchdb-#.#.#-1.el7.rpm
rpmsign --addsign pkgs/couch/centos-8/couchdb-#.#.#-1.el8.rpm
export BINARY_CREDS=<user>:<token>    # this is your artifactory login and an API token from them
./build.sh couch-upload-all
  1. In couchdb-docker:
  • new directory for each release, copy files forward, tweak as needed
  • remove deprecated versions (right now, active are 2.3.1, 3.1.2, 3.2.0) from git
  • build and push the apache/couchdb images (run build.sh for help, use the buildx setup if you can)
  • remove old tags from Docker Hub for apache/couchdb(especially if security issue...)
  • test the image
  • file a downstream PR with docker-library/official-images to update the hash they should use and update the list of supported releases
  1. For Windows, see couchdb-glazier for Windows build instructions, but on a prepared machine, it's:
&c:\relax\couchdb-glazier\bin\shell.ps1
cd c:\relax
wget.exe <URL to source tarball>
tar xf <source-tarball.tar.gz>
move <apache-couchdb-#.#.#> couchdb
cd couchdb
&.\configure.ps1 -SpiderMonkeyVersion 60
make -f Makefile.win check
make -f Makefile.win release
cd c:\relax
&couchdb-glazier\bin\build_installer.ps1

and test the .msi file works on a DIFFERENT system (or do a full-machine VM snapshot prior to install so you can roll back, installation changes system state and it's best to fully remove it before doing a new build)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment