Publish Docker images to GitHub Packages (GHCR)#629
Open
mbukeRepo wants to merge 1 commit into
Open
Conversation
Publish container images to GitHub Packages (GHCR) alongside the existing Docker Hub builds, giving us versioned, release-pinned images we don't have today.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
📦 Publish Docker images to GitHub Packages (GHCR)
This PR sets up automated Docker image publishing to the GitHub Container
Registry so that every release produces a versioned, immutable image — straight
from GitHub, with zero extra secrets to manage.
Why this is worth it
Today our images are built by GitLab CI and only ever pushed as
:latest. There'sno way to pull "the image for release 1.2.3" — which makes rollbacks, reproducible
deploys, and pinning painful. This PR fixes exactly that, while leaving the existing
Docker Hub pipeline completely untouched.
What's included
release-docker.yml— on a published GitHub Release (or a manual run), buildsthe esplora image and pushes
ghcr.io/<owner>/esploratagged1.2.3,1.2, andlatest. Manual runs accept an optional extra tag for testing.base-image.yml— builds and publishesghcr.io/<owner>/esplora-basewhencontrib/Dockerfile.basechanges, or on demand. (It's a heavy build, so it onlyruns when it actually needs to.)
contrib/Dockerfile— addsARG BASE_IMAGEso CI can build on top of the GHCRbase, defaulting to
blockstream/esplora-base:latestso nothing else changes.usage, and setup.
🔑 One-time setup (please do this before merging-to-release)
(the release image builds
FROMthe GHCR base, so it needs to exist first).✅ Safe by design
GITHUB_TOKENonly — no new secrets.amd64only for now (fast, reliable on GitHub-hosted runners); arm64 is a one-lineadd later if we want it.
Pull it once it's live: