Release Process
See Branch and Release Policy for the governing branch, promotion, and ruleset policy. This document describes the release mechanics that implement that policy.
ZeptoDB uses dev as the integration branch and main as the release branch.
All normal development pushes should target dev. Promoting code to main
starts the release automation.
Branch Flow
Section titled “Branch Flow”- Push feature work to
devor to a short-lived branch that targetsdev. - Run the required CI and review checks against
dev. - Promote
devtomainonly when the repository is ready to publish a new version. - Do not push directly to
mainfrom local development. The repository pre-push hook blocksrefs/heads/mainunlessZEPTO_ALLOW_MAIN_PUSH=1is set for an explicit release-admin override.
Automatic Versioning
Section titled “Automatic Versioning”Version Main Release runs on every push to main.
The workflow:
- Fetches all
vMAJOR.MINOR.PATCHtags. - Reads the current project versions from:
CMakeLists.txtzepto_py/__init__.pyweb/package.jsondeploy/helm/zeptodb/Chart.yaml- both production Dockerfile
ZEPTO_VERSIONdefaults
- Compares the highest tag version with the highest checked-in version file.
- Uses the checked-in version when it is ahead of the latest tag; otherwise bumps the latest tag’s patch component.
- Commits the synchronized version files to
mainwithchore(release): vX.Y.Z. - Creates tag
vX.Y.Z. - Pushes the tag, which triggers the
Releaseworkflow.
This keeps binary artifact names, Docker tags, GitHub releases, and the Python package version aligned.
Release Workflow
Section titled “Release Workflow”The existing Release workflow still owns publishing:
- Linux amd64 and arm64 binary archives.
- Multi-arch Docker image tags
zeptodb/zeptodb:X.Y.Zandzeptodb/zeptodb:latest. - GitHub Release notes and downloadable archives.
- PyPI package publishing through trusted publishing.
- Homebrew tap update dispatch.
The full release workflow is triggered by a v* tag push. The workflow can
also be run manually with workflow_dispatch plus a version input to
republish Docker images and manifests for an existing release without creating
a new GitHub Release, PyPI package, Homebrew dispatch, or tag.
Release binary builds use ccache with per-architecture restore keys so repeated
tag builds can reuse unchanged C++ compilation results. Docker release builds
use the repository .dockerignore to keep local build directories, web build
output, docs, Git metadata, and benchmark artifacts out of the build context.
The Docker image path builds and smoke-tests native amd64/arm64 images, verifies
their version labels, generates SBOMs, blocks HIGH/CRITICAL vulnerabilities,
archives those exact verified images, and only then publishes the per-arch tags
and multi-arch manifest. Published images are therefore the same image bytes
that passed verification rather than a later rebuild.
The Graviton ARM64 Build & Test workflow is not run for release-bot
chore(release): vX.Y.Z version bump commits. The tag-triggered Release
workflow calls the hosted x86_64 and ARM64 full production gate before building
portable release binaries and verified native images. Release-version commits
use a separate Graviton concurrency key so they do not cancel the main-merge
Graviton run that preceded the version bump.
Repository Settings
Section titled “Repository Settings”The pipeline expects these GitHub settings:
- The repository secret
RELEASE_BOT_TOKENis configured with permission to push tomain, createv*tags, and dispatch workflows. This repository is under an organization policy that disables write permissions for the defaultGITHUB_TOKEN, so the release workflow cannot rely ongithub.token. mainandv*rulesets allow the release bot account to bypass release automation writes. The current repository ruleset uses repository-admin bypass, so the token owner must have admin permission or the ruleset must be updated to name a narrower bot actor.- Required release secrets are present:
RELEASE_BOT_TOKENDOCKERHUB_USERNAMEDOCKERHUB_TOKENSITE_DEPLOY_TOKEN
- PyPI trusted publishing is configured for the
pypienvironment. - The self-hosted ARM64 runner used by
Graviton ARM64 Build & Testis online.
Version Policy
Section titled “Version Policy”The default automatic bump is patch-only. Minor or major releases should be
prepared by manually updating the version files on dev before promoting to
main; the automation will publish that higher checked-in version exactly.
Active Rulesets
Section titled “Active Rulesets”The repository is configured with these active rules:
Dev branch safety: protectsdevfrom deletion and non-fast-forward updates.Main release branch: protectsmainfrom deletion and non-fast-forward updates, requires a pull request, requires one approving review, dismisses stale reviews on push, and requires review-thread resolution.Release tags: protectsv*tags from unauthorized creation, deletion, and non-fast-forward updates.