TazPod: CI Detail

Level 3 (Detail) — Conditional build pipeline for CLI and container images.

Concept

The CI pipeline builds the tazpod CLI binary unconditionally on every push to master, but only builds Docker images if the relevant files (Dockerfiles, dotfiles) have changed.

Workflow

File: .github/workflows/build-push.yml

Trigger: push to master.

Stage 1: CLI Build

Always runs:

  1. go vet ./...
  2. go test ./...
  3. go build -ldflags "-X main.Version=$(cat VERSION)" -o tazpod cmd/tazpod/main.go
  4. Upload binary as GitHub Release artifact

Stage 2: Conditional Docker Build

Only runs if changes detected in:

  • .tazpod/Dockerfile.*
  • dotfiles/
  • cmd/
  • internal/
  • .github/workflows/

Uses GitHub Actions cache for Docker layer caching.

Build Matrix

LayerDockerfileImage TagDepends On
base.tazpod/Dockerfile.basetazzo/tazpod-base:<version>
aws.tazpod/Dockerfile.awstazzo/tazpod-aws:<version>base published
k8s.tazpod/Dockerfile.k8stazzo/tazpod-k8s:<version>aws published
ai.tazpod/Dockerfile.aitazzo/tazpod-ai:<version>k8s published

Each layer:

  • Tags with version from VERSION file (e.g., tazzo/tazpod-ai:0.3.18)
  • Tags with latest
  • Pushes to Docker Hub

Versioning

File: VERSION

0.3.18

Used both for CLI --version flag (via ldflags) and for Docker image tags.

See Also