Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Updated to include uses of "ant pre-release"

...

  • Perform an git clone and switch to the correct branch
  • (Hint: using ant pre-release  may save you the following two three steps, plus steps 2-3 in the Maven release process.)
  • Edit "build.properties.default" and change the lines after "# ----- Reproducible builds -----" to a new value.

    • Note that the value of ant.tstamp.now property is in seconds (unlike the value returned by System.currentTimeMillis() method which is milliseconds, see bug 65527 for how this happened for Tomcat 8.5.70).
      The value can be printed in a Bash shell with the following command:
      date +%s
      To print seconds since epoch, and date and time in human-readable format in UTC time zone:
      date -u '+%s %Y-%m-%d %H:%M:%S %Z'
  • Edit "build.properties.default" and change the line version.suffix=-dev to version.suffix=

    • This can be done with sed -i.bak "s/^version.suffix=.*/version.suffix=/" build.properties.default
  • Edit "webapps/docs/changelog.xml" and remove rtext="in development" from the latest version
    • Remember that notepad.exe will remove UTF-8 Byte-Order Marks (BOMs). Use write.exe or Notepad++ instead.
  • Commit these changes
    • git add build-release.properties (if you used 'ant pre-release')
    • git commit -a -m "Tag 9.0.94"
    • git tag 9.0.94
    • git push origin 9.0.94
  • Check the diff mailed to the dev list
  • Reset to the 9.0.x branch (git reset HEAD~ && git checkout build.properties.default && git checkout webapps/docs/changelog.xml && rm -f build-release.properties)

I found it simplest to keep this clone for tagging to ensure no other edits found their way into the tag.

Build the release

  • Set JVM to Java 7 (Tomcat 8.5.x) or 8 (Tomcat 9.0, 10.0) or 11 (Tomcat 10.1) (no Longer necessary: always use Java 11 for release builds)
  • mkdir /c/releases/TOMCAT_9_0_94
  • git archive 9.0.94 | tar -x -C /c/releases/TOMCAT_9_0_94/

...

No Format
execute.validate=true

execute.test.bio=true
execute.test.nio=true
execute.test.apr=true

test.haltonfailure=true

gpg.exec=C:/Program Files (x86)/GNU/GnuPG/gpg2.exe
#gpg.exec=/usr/bin/gpg

base.path=C:/temp/libs
#base.path=~/tomcat-libs
# Enable the following if the DigiCert ONE magic is all set up, including ~/.digicertone/pkcs11properties.cfg
#docodesigning.storepass=apikey|keystorepath|keystorepassword
do.codesigning=true
  • ant pre-release (again, to generate res/maven/mvn.properties)
  • ant release

Notes:

  • GPG should be configured to use your Apache code signing key by default
  • I always ensured c:/temp/libs was empty so that the build had to download all the dependencies
  • This does not include the signing of the Windows installer, which must be done using https://one.digicert.com/ and https://infra.apache.org/digicert-use.html which is automated during the build process once the Tomcat PMC key is accessible by using jsign. (Working? ! Try setting do.codesigning=true in build.properties).
  • The logs for the Windows signing are in ~/.signingmanager/logs on Linux
  • If you get an error signing the installer/uninstaller "Cannot load keystore ~/.digicertone/pkcs11properties.cfg" then you probably don't have your environment variables (or codesigning.storepass property) set properly.

Upload the release

...