Skip to content

Contributing

Setup

mise install                  # rust toolchain
cargo test                    # unit + wiremock API-client tests
cargo run --bin crdgen        # print CRDs

Regenerate the chart's CRDs after changing any spec type in src/crds/ — CI's test job fails if they've drifted:

cargo run --bin crdgen > charts/glitchtip-operator/crds/glitchtip.ruck.io.yaml

Running against a real cluster

hack/kind-up.sh               # kind + Gateway API CRDs + pgop + CRDs
RUST_LOG=info cargo run       # run the operator against your kubeconfig
hack/e2e.sh                   # end-to-end smoke test (real glitchtip image)

hack/kind-up.sh is safe to re-run against an existing cluster (it short-circuits cluster creation and uses helm upgrade --install for pgop).

CI

.github/workflows/ci.yaml runs three jobs on every push/PR:

  • test: cargo fmt --check, cargo clippy -D warnings, cargo test, and the CRD-drift check above.
  • helm: helm lint/helm template on the operator chart.
  • e2e: builds the operator's container image, loads it into a fresh kind cluster, deploys it via the Helm chart (not cargo run on the runner — the operator's live API calls to http://<name>-web.<ns>.svc:8000 only resolve from inside the cluster's pod network), and runs hack/e2e.sh against a real glitchtip/glitchtip image.

If you touch the Dockerfile, keep its build-stage base image pinned to the same Debian release as the distroless runtime stage (bookworm) — an unsuffixed rust:*-slim tag tracks whatever Debian release is current and can drift to a newer glibc than the runtime image ships, which fails at container startup rather than at build time.

Documentation

This site is built with MkDocs Material from the docs/ directory and mkdocs.yml, and deployed to GitHub Pages by .github/workflows/docs.yml on every push to main that touches docs/** or mkdocs.yml. Preview locally with:

pip install mkdocs-material
mkdocs serve