Skip to content

ESO-334: Adds implementation logic for Environment Variables to support customizations at install time#106

Open
siddhibhor-56 wants to merge 1 commit intoopenshift:mainfrom
siddhibhor-56:env-var
Open

ESO-334: Adds implementation logic for Environment Variables to support customizations at install time#106
siddhibhor-56 wants to merge 1 commit intoopenshift:mainfrom
siddhibhor-56:env-var

Conversation

@siddhibhor-56
Copy link
Contributor

No description provided.

@coderabbitai
Copy link

coderabbitai bot commented Feb 3, 2026

Walkthrough

This change extends the external secrets deployment controller to support per-container configuration by adding container name constants, modifying function signatures to return container identifiers alongside component names, introducing environment variable merging logic, and adding comprehensive test coverage for the new functionality.

Changes

Cohort / File(s) Summary
Container Name Constants
pkg/controller/external_secrets/constants.go
Added four unexported constants defining container names: controllerContainerName, webhookContainerName, certControllerContainerName, and bitwardenContainerName.
Deployment Configuration Logic
pkg/controller/external_secrets/deployments.go
Updated getComponentNameFromAsset signature to return a tuple of (ComponentName, container name, error). Added new mergeEnvVars function to merge user-specified environment variables into containers with user-provided values taking precedence. Modified applyUserDeploymentConfigs to retrieve and apply environment variable overrides to the matched container.
Deployment Tests
pkg/controller/external_secrets/deployments_test.go
Updated existing tests to handle the new three-value return signature of getComponentNameFromAsset. Added TestMergeEnvVars to validate environment variable merging behavior (override, add, ValueFrom scenarios). Added TestApplyUserDeploymentConfigsWithOverrideEnv to validate per-component override behavior and integration with DeploymentConfigs.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 golangci-lint (2.5.0)

Error: build linters: unable to load custom analyzer "kubeapilinter": bin/kube-api-linter.so, plugin: not implemented
The command is terminated due to an error: build linters: unable to load custom analyzer "kubeapilinter": bin/kube-api-linter.so, plugin: not implemented

Important

Action Needed: IP Allowlist Update

If your organization protects your Git platform with IP whitelisting, please add the new CodeRabbit IP address to your allowlist:

  • 136.113.208.247/32 (new)
  • 34.170.211.100/32
  • 35.222.179.152/32

Failure to add the new IP will result in interrupted reviews.


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

@openshift-ci openshift-ci bot requested review from TrilokGeer and swghosh February 3, 2026 14:16
@siddhibhor-56 siddhibhor-56 changed the title Adds implementation logic for Environment Variables to support customizations at install time ESO-334: Adds implementation logic for Environment Variables to support customizations at install time Feb 3, 2026
@openshift-ci-robot openshift-ci-robot added the jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. label Feb 3, 2026
@openshift-ci
Copy link

openshift-ci bot commented Feb 3, 2026

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: siddhibhor-56
Once this PR has been reviewed and has the lgtm label, please assign trilokgeer for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found 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

@openshift-ci-robot
Copy link

openshift-ci-robot commented Feb 3, 2026

@siddhibhor-56: This pull request references ESO-334 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.22.0" version, but no target version was set.

Details

In response to this:

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 openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci
Copy link

openshift-ci bot commented Feb 3, 2026

@siddhibhor-56: 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/verify a4bec08 link true /test verify

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.

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

Labels

jira/valid-reference Indicates that this PR references a valid Jira ticket of any type.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants