Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WIP: azure-file: improve secret namespace discovery when translating to CSI #1147

Closed

Conversation

RomanBednar
Copy link

No description provided.

When translating InTree pv to CSI pv we use default secret namespace
when it's not found in the InTree pv.

Using the default so early is not ideal and can result in failed pod
creation after users migrate to cluster with CSI enabled because the
existing pvs might not have the namespace defined.

There is another object we can use to determine correct namespace
which presence could be safely assumed - ClaimRef.

Using default namespace should never happen however should be safe for
cases when secret is not needed - e.g. unmounting a volume.
There is no reason to assign default namespace value and then rewrite
it based on other conditions.

Separate namespace logic so the code is easier to read.
This is the actual fix - attempt to obtain a namespace from ClaimRef,
if present.
@openshift-ci-robot openshift-ci-robot added the backports/unvalidated-commits Indicates that not all commits come to merged upstream PRs. label Jan 26, 2022
@openshift-ci-robot
Copy link

@RomanBednar: the contents of this pull request could not be automatically validated.

The following commits could not be validated and must be approved by a top-level approver:

Comment /validate-backports to re-evaluate validity of the upstream PRs, for example when they are merged upstream.

@openshift-ci openshift-ci bot requested review from deads2k and sttts January 26, 2022 11:21
@openshift-ci openshift-ci bot added the vendor-update Touching vendor dir or related files label Jan 26, 2022
@openshift-ci
Copy link

openshift-ci bot commented Jan 26, 2022

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: RomanBednar
To complete the pull request process, please assign deads2k after the PR has been reviewed.
You can assign the PR to them by writing /assign @deads2k in a comment when ready.

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

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

openshift-ci bot commented Jan 26, 2022

@RomanBednar: The following tests 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-gcp-upgrade 44a8d39 link true /test e2e-gcp-upgrade
ci/prow/e2e-aws-crun 44a8d39 link false /test e2e-aws-crun
ci/prow/e2e-agnostic-cmd 44a8d39 link false /test e2e-agnostic-cmd
ci/prow/verify-commits 44a8d39 link true /test verify-commits

Full PR test history. Your PR dashboard.

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/test-infra 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
backports/unvalidated-commits Indicates that not all commits come to merged upstream PRs. vendor-update Touching vendor dir or related files
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants