[release-4.17] OCPBUGS-44861: Add ARO HCP environment vars to CSI deployment#541
[release-4.17] OCPBUGS-44861: Add ARO HCP environment vars to CSI deployment#541bryan-cox wants to merge 3 commits into
Conversation
This commit adds environment variables needed by a CSI deployment for ARO HCP. Signed-off-by: Bryan Cox <brcox@redhat.com>
|
@bryan-cox: This pull request references Jira Issue OCPBUGS-44627, which is invalid:
Comment The bug has been updated to refer to the pull request using the external bug tracker. DetailsIn 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. |
|
/jira cherrypick OCPBUGS-44627 |
|
@bryan-cox: Jira Issue OCPBUGS-44627 has been cloned as Jira Issue OCPBUGS-44861. Will retitle bug to link to clone. DetailsIn 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. |
|
@bryan-cox: This pull request references Jira Issue OCPBUGS-44861, which is invalid:
Comment The bug has been updated to refer to the pull request using the external bug tracker. DetailsIn 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. |
|
@bryan-cox: 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. |
|
/jira refresh |
|
@bryan-cox: This pull request references Jira Issue OCPBUGS-44861, which is invalid:
Comment The bug has been updated to refer to the pull request using the external bug tracker. DetailsIn 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. |
| // The existence of the environment variable, ARO_HCP_SECRET_PROVIDER_CLASS_FOR_FILE, means this is an ARO HCP | ||
| // deployment. We need to pass along additional environment variables for ARO HCP in order to mount the backing | ||
| // certificates, related to the client IDs, in a volume on the azure-disk-csi-controller and | ||
| // azure-file-csi-controller deployments. | ||
| var envVars []corev1.EnvVar | ||
| if os.Getenv("ARO_HCP_SECRET_PROVIDER_CLASS_FOR_DISK") != "" && requiredCopy.Name == "azure-disk-csi-driver-operator" { | ||
| envVars = []corev1.EnvVar{ | ||
| {Name: "ARO_HCP_SECRET_PROVIDER_CLASS_FOR_DISK", Value: os.Getenv("ARO_HCP_SECRET_PROVIDER_CLASS_FOR_DISK")}, | ||
| } | ||
| } | ||
|
|
||
| if os.Getenv("ARO_HCP_SECRET_PROVIDER_CLASS_FOR_FILE") != "" && requiredCopy.Name == "azure-file-csi-driver-operator" { | ||
| envVars = []corev1.EnvVar{ | ||
| {Name: "ARO_HCP_SECRET_PROVIDER_CLASS_FOR_FILE", Value: os.Getenv("ARO_HCP_SECRET_PROVIDER_CLASS_FOR_FILE")}, | ||
| } | ||
| } |
There was a problem hiding this comment.
I would prefer a generic function like InjectPassThroughEnvVars with a list (map with operator name?) of env. vars to pass from the upper layer (CVO / hypershift) down to the CSI driver operators. Having a specific code for each env. var looks error prone to me - now it's just two env. vars for ARO, but who knows what comes next.
And you can unit test that function nicely 3:-).
There was a problem hiding this comment.
heh, too late, I missed it's a cherry pick
/lgtm
/approve
/label backport-risk-assessed
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: bryan-cox, jsafrane 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 |
|
/label cherry-pick-approved |
|
/close Closing for now since it looks like ARO HCP will private preview with 4.18.0 rather than 4.17.z. |
|
@bryan-cox: Closed this PR. DetailsIn 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 kubernetes-sigs/prow repository. |
|
@bryan-cox: This pull request references Jira Issue OCPBUGS-44861. The bug has been updated to no longer refer to the pull request using the external bug tracker. DetailsIn 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. |
This pull request is the cherry-picks of: