Skip to content

Build and publish

The build is a Dagger module; make targets wrap its entrypoints. The repository ships a Nix flake with the Go toolchain, make, and dagger:

Terminal window
nix develop # or `direnv allow`, which loads the same shell

make help lists every target:

build Builds the postgres image and exports locally
build-push Build and publish the multi-arch image to the public registry
help Prints this help message

make build builds the image for your local platform and loads it into your local container image store:

Terminal window
make build

That is a thin wrapper over the module’s own entrypoint:

Terminal window
dagger call build-postgres-image export-image --name postgres:17.7-pgduckdb-1.1.1

NAME and TAG override the exported image reference:

Terminal window
make build NAME=pgtapes TAG=dev

make build-push builds the multi-platform image (linux/amd64 and linux/arm64) and pushes it to a registry. It needs credentials for whatever registry you point it at:

Terminal window
make build-push REGISTRY=public.ecr.aws/your-alias TAG=17.7-pgduckdb-1.1.1

Which calls:

Terminal window
dagger call build-push-postgres-images \
--registry "$REGISTRY" \
--tags "17.7-pgduckdb-1.1.1"

The module validates every tag before building — the constraint and its reason are in Image tags. CI builds the image on pushes to main and on pull requests; publishing to the public registry is a manually triggered workflow.