Skip to content

ci: publish research and trading images to ACR - #14

Merged
proerror77 merged 3 commits into
mainfrom
codex/acr-publish
Jul 14, 2026
Merged

proerror77 merged 3 commits into
mainfrom
codex/acr-publish

Conversation

@proerror77

@proerror77 proerror77 commented Jul 14, 2026

Copy link
Copy Markdown
Owner

Summary

  • add a manual ACR image publication workflow
  • build native linux/amd64 research and trading images from the existing Dockerfiles
  • publish commit-SHA tags and record immutable digests

Configuration

  • GitHub variables: ACR_REGISTRY, ACR_USERNAME
  • GitHub secret: ACR_PASSWORD
  • ACR namespace: monday
  • repositories: research-runner, hft-trading

Review

  • Standards: pass (0 findings)
  • Spec: pass (0 findings)
  • YAML parse: pass
  • git diff --check: pass

Summary by CodeRabbit

  • Chores
    • Added a manually triggered workflow for publishing Docker images to Azure Container Registry.
    • Supports building and publishing the research runner and high-frequency trading images for Linux AMD64.
    • Uses commit-specific image tags and records published image digests for traceability.
    • Includes build caching to improve repeat build performance and controlled concurrency to prevent conflicting runs.

@coderabbitai

coderabbitai Bot commented Jul 14, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@proerror77, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 47 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 9f47b9fb-9ea9-4f90-9104-0303de282612

📥 Commits

Reviewing files that changed from the base of the PR and between e5fca20 and ebd7bec.

📒 Files selected for processing (3)
  • .github/workflows/acr-publish.yml
  • deployment/aliyun/research/k8s/alpha-mission-job.example.yaml
  • deployment/aliyun/research/k8s/backtest-job.example.yaml
📝 Walkthrough

Walkthrough

Adds a manually triggered GitHub Actions workflow that builds and pushes research-runner and hft-trading Docker images to Azure Container Registry, using Buildx caching and recording immutable digests in the job summary.

Changes

ACR image publishing

Layer / File(s) Summary
Build and publish ACR images
.github/workflows/acr-publish.yml
Defines a manual, ref-concurrent workflow with scoped permissions, a two-image build matrix, ACR authentication, Linux AMD64 Docker builds, per-repository caching, SHA-based tags, and digest summaries.

Estimated code review effort: 2 (Simple) | ~10 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly summarizes the main change: publishing research and trading images to ACR via CI.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/acr-publish

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.


steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v4

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
uses: docker/setup-buildx-action@v3

- name: Log in to ACR
uses: docker/login-action@v3

- name: Build and push
id: build
uses: docker/build-push-action@v6

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🧹 Nitpick comments (2)
.github/workflows/acr-publish.yml (2)

26-27: 🔒 Security & Privacy | 🔵 Trivial | 💤 Low value

Disable credential persistence in the checkout action.

As flagged by static analysis, the actions/checkout action persists the GITHUB_TOKEN in the local git configuration by default. Since this workflow only needs to read the repository contents to build the Docker image, it is a security best practice to disable credential persistence. This minimizes the token's exposure to subsequent steps or the Docker build environment.

🛡️ Proposed fix to disable credential persistence
       - name: Checkout
         uses: actions/checkout@v4
+        with:
+          persist-credentials: false
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In @.github/workflows/acr-publish.yml around lines 26 - 27, Update the
actions/checkout@v4 step in the workflow to disable credential persistence by
configuring its persist-credentials input to false, while leaving the existing
checkout behavior unchanged.

Source: Linters/SAST tools


51-53: 🔒 Security & Privacy | 🔵 Trivial | 💤 Low value

Pass variables to the run script via environment variables.

As flagged by static analysis, interpolating GitHub Actions expressions (${{ ... }}) directly into a run script can expose the workflow to shell injection risks if any variable unexpectedly contains quotes. Although the specific variables used here are trusted and unlikely to contain malicious characters, passing them via environment variables is a strong security best practice that prevents quoting issues entirely.

🛡️ Proposed fix to securely pass variables
       - name: Record immutable image
+        env:
+          REGISTRY: ${{ vars.ACR_REGISTRY }}
+          REPOSITORY: ${{ matrix.repository }}
+          DIGEST: ${{ steps.build.outputs.digest }}
         run: |
-          echo '${{ matrix.repository }}=${{ vars.ACR_REGISTRY }}/monday/${{ matrix.repository }}@${{ steps.build.outputs.digest }}' >> "$GITHUB_STEP_SUMMARY"
+          echo "${REPOSITORY}=${REGISTRY}/monday/${REPOSITORY}@${DIGEST}" >> "$GITHUB_STEP_SUMMARY"
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In @.github/workflows/acr-publish.yml around lines 51 - 53, Update the “Record
immutable image” step to pass matrix.repository, vars.ACR_REGISTRY, and
steps.build.outputs.digest through the step’s environment, then reference those
environment variables in the shell command instead of interpolating GitHub
Actions expressions directly in run. Preserve the existing summary format and
image digest value.

Source: Linters/SAST tools

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Nitpick comments:
In @.github/workflows/acr-publish.yml:
- Around line 26-27: Update the actions/checkout@v4 step in the workflow to
disable credential persistence by configuring its persist-credentials input to
false, while leaving the existing checkout behavior unchanged.
- Around line 51-53: Update the “Record immutable image” step to pass
matrix.repository, vars.ACR_REGISTRY, and steps.build.outputs.digest through the
step’s environment, then reference those environment variables in the shell
command instead of interpolating GitHub Actions expressions directly in run.
Preserve the existing summary format and image digest value.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 74c4f32d-0461-4ea6-a215-05fe2e8ca0d0

📥 Commits

Reviewing files that changed from the base of the PR and between 3538575 and e5fca20.

📒 Files selected for processing (1)
  • .github/workflows/acr-publish.yml

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: e5fca20162

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

context: rust_hft
file: ${{ matrix.file }}
platforms: linux/amd64
push: true

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Gate ACR publishing to the reviewed main ref

When this manually dispatched workflow is run from a non-main ref (the Actions UI/gh workflow run --ref allow selecting a branch), this unconditional push: true builds whatever Dockerfiles and source are on that branch and publishes them to the shared ACR under a commit-SHA tag. That lets unreviewed branch code produce monday/research-runner and monday/hft-trading images with production registry credentials; add a main-ref guard or pin checkout/push provenance before pushing.

Useful? React with 👍 / 👎.

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