Skip to content

Julia Docker Fix And UX Improvements - #931

Open
calvinp0 wants to merge 1 commit into
mainfrom
feature_docker_ux
Open

Julia Docker Fix And UX Improvements#931
calvinp0 wants to merge 1 commit into
mainfrom
feature_docker_ux

Conversation

@calvinp0

Copy link
Copy Markdown
Member

This pull request makes significant improvements to the Docker image build process and interactive shell experience for ARC. The changes streamline the build context, improve reproducibility and provenance tracking, and overhaul the interactive command wrappers for a more robust and user-friendly workflow. Documentation is updated to match these enhancements.

Docker build and provenance improvements:

  • Adds a comprehensive .dockerignore to minimize build context size, improving build performance and reliability.
  • Updates the Dockerfile to record exact commit SHAs for ARC, RMG-Py, and RMG-database in an image_versions.env file, and exposes this provenance via an OCI label and in-shell display. [1] [2] [3]
  • Ensures consistent and correct conda channel configuration is carried into the runtime image, avoiding missing dependency pins. [1] [2]
  • Sets up Julia and Python/Julia integration more robustly, including architecture-specific environment variables for cross-platform support. [1] [2]

Interactive shell and command runner overhaul:

  • Replaces previous hard-coded aliases for arc, arcrestart, rmg, and arkane with shell functions that forward arguments and dispatch via a shared helper script (arc_job_helpers.sh), ensuring interactive and non-interactive invocations behave identically. [1] [2]
  • Updates the aliases cheat-sheet and documentation to reflect the new argument-forwarding behavior and log handling. [1] [2]

Continuous integration and build workflow enhancements:

  • Refactors the GitHub Actions workflow to support manual dispatch, scheduled builds, and improved conditional logic for building, testing, and publishing images. [1] [2] [3] [4]
  • Ensures the ARC commit SHA is passed as a build argument and OCI label for all build paths, improving traceability. [1] [2]

Documentation updates:

  • Documents platform support, new shell behavior, and provenance tracking for users. [1] [2] [3]

Dependency and environment fixes:

  • Removes unnecessary packages (e.g., sudo) from the Docker image, reducing attack surface and image size.

These changes collectively make the ARC Docker image more efficient, transparent, and user-friendly for both interactive and automated workflows.

@calvinp0
calvinp0 requested review from alongd and Copilot and removed request for Copilot July 28, 2026 09:20
@calvinp0

Copy link
Copy Markdown
Member Author

This supersedes #910

@codecov

codecov Bot commented Jul 28, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 63.44%. Comparing base (9787770) to head (a0f588b).

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #931      +/-   ##
==========================================
- Coverage   63.45%   63.44%   -0.01%     
==========================================
  Files         114      114              
  Lines       38325    38325              
  Branches    10030    10030              
==========================================
- Hits        24319    24316       -3     
+ Misses      11089    11088       -1     
- Partials     2917     2921       +4     
Flag Coverage Δ
functionaltests 63.44% <ø> (-0.01%) ⬇️
unittests 63.44% <ø> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copilot AI review requested due to automatic review settings July 28, 2026 14:03

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

The published image had been failing to build since ~2026-06-10, and the
interactive commands it ships were dead on arrival. This reworks both, plus
the workflow that builds it.

Build:
- install_rms.sh runs `conda install 'conda-forge::pyjuliacall<0.9.35'`, but
  the micromamba base ships no .condarc, so that died with
  NoChannelsConfiguredError and silently dropped RMG's protective pin.
  juliacall 0.9.35 then landed and resolved sys.so against the juliaup
  launcher shim, failing with "could not load library .../lib/julia/sys.so".
  A ~/.condarc with conda-forge makes RMG's own pin apply; the Dockerfile
  pre-install is pinned too, and .condarc now ships in the final image so a
  runtime `conda install` does not hit the same error.
- Copy ~/.julia into the final stage. ~/.juliaup is only the ~14 MB launcher,
  so the shipped image previously contained no working Julia at all.
- JULIA_CPU_TARGET was comma-separated, but ';' separates targets while ','
  separates features within one target, so Julia read the whole list as a
  single x86-64 target plus bogus features and baked one generic pkgimage.
  Measured on Julia 1.10.11 via Base.parse_image_targets: 1 target before,
  11 after. The list is byte-identical to RMG-Py/Dockerfile:78 in names and
  order, which carries the same defect and is being fixed upstream.
- Pin JULIAUP_DEPOT_PATH. juliaup reads its channel config from
  $HOME/.julia/juliaup/juliaup.json, but `docker exec` and any --entrypoint
  override run as root with HOME=/root rather than going through
  entrywrapper.sh's `runuser -u mambauser`; juliaup then finds no config and
  fetches a newer Julia over the network, bypassing the pinned 1.10 and every
  pkgimage baked above. Note it is JULIAUP_DEPOT_PATH, not JULIA_DEPOT_PATH.

Interactive shell:
- The arc/arcrestart/rmg/arkane aliases hardcoded the input filename,
  discarded "$@", and invoked base-env `python` - which does not exist, so
  all four exited 127. They are now functions that forward arguments through
  entrywrapper.sh itself, so interactive and non-interactive invocations
  cannot drift apart.
- Land the shell in arc_env via micromamba's own activation hook.

Image and CI:
- Add .dockerignore: build context 161 MB -> 31 MB measured.
- OCI labels, plus resolved ARC/RMG-Py/RMG-database commit SHAs recorded in
  image_versions.env, since LABEL cannot read RUN output.
- Drop unused sudo and a duplicated make.
- The `schedule` runs were falsely green: neither build step's `if:` matched,
  so nothing was built. schedule now takes the push-to-main path, and
  workflow_dispatch is enabled on the no-push path.
@calvinp0
calvinp0 force-pushed the feature_docker_ux branch from 22c1202 to a0f588b Compare July 29, 2026 07:20
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.

2 participants