Skip to content

fix(dev-infrastructure): scope acr-replication/postgres-access/grafana-group-roles workingDir - #6398

Merged
2 commits merged into
Azure:mainfrom
raelga:rael/aroslsre-1699-scope-workingdir
Aug 4, 2026
Merged

fix(dev-infrastructure): scope acr-replication/postgres-access/grafana-group-roles workingDir#6398
2 commits merged into
Azure:mainfrom
raelga:rael/aroslsre-1699-scope-workingdir

Conversation

@raelga

@raelga Rael Garcia (raelga) commented Aug 4, 2026

Copy link
Copy Markdown
Collaborator

What

Scope workingDir for the acr-replication, postgres-access, and grafana-group-roles Shell steps to their own scripts/<name> subfolder instead of the repo root (.), matching the existing pattern used by housekeeping, upgrade-aks-cluster, oidc-storage-setup, cleanup-prometheus-pvc, and istio-upgrade (which all set workingDir: ./scripts).

Follow-up to AROSLSRE-1699 raised on the review of #6369.

Affected steps:

  • ocp-acr-replication / svc-acr-replication in dev-infrastructure/region-pipeline.yaml
  • cs-postgres-access / maestro-postgres-access in dev-infrastructure/svc-pipeline.yaml
  • grafana-group-roles in dev-infrastructure/global-pipeline-stg.yaml

workingDir changes from . to ./scripts/acr-replication / ./scripts/postgres-access / ./scripts/grafana-group-roles, and command becomes relative to that.

Why

workingDir has to stay non-empty, EV2 needs it set to build a scoped package archive for the step. Unsetting it falls back to the implicit whole-repo archive, which fails in EV2. With workingDir: . the package that gets archived and content-hashed is the entire repo, so the incremental-rollout cache key is effectively decoupled from what the step actually depends on. Scoping it down to the step's own scripts/<name> folder keeps the same non-empty-workingDir requirement, but makes the archived/hashed content actually reflect that step's own inputs.

Testing

  • templatize pipeline validate --topology-config-file topology.yaml --service-config-file config/config.yaml --dev-mode --dev-region westus3 passes on all changed pipelines.
  • Checked main.go in scripts/acr-replication, scripts/postgres-access, and scripts/grafana-group-roles for any relative-path assumptions beyond the working directory itself, none found (they only read env vars).

…r own script folder (AROSLSRE-1699)

Point ocp-acr-replication, svc-acr-replication, cs-postgres-access, and
maestro-postgres-access at their own scripts/<name> subfolder instead of
the repo root, matching the pattern already used by housekeeping,
upgrade-aks-cluster, oidc-storage-setup, cleanup-prometheus-pvc, and
istio-upgrade.

workingDir stays non-empty (required for EV2's scoped-package archiving,
unsetting it breaks EV2), but the archive is now limited to the step's
own script directory instead of the whole repo. This lets the
incremental-rollout content-hash actually reflect that script's inputs,
instead of effectively depending on the entire monorepo's content.

command is updated to be relative to the new workingDir.
Copilot AI previously approved these changes Aug 4, 2026

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.

🟢 Ready to approve

The updated workingDir and relative command paths align with existing pipeline patterns and remain consistent with where the prebuilt binaries are produced.

This review doesn't count toward merge requirements. Sign up for the private preview to control whether Copilot approvals count.

Pull request overview

Scopes EV2 Shell step workingDir to each Go helper’s script directory so the archived/hashed step package matches the step’s actual runtime inputs (instead of content-hashing the entire repo), improving incremental-rollout cache correctness for regional ACR replication and Postgres access helpers.

Changes:

  • Update cs-postgres-access and maestro-postgres-access steps to run from ./scripts/postgres-access with a relative ./postgres-access command.
  • Update ocp-acr-replication and svc-acr-replication steps to run from ./scripts/acr-replication with a relative ./acr-replication command.
File summaries
File Description
dev-infrastructure/svc-pipeline.yaml Scopes Postgres access Shell steps to ./scripts/postgres-access and makes the command relative to that directory.
dev-infrastructure/region-pipeline.yaml Scopes ACR replication Shell steps to ./scripts/acr-replication and makes the command relative to that directory.
Review details
  • Files reviewed: 2/2 changed files
  • Comments generated: 0
  • Review effort level: Lite

We're testing this review assessment. Please use 👍 or 👎 to tell us if it's correct.

…own script folder (AROSLSRE-1699)

Same fix as the acr-replication/postgres-access steps: point workingDir
at scripts/grafana-group-roles instead of the repo root, so the EV2
package archive and incremental-rollout cache key actually reflect this
step's own inputs.
Copilot AI review requested due to automatic review settings August 4, 2026 10:09
@roivaz

Copy link
Copy Markdown
Collaborator

/lgtm
/approve

@openshift-ci openshift-ci Bot added the lgtm label Aug 4, 2026
Copilot AI dismissed their stale review, a newer Copilot review was requested August 4, 2026 10:12
Copilot AI previously approved these changes Aug 4, 2026

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.

🟢 Ready to approve

The updated workingDir/command values align with where each pipeline’s buildStep places the compiled binaries, with no other step inputs referenced from the repo root.

This review doesn't count toward merge requirements. Sign up for the private preview to control whether Copilot approvals count.

Review details
  • Files reviewed: 3/3 changed files
  • Comments generated: 0 new
  • Review effort level: Lite

We're testing this review assessment. Please use 👍 or 👎 to tell us if it's correct.

Copilot AI review requested due to automatic review settings August 4, 2026 10:50
@openshift-ci openshift-ci Bot removed the lgtm label Aug 4, 2026
@raelga Rael Garcia (raelga) changed the title fix(dev-infrastructure): scope acr/postgres-access workingDir to their own script folder fix(dev-infrastructure): scope acr-replication workingDir and simplify replication-state config Aug 4, 2026
Copilot AI dismissed their stale review, a newer Copilot review was requested August 4, 2026 10:54
Copilot AI previously approved these changes Aug 4, 2026

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.

🟢 Ready to approve

The changes are consistent across pipelines/config/schema, maintain prior behavior via per-region override, and include updated unit tests for the new env var parsing.

This review doesn't count toward merge requirements. Sign up for the private preview to control whether Copilot approvals count.

Review details
  • Files reviewed: 14/14 changed files
  • Comments generated: 0 new
  • Review effort level: Lite

We're testing this review assessment. Please use 👍 or 👎 to tell us if it's correct.

Copilot AI review requested due to automatic review settings August 4, 2026 11:05
@raelga
Rael Garcia (raelga) force-pushed the rael/aroslsre-1699-scope-workingdir branch from a790739 to 830c365 Compare August 4, 2026 11:05
@raelga Rael Garcia (raelga) changed the title fix(dev-infrastructure): scope acr-replication workingDir and simplify replication-state config fix(dev-infrastructure): scope acr-replication/postgres-access/grafana-group-roles workingDir Aug 4, 2026
@roivaz

Copy link
Copy Markdown
Collaborator

/lgtm

@openshift-ci openshift-ci Bot added the lgtm label Aug 4, 2026
@openshift-ci

openshift-ci Bot commented Aug 4, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: raelga, roivaz

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Copilot AI dismissed their stale review, a newer Copilot review was requested August 4, 2026 11:07

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.

🟢 Ready to approve

The updated workingDir values align with where the build steps emit the binaries and the commands are correctly adjusted to remain executable from the new directories.

This review doesn't count toward merge requirements. Sign up for the private preview to control whether Copilot approvals count.

Review details
  • Files reviewed: 3/3 changed files
  • Comments generated: 0 new
  • Review effort level: Lite

We're testing this review assessment. Please use 👍 or 👎 to tell us if it's correct.

@openshift-ci

openshift-ci Bot commented Aug 4, 2026

Copy link
Copy Markdown

Rael Garcia (@raelga): The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/e2e-parallel 830c365 link true /test e2e-parallel

Full PR test history. Your PR dashboard.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here.

@openshift-merge-bot openshift-merge-bot Bot closed this pull request by merging all changes into Azure:main in ff3ae36 Aug 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants