Skip to content
This repository was archived by the owner on Nov 23, 2025. It is now read-only.

chore: backport update-manifest yq fix to main#22

Merged
RandithaK merged 2 commits intomainfrom
dev
Nov 14, 2025
Merged

chore: backport update-manifest yq fix to main#22
RandithaK merged 2 commits intomainfrom
dev

Conversation

@RandithaK
Copy link
Copy Markdown
Member

@RandithaK RandithaK commented Nov 14, 2025

Backport: Update K8s Manifest changed to use yq --arg; make the same fix on main to avoid failing runs when main branch builds succeed

Summary by CodeRabbit

  • Chores
    • Improved the robustness of the CI/CD deployment process by refining manifest update mechanisms to ensure more reliable and consistent deployment workflows on cloud infrastructure.

Copilot AI review requested due to automatic review settings November 14, 2025 22:47
@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Nov 14, 2025

Walkthrough

A GitHub Actions workflow is updated to replace yq command invocation that relied on env(NEW_IMAGE) environment variable substitution with a more robust --arg pattern, eliminating the need for explicit environment variable export.

Changes

Cohort / File(s) Change Summary
Workflow script adjustment
.github/workflows/update-manifest.yaml
Refactored yq invocation from env(NEW_IMAGE) to --arg new_image pattern for more reliable variable substitution on GitHub runners; removed related environment export statement

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

  • Single file modified with focused, repetitive change pattern
  • Straightforward refactor of command invocation syntax
  • No complex logic or multi-file coordination required

Poem

🐰 A workflow once whispered to yq with env,
But args spoke clearer—a path to convene,
No exports now needed, just --arg and $new_image,
Where GitHub's runners dance without baggage! ✨

Pre-merge checks and finishing touches

✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: backporting a yq fix to the update-manifest workflow to the main branch.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch dev

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 6c27fab and 1b36f0b.

📒 Files selected for processing (1)
  • .github/workflows/update-manifest.yaml (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: Build & Push Docker Image
🔇 Additional comments (2)
.github/workflows/update-manifest.yaml (2)

51-54: ✅ Solid fix for robust variable substitution.

The change from env(NEW_IMAGE) to --arg new_image is the correct pattern for yq. This approach avoids shell variable expansion issues on GitHub runners and is more reliable. The filter logic correctly selects Deployment resources and updates the container image.

However, please verify that the yq version installed on line 38 supports yq eval. Newer versions may use yq directly instead of yq eval.Based on the search results, in yq4, invoking "yq" by default now invokes the all-in-one "eval" function, and as of 4.18.1 this is the default command when none is supplied to yq. This means yq eval is backward compatible and will continue to work on all recent yq v4 versions installed via the latest release download (line 38). The syntax is correct.


46-55: Verify that k8s/services/auth-deployment.yaml exists in the TechTorque-2025/k8s-config repository.

The workflow explicitly checks out the k8s-config repository (line 24-27) and assumes the path k8s/services/auth-deployment.yaml exists when it attempts the yq update (line 54). The workflow will fail silently or with unclear errors if this path structure doesn't exist. Since the k8s-config repository is separate from this codebase, manual verification is required to confirm the deployment file exists at the expected location in that repository.


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
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR backports a yq command fix from another branch to main, replacing the env() function with the --arg parameter for improved robustness on GitHub runners.

  • Changed yq command to use --arg parameter instead of env() function for passing the image tag variable
  • Added explanatory comment about the rationale for using --arg
  • Removed trailing whitespace

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@RandithaK RandithaK merged commit 986f73c into main Nov 14, 2025
12 checks passed
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants