Making and deploying releases
Version compatibility
DiracX should be upgraded before upgrading legacy DIRAC installations.
The versioning of DIRAC, DIRACCommon, diracx, diracx-charts and all the extensions are linked to one another.
Dependencies between diracx, DIRAC and DIRACCommon
Both DIRAC and diracx depend on DIRACCommon. However, DIRACCommon is in the same repository as DIRAC, and versioned together. This means that if we need to move code from DIRAC to DIRACCommon such that it is usable by diracx, we need first a new release of DIRAC and DIRACCommon just moving the code, before being able to use it in diracx.
The releases of DIRAC and DIRACCommon are managed as they have always been, and are described in the DIRAC documentation
Dependencies between diracx and diracx-charts
diracx-charts has a version number, as well as an appversion, which corresponds to the diracx version. This means that a new release of diracx requires a new diracx-charts release, which will update:
- the diracx-charts version
- the AppVersion
- the container versions
Renovate, configured in diracx-charts, detects the new diracx images and opens a pull request in diracx-charts with these changes. Once merged, it results in a new diracx-charts release.
Dependencies between diracx, diracx-web and diracx-charts
The diracx-web version is only very loosely coupled with the diracx version.
A new diracx-web release leads, through the same Renovate pull request mechanism, to a new diracx-charts release updating:
- the chart version
- the container versions
- NOT the AppVersion
It does not bump the AppVersion because it refers to the diracx version, which is more relevant.
diracx release
Releases are managed by ReleasePlease. The token used to perform it belongs to DIRACGridBot github user.
Why a bot token?
GITHUB_TOKEN cannot trigger downstream workflows (GitHub's anti-loop protection). Using a bot PAT ensures that the tag created by release-please triggers the deployment jobs.
A new release creates:
- a github release
- a pypi release
- new docker images
Force version number
You can force a specific version number following the doc
git commit --allow-empty -m "chore: release 0.0.3" -m "Release-As: v0.0.3"
git push upstream HEAD:main
diracx-web release
Releases are managed by ReleasePlease, which runs in the deployment workflow with the job's own GITHUB_TOKEN. A tag created with that token triggers no other workflow, so the release jobs run in the same workflow, after ReleasePlease.
A new release creates:
- a github release
- an npm release for
diracx-web-components: CI stages the version, and a maintainer approves it on npm (2FA) before it is published - new docker images
- updated Storybook documentation on GitHub Pages
diracx-charts releases
Every commit in master triggers a new release. The releases are published on a helm repo
The pull requests updating the chart for new diracx and diracx-web releases are opened by Renovate (see renovate.json in diracx-charts). Patch releases are marked for automerge, minor and major releases wait for a review. The diracx-charts ruleset requires an approving review on every pull request, so a maintainer still has to approve each of them before it merges.