Skip to content

Ymagen/docker release images#96

Open
yohaimagen wants to merge 174 commits intodmay/stagingfrom
ymagen/docker-release-images
Open

Ymagen/docker release images#96
yohaimagen wants to merge 174 commits intodmay/stagingfrom
ymagen/docker-release-images

Conversation

@yohaimagen
Copy link
Copy Markdown
Collaborator

Add Docker release images and CI workflow

Summary

This PR adds pre-built Docker release images for Tandem, published to GitHub Container Registry (GHCR). Users can now run any Tandem configuration without compiling from source.


What's included

Docker infrastructure (docker/release/)

Three Dockerfiles implement a two-stage (builder + slim runtime) pipeline:

File Purpose
Dockerfile.base Builds the shared base image: Ubuntu 22.04 + OpenMPI + PETSc + Eigen + Tandem source
Dockerfile.release Builds a single configuration (parameterised by DIM and DEG) on top of the base
Dockerfile.all Builds all 12 configurations (2D/3D × degrees 1–6) in one image and installs named wrapper scripts (tandem_2d_6p_tandem, tandem_3d_3p_tandem, …)

All images:

  • Target linux/amd64 only
  • Run as a non-root tandem user
  • Bundle example input files at /work/examples/

CI workflow (.github/workflows/release-images.yml)

Three-job GitHub Actions pipeline:

  1. build-base — builds and pushes ghcr.io/tear-erc/tandem-base with a run-specific tag to avoid :latest races.
  2. build-images — matrix job (2 dims × 6 degrees = 12 parallel builds) that produces individual images ghcr.io/tear-erc/tandem:<dim>d-<deg>p.
  3. build-all — builds the all-in-one image ghcr.io/tear-erc/tandem:all.

Triggers:

  • Push to this branch or changes to docker/release/** / the workflow file itself (for development/testing)
  • Git tags matching v* (versioned release) → also pushes :2d-6p, :2d-6p-1.2.0, :all, :all-1.2.0 tags

Documentation (docs/getting-started/)

  • New page docker-release.rst — covers prerequisites (Docker + host-side Gmsh), the all-in-one image, versioning strategy, volume mounting (-v $(pwd):/host to avoid shadowing /work/examples), MPI usage, and a step-by-step example workflow (copy .geo + .toml out → generate mesh with Gmsh on host → run inside container).
  • Removed quick-start.rst — the old development Docker workflow (compile-from-source inside a dev container) is no longer the recommended entry point.
  • Updated getting-started/index.rst — toctree and intro text updated to point users to the release images first, then the installation guide for custom builds.
  • Updated docs/index.rst — added a one-line GHCR mention on the main landing page.

Tagging strategy

Trigger Tags pushed
Branch push :all-<branch-name>, :2d-6p-<branch-name> (testing only)
v* git tag :all, :all-latest, :all-1.2.0, :2d-6p, :2d-6p-latest, :2d-6p-1.2.0

@dmay23 I do not have the permission to make those images public
The GHCR package ghcr.io/tear-erc/tandem is currently private — this is GitHub's default for newly created packages
To make the images publicly pullable without authentication, an org admin needs to change the visibility once:

Go to https://github.com/orgs/TEAR-ERC/packages/container/tandem/settings
scroll to Danger Zone → Change visibility → Public
This is a one-time action — all future tags pushed to these packages will automatically inherit public visibility.

piyushkarki and others added 18 commits March 24, 2026 20:08
- Add docs/getting-started/docker-release.rst covering pre-built GHCR
  images, versioning, volume mounting, MPI usage, Gmsh mesh workflow,
  and bundled examples
- Remove outdated quick-start.rst (development Docker build)
- Update getting-started/index.rst: add docker-release to toctree,
  remove quick-start, update intro text
- Update docs/index.rst: add GHCR mention on landing page
Add gmsh to the runtime apt dependencies in both Dockerfile.release and
Dockerfile.all so users can generate meshes directly inside the container.
Update docs to remove the host-Gmsh prerequisite and adjust the example
workflow accordingly.
@yohaimagen yohaimagen force-pushed the ymagen/docker-release-images branch from 6342553 to fd029ed Compare March 24, 2026 19:50
Yohai Magen and others added 4 commits March 24, 2026 13:51
…openblas.so.0

PETSc in the builder (tandem-base:3.22.5) links against libopenblas.so.0,
but the runtime stage only installed libblas3 which provides libblas.so.3.
Adding libopenblas0-pthread supplies the exact SONAME the binaries need.
PETSc is compiled with ParMETIS support; libparmetis.so.4.0 is a
transitive runtime dependency not covered by the previous package list.
@yohaimagen
Copy link
Copy Markdown
Collaborator Author

@piyushkarki @Thomas-Ulrich

This is ready to be merged downstream to Piyus's PR.

Note on ARM CPUs. I managed to create a working image built on my laptop, but was not able to create one that can be built on GitHub and run on my Mac M3. For now, I've put all those attempts on a new bench (ymagen/arm-release-images) and will revisit them later when I have more time.

@Thomas-Ulrich
Copy link
Copy Markdown
Collaborator

Ok, I won't have time to look at it again because of the force-push, which prevents me from identifying the new changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants