prowgen: always add GSM config volumes to multi-stage test jobs - #5351
prowgen: always add GSM config volumes to multi-stage test jobs#5351psalajova wants to merge 1 commit into
Conversation
|
Pipeline controller notification For optional jobs, comment This repository is configured in: automatic mode |
|
Skipping CI for Draft Pull Request. |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: psalajova The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
📝 WalkthroughWalkthroughThe ProwJob generator now always adds ChangesGSM and Secrets Store CSI integration
Estimated code review effort: 2 (Simple) | ~10 minutes Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 17✅ Passed checks (17 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
|
/hold |
efd16f6 to
d63d69f
Compare
|
Note GitHub couldn't provide a complete incremental comparison for this pull request, so CodeRabbit is performing a full review instead. This review may take a little longer. |
Remove the EnableSecretsStoreCSIDriver gate so prowgen unconditionally adds GSM config volumes (gsm-config ConfigMap, gsm-sa-key CSI) and the --enable-secrets-store-csi-driver=true flag to all multi-stage test job specs. Post Vault-to-GSM migration, all credentials use GSM. Making this unconditional ensures new onboarding works without explicitly setting prowgen.enable_secrets_store_csi_driver in the ci-operator config. Container tests already auto-detect GSM references via GSMSecrets() at jobbase.go:166 and are unaffected by this change. DO NOT MERGE until the Vault-to-GSM migration is complete. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
d63d69f to
be757ce
Compare
|
Note GitHub couldn't provide a complete incremental comparison for this pull request, so CodeRabbit is performing a full review instead. This review may take a little longer. |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 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.
Inline comments:
In `@test/integration/pj-rehearse/expected.yaml`:
- Around line 538-543: Update the GSMConfig() mutator to add container-level
securityContext settings for GSM credential containers: runAsNonRoot true,
allowPrivilegeEscalation false, readOnlyRootFilesystem true, and
capabilities.drop containing ALL. Regenerate
test/integration/pj-rehearse/expected.yaml, applying the fixture update at
538-543, 1174-1179, 1321-1326, 1470-1475, 1617-1622, 1881-1886, 2027-2032, and
2173-2178; verify Prow’s base configuration does not already provide these
controls.
🪄 Autofix
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository YAML (base), Central YAML (inherited)
Review profile: CHILL
Plan: Enterprise
Run ID: 76ed0a13-c769-4756-8b75-5ffe8061d806
📒 Files selected for processing (23)
cmd/ci-operator-prowgen/testdata/zz_fixture_presubmit_TestFromCIOperatorConfigToProwYaml_Custom_test_timeout.yamlpkg/controller/ephemeralcluster/testdata/zz_fixture_pj_TestReconcileCreateProwJob_An_EphemeralCluster_request_creates_a_ProwJob.yamlpkg/controller/ephemeralcluster/testdata/zz_fixture_pj_TestReconcileCreateProwJob_Hive_cluster_request_creates_a_ProwJob.yamlpkg/controller/ephemeralcluster/testdata/zz_fixture_pj_TestReconcileCreateProwJob_Privileged_tenant.yamlpkg/controller/prpqr_reconciler/testdata/zz_fixture_prowjobs_TestReconcile_basic_aggregated_case.yamlpkg/controller/prpqr_reconciler/testdata/zz_fixture_prowjobs_TestReconcile_private_repo_aggregated_sets_aggregator_hidden.yamlpkg/prowgen/jobbase.gopkg/prowgen/testdata/zz_fixture_TestNewProwJobBaseBuilderForTest_literal_multi_stage_test.yamlpkg/prowgen/testdata/zz_fixture_TestNewProwJobBaseBuilderForTest_multi_stage_test.yamlpkg/prowgen/testdata/zz_fixture_TestNewProwJobBaseBuilderForTest_multi_stage_test_with_claim.yamlpkg/prowgen/testdata/zz_fixture_TestNewProwJobBaseBuilderForTest_multi_stage_test_with_cluster_profile.yamlpkg/prowgen/testdata/zz_fixture_TestNewProwJobBaseBuilderForTest_multi_stage_test_with_releases.yamltest/integration/ci-operator-prowgen/output/jobs/sharded/repo/sharded-repo-main-presubmits.yamltest/integration/ci-operator-prowgen/output/jobs/super/duper/super-duper-master-presubmits.yamltest/integration/pj-rehearse/candidate/ci-operator/jobs/super/trooper/super-trooper-master-periodics.yamltest/integration/pj-rehearse/candidate/ci-operator/jobs/super/trooper/super-trooper-master-presubmits.yamltest/integration/pj-rehearse/candidate/ci-operator/jobs/uses/observer/uses-observer-master-presubmits.yamltest/integration/pj-rehearse/expected.yamltest/integration/pj-rehearse/master/ci-operator/jobs/super/trooper/super-trooper-master-periodics.yamltest/integration/pj-rehearse/master/ci-operator/jobs/super/trooper/super-trooper-master-presubmits.yamltest/integration/pj-rehearse/master/ci-operator/jobs/uses/observer/uses-observer-master-presubmits.yamltest/integration/repo-init/expected/ci-operator/jobs/org/repo/org-repo-main-presubmits.yamltest/integration/repo-init/expected/ci-operator/jobs/org/third/org-third-nonstandard-presubmits.yaml
🔗 Linked repositories identified
CodeRabbit considers these linked repositories for cross-repo context during reviews:
openshift/release(manual)openshift/ci-docs(manual)openshift/release-controller(manual)openshift/ci-chat-bot(manual)
🚧 Files skipped from review as they are similar to previous changes (22)
- pkg/controller/ephemeralcluster/testdata/zz_fixture_pj_TestReconcileCreateProwJob_Hive_cluster_request_creates_a_ProwJob.yaml
- pkg/prowgen/testdata/zz_fixture_TestNewProwJobBaseBuilderForTest_multi_stage_test_with_claim.yaml
- pkg/prowgen/testdata/zz_fixture_TestNewProwJobBaseBuilderForTest_multi_stage_test.yaml
- test/integration/pj-rehearse/candidate/ci-operator/jobs/super/trooper/super-trooper-master-periodics.yaml
- pkg/controller/ephemeralcluster/testdata/zz_fixture_pj_TestReconcileCreateProwJob_An_EphemeralCluster_request_creates_a_ProwJob.yaml
- pkg/prowgen/testdata/zz_fixture_TestNewProwJobBaseBuilderForTest_literal_multi_stage_test.yaml
- test/integration/pj-rehearse/master/ci-operator/jobs/super/trooper/super-trooper-master-periodics.yaml
- pkg/prowgen/jobbase.go
- test/integration/ci-operator-prowgen/output/jobs/super/duper/super-duper-master-presubmits.yaml
- pkg/controller/prpqr_reconciler/testdata/zz_fixture_prowjobs_TestReconcile_private_repo_aggregated_sets_aggregator_hidden.yaml
- test/integration/repo-init/expected/ci-operator/jobs/org/third/org-third-nonstandard-presubmits.yaml
- cmd/ci-operator-prowgen/testdata/zz_fixture_presubmit_TestFromCIOperatorConfigToProwYaml_Custom_test_timeout.yaml
- pkg/controller/ephemeralcluster/testdata/zz_fixture_pj_TestReconcileCreateProwJob_Privileged_tenant.yaml
- pkg/prowgen/testdata/zz_fixture_TestNewProwJobBaseBuilderForTest_multi_stage_test_with_cluster_profile.yaml
- pkg/prowgen/testdata/zz_fixture_TestNewProwJobBaseBuilderForTest_multi_stage_test_with_releases.yaml
- test/integration/pj-rehearse/master/ci-operator/jobs/super/trooper/super-trooper-master-presubmits.yaml
- test/integration/ci-operator-prowgen/output/jobs/sharded/repo/sharded-repo-main-presubmits.yaml
- test/integration/pj-rehearse/candidate/ci-operator/jobs/uses/observer/uses-observer-master-presubmits.yaml
- pkg/controller/prpqr_reconciler/testdata/zz_fixture_prowjobs_TestReconcile_basic_aggregated_case.yaml
- test/integration/pj-rehearse/master/ci-operator/jobs/uses/observer/uses-observer-master-presubmits.yaml
- test/integration/pj-rehearse/candidate/ci-operator/jobs/super/trooper/super-trooper-master-presubmits.yaml
- test/integration/repo-init/expected/ci-operator/jobs/org/repo/org-repo-main-presubmits.yaml
|
@psalajova: The following tests failed, say
Full PR test history. Your PR dashboard. DetailsInstructions 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. |
Summary
EnableSecretsStoreCSIDrivergate injobbase.go— prowgen now unconditionally adds GSM config volumes (gsm-configConfigMap,gsm-sa-keyCSI) and--enable-secrets-store-csi-driver=trueto all multi-stage test job specs.prowgen: enable_secrets_store_csi_driver: truein the ci-operator config.Context
This is part of the Vault-to-GSM migration plan. After migration day:
enable_secrets_store_csi_driver: trueto all existing configsDO NOT MERGE until the Vault-to-GSM migration is complete.
After merge + image build:
make updatein release repo to regenerate all jobsSummary
prowgennow configures every multi-stage test ProwJob for Google Secret Manager. It enables the Secrets Store CSI driver, passes GSM configuration paths toci-operator, and mounts thegsm-configConfigMap andgsm-sa-keyCSI volume.The
EnableSecretsStoreCSIDrivergate no longer controls multi-stage jobs. New repositories do not needprowgen: enable_secrets_store_csi_driver: true.Unit and integration fixtures now match the generated ProwJob specifications.
Production note
Complete the Vault-to-GSM migration before merging. After building the image, run
make updatein the release repository.