Skip to content

Conversation

@dillon-cullinan
Copy link
Contributor

@dillon-cullinan dillon-cullinan commented Nov 20, 2025

Overview:

Pushes dynamo-base images to ECR on merges to main. We will be able to utilize these for docker caching in a future PR.

Example push: https://github.com/ai-dynamo/dynamo/actions/runs/19547412991/job/55976387455

Summary by CodeRabbit

  • Chores
    • Enhanced container validation workflow with improved image management configuration.
    • Updated build script to support environment variable overrides for base image configuration, enabling greater flexibility in deployment scenarios.

✏️ Tip: You can customize this high-level summary in your review settings.

Signed-off-by: Dillon Cullinan <[email protected]>
@dillon-cullinan dillon-cullinan requested review from a team as code owners November 20, 2025 17:34
@github-actions github-actions bot added the ci Issues/PRs that reference CI build/test label Nov 20, 2025
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Nov 20, 2025

Walkthrough

The pull request updates Docker image building and deployment processes across CI/CD workflows and build scripts. It introduces a new environment variable for dynamo base images in the validation backend workflow, renames existing push steps, and modifies the build script to respect pre-existing environment variables through parameter expansion.

Changes

Cohort / File(s) Summary
CI/CD Workflow Configuration
\.github/workflows/container-validation-backends\.yml
Added DYNAMO_BASE_IMAGE environment variable to vllm job; renamed "Docker Tag and Push" steps to "Push framework runtime image"; introduced new "Push dynamo base image" steps across multiple jobs with branch/arch-specific tagging and AWS/Azure push configuration.
Build Script Logic
container/build\.sh
Changed DYNAMO_BASE_IMAGE initialization from unconditional assignment to conditional parameter expansion (${DYNAMO_BASE_IMAGE:-dynamo-base:$VERSION}), allowing environment variable precedence.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

  • Verify consistent step naming conventions across all affected jobs in the workflow file
  • Confirm environment variable propagation from workflow to build script
  • Validate tag formatting and AWS/Azure push configuration in new push steps

Poem

🐰 A docker rabbit hops with glee,
Base images stacked, one, two, three!
Env vars now lead the way,
Parameters dance and play—
Containers built more gracefully! 🐳

Pre-merge checks

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Description check ⚠️ Warning The PR description is incomplete and missing key sections from the template including Details, Where should the reviewer start, and Related Issues. Add the missing template sections: provide detailed change descriptions, specify files for reviewer focus, and link any related GitHub issues using action keywords.
✅ Passed checks (2 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Title check ✅ Passed The title clearly and specifically summarizes the main change: adding automation to push dynamo base images to ECR on main branch merges, which aligns with the PR objectives and file modifications.

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

📜 Review details

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between d1ce423 and 647364c.

📒 Files selected for processing (2)
  • .github/workflows/container-validation-backends.yml (5 hunks)
  • container/build.sh (1 hunks)
🧰 Additional context used
🧠 Learnings (6)
📓 Common learnings
Learnt from: grahamking
Repo: ai-dynamo/dynamo PR: 1177
File: container/Dockerfile.vllm:102-105
Timestamp: 2025-05-28T22:54:46.875Z
Learning: In Dockerfiles, when appending to environment variables that may not exist in the base image, Docker validation will fail if you reference undefined variables with ${VARIABLE} syntax. In such cases, setting the environment variable directly (e.g., ENV CPATH=/usr/include) rather than appending is the appropriate approach.
Learnt from: keivenchang
Repo: ai-dynamo/dynamo PR: 3051
File: container/templates/Dockerfile.vllm.j2:221-233
Timestamp: 2025-09-16T17:16:07.820Z
Learning: In the dynamo project, when converting Dockerfiles to Jinja2 templates, the primary goal is backward compatibility - generated Dockerfiles must be identical to the originals. Security improvements or other enhancements that would change the generated output are out of scope for templating PRs and should be addressed separately.
Learnt from: keivenchang
Repo: ai-dynamo/dynamo PR: 2797
File: container/Dockerfile:437-449
Timestamp: 2025-08-30T20:43:49.632Z
Learning: In the dynamo project's devcontainer setup, the team prioritizes consistency across framework-specific Dockerfiles (like container/Dockerfile, container/Dockerfile.vllm, etc.) by mirroring their structure, even when individual optimizations might be possible, to maintain uniformity in the development environment setup.
Learnt from: keivenchang
Repo: ai-dynamo/dynamo PR: 2797
File: .devcontainer/devcontainer.json:12-12
Timestamp: 2025-08-30T20:43:10.091Z
Learning: In the dynamo project, devcontainer.json files use templated container names (like "dynamo-vllm-devcontainer") that are automatically processed by the copy_devcontainer.sh script to generate framework-specific configurations with unique names, preventing container name collisions.
Learnt from: keivenchang
Repo: ai-dynamo/dynamo PR: 2822
File: container/Dockerfile.vllm:343-352
Timestamp: 2025-09-03T01:10:12.599Z
Learning: In the dynamo project's local-dev Docker targets, USER_UID and USER_GID build args are intentionally left without default values to force explicit UID/GID mapping during build time, preventing file permission issues in local development environments where container users need to match host user permissions for mounted volumes.
Learnt from: keivenchang
Repo: ai-dynamo/dynamo PR: 2797
File: .devcontainer/devcontainer.json:12-12
Timestamp: 2025-08-30T20:43:10.091Z
Learning: In the dynamo project's devcontainer setup, hard-coded container names in devcontainer.json files serve as templates that are automatically processed by the copy_devcontainer.sh script to generate framework-specific configurations with unique names, preventing container name collisions.
📚 Learning: 2025-05-28T22:54:46.875Z
Learnt from: grahamking
Repo: ai-dynamo/dynamo PR: 1177
File: container/Dockerfile.vllm:102-105
Timestamp: 2025-05-28T22:54:46.875Z
Learning: In Dockerfiles, when appending to environment variables that may not exist in the base image, Docker validation will fail if you reference undefined variables with ${VARIABLE} syntax. In such cases, setting the environment variable directly (e.g., ENV CPATH=/usr/include) rather than appending is the appropriate approach.

Applied to files:

  • container/build.sh
📚 Learning: 2025-09-16T17:16:07.820Z
Learnt from: keivenchang
Repo: ai-dynamo/dynamo PR: 3051
File: container/templates/Dockerfile.vllm.j2:221-233
Timestamp: 2025-09-16T17:16:07.820Z
Learning: In the dynamo project, when converting Dockerfiles to Jinja2 templates, the primary goal is backward compatibility - generated Dockerfiles must be identical to the originals. Security improvements or other enhancements that would change the generated output are out of scope for templating PRs and should be addressed separately.

Applied to files:

  • container/build.sh
  • .github/workflows/container-validation-backends.yml
📚 Learning: 2025-08-30T20:43:10.091Z
Learnt from: keivenchang
Repo: ai-dynamo/dynamo PR: 2797
File: .devcontainer/devcontainer.json:12-12
Timestamp: 2025-08-30T20:43:10.091Z
Learning: In the dynamo project, devcontainer.json files use templated container names (like "dynamo-vllm-devcontainer") that are automatically processed by the copy_devcontainer.sh script to generate framework-specific configurations with unique names, preventing container name collisions.

Applied to files:

  • container/build.sh
  • .github/workflows/container-validation-backends.yml
📚 Learning: 2025-08-30T20:43:49.632Z
Learnt from: keivenchang
Repo: ai-dynamo/dynamo PR: 2797
File: container/Dockerfile:437-449
Timestamp: 2025-08-30T20:43:49.632Z
Learning: In the dynamo project's devcontainer setup, the team prioritizes consistency across framework-specific Dockerfiles (like container/Dockerfile, container/Dockerfile.vllm, etc.) by mirroring their structure, even when individual optimizations might be possible, to maintain uniformity in the development environment setup.

Applied to files:

  • container/build.sh
  • .github/workflows/container-validation-backends.yml
📚 Learning: 2025-08-30T20:43:10.091Z
Learnt from: keivenchang
Repo: ai-dynamo/dynamo PR: 2797
File: .devcontainer/devcontainer.json:12-12
Timestamp: 2025-08-30T20:43:10.091Z
Learning: In the dynamo project's devcontainer setup, hard-coded container names in devcontainer.json files serve as templates that are automatically processed by the copy_devcontainer.sh script to generate framework-specific configurations with unique names, preventing container name collisions.

Applied to files:

  • .github/workflows/container-validation-backends.yml
🔇 Additional comments (3)
container/build.sh (1)

845-846: Parameter expansion allows flexible base image control. The change correctly preserves externally-set DYNAMO_BASE_IMAGE while defaulting to a version-based tag for local builds. This integrates well with the CI/CD workflow.

.github/workflows/container-validation-backends.yml (2)

135-136: Environment variable setup for base image caching. The hardcoded dynamo-base:latest tag enables consistent Docker layer caching across CI runs. This will be passed to build.sh where it overrides the VERSION-based default, ensuring all builds reference the same base image tag.


162-174: Step name clarification improves CI log readability. Renaming from "Docker Tag and Push" to "Push framework runtime image" makes it clear these steps push framework-specific builds, distinct from the base image push. Consistent naming across all three jobs (vllm, sglang, trtllm).

Also applies to: 242-254, 309-321

Signed-off-by: Dillon Cullinan <[email protected]>
Signed-off-by: Dillon Cullinan <[email protected]>
@dillon-cullinan dillon-cullinan changed the title ci: OPS-2135: Test push dynamo base image ci: OPS-2135: Push dynamo base image on main merges Nov 20, 2025
@dillon-cullinan dillon-cullinan enabled auto-merge (squash) November 20, 2025 20:38
azure_push: 'false'
aws_account_id: ${{ secrets.AWS_ACCOUNT_ID }}
aws_default_region: ${{ secrets.AWS_DEFAULT_REGION }}
azure_acr_hostname: ${{ secrets.AZURE_ACR_HOSTNAME }}
Copy link
Contributor

Choose a reason for hiding this comment

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

Lets remove the azure credentials from here. Only AWS credentials are needed if azure_push is false.

Copy link
Contributor Author

@dillon-cullinan dillon-cullinan Nov 21, 2025

Choose a reason for hiding this comment

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

Ack. This change does not actually effect functionality.

For the sake of not running through CI again, I will make this commit in the followup PR, unless I must make another commit for a diff reason: #4535

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

Labels

ci Issues/PRs that reference CI build/test size/S

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants