manifests icon indicating copy to clipboard operation
manifests copied to clipboard

Add patches to remove namespaces and edit kustomization

Open keithmattix opened this issue 3 years ago • 4 comments

Description of your changes: When applying kustomize generated kubeflow manifests to a k8s cluster without kubectl, the k8s apiserver will error on several of them due to certain cluster-scoped (i.e. no namespace) manifests containing namespace metadata. To fix this, I've created JSON patches for the resources that I encountered issues with.

Checklist:

  • [ ] Unit tests pass: Make sure you have installed kustomize == 3.2.1
    1. make generate-changed-only
    2. make test

keithmattix avatar May 02 '22 21:05 keithmattix

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: keithmattix To complete the pull request process, please assign elikatsis after the PR has been reviewed. You can assign the PR to them by writing /assign @elikatsis 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

google-oss-prow[bot] avatar May 02 '22 21:05 google-oss-prow[bot]

Hi @keithmattix. Thanks for your PR.

I'm waiting for a kubeflow member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

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.

aws-kf-ci-bot avatar May 02 '22 21:05 aws-kf-ci-bot

This is the wrong repository. You need to fix it in the upstream repositories. And you need to fix it directly without using patches

juliusvonkohout avatar May 02 '22 22:05 juliusvonkohout

Thanks for pointing that out @juliusvonkohout; I didn't realize that. Some follow-up questions:

  1. The cert-manager kubeflow-issuer doesn't have an upstream repo, correct? Since it's a ClusterIssuer kind, the kustomization.yaml actually doesn't need a namespace declaration at all.
  2. The only way (that I'm aware of) to remove namepaces from certain cluster-scoped resources would be to remove top-level namespace declarations from each kustomize.yaml and explicitly add the namespace to each manifest. Does that seem more desirable to you than patches?

keithmattix avatar May 03 '22 14:05 keithmattix

Please put this on the agenda of the next manifest wg meeting in two weeks and join us for a discussion

juliusvonkohout avatar Aug 25 '23 10:08 juliusvonkohout

I'm no longer working on this

keithmattix avatar Sep 14 '23 17:09 keithmattix