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

Missing AdmissionregistrationV1Api, V1MutatingWebhook #1179

Closed
GnatorX opened this issue Jun 8, 2020 · 4 comments
Closed

Missing AdmissionregistrationV1Api, V1MutatingWebhook #1179

GnatorX opened this issue Jun 8, 2020 · 4 comments
Labels
kind/bug Categorizes issue or PR as related to a bug.

Comments

@GnatorX
Copy link

GnatorX commented Jun 8, 2020

What happened (please include outputs or screenshots):
Attempted to create via create_from_yaml a v1 version of mutatingwebhook config but client failed to find this version

What you expected to happen:
Expected the client to find it (I see the code/ doc in master branch but not in 11 or 12
How to reproduce it (as minimally and precisely as possible):

kind: MutatingWebhookConfiguration
apiVersion: admissionregistration.k8s.io/v1
metadata:
  name: mutating-webhook
webhooks:
  - name: alb.ingress.webhook
    sideEffects: None
    admissionReviewVersions: ["v1", "v1beta1"]
    rules:
      - operations: ["CREATE"]
        apiGroups: ["*"]
        apiVersions: ["*"]
        resources: ["ingresses"]
    #namespaceSelector:
    #  matchLabels:
    #    watch: "true"
    failurePolicy: Fail
    clientConfig:
      caBundle: ${CA_BUNDLE}
      service:
        name: webhook
        path: /mutate

Attempting to create from yaml with this will fail due to unknown api version to python client

Anything else we need to know?:

Environment:

  • Kubernetes version (kubectl version): 1.16
  • OS (e.g., MacOS 10.13.6): AWS EC2
  • Python version (python --version): 3.7
  • Python client version (pip list | grep kubernetes): 11
@GnatorX GnatorX added the kind/bug Categorizes issue or PR as related to a bug. label Jun 8, 2020
@GnatorX
Copy link
Author

GnatorX commented Jun 9, 2020

Example of what is in master:
https://github.com/kubernetes-client/python/blob/master/kubernetes/docs/AdmissionregistrationV1Api.md
but neither 11 or 12 branch has this

@GnatorX
Copy link
Author

GnatorX commented Jun 9, 2020

Following the other threads, it seems like 11 is created against 1.15 which didn't support these APIs. #1052

@moshevayner
Copy link
Member

Yep @GnatorX you are correct.
There is a similar issue #1172 and this comment in particular which provides some additional context.

@GnatorX
Copy link
Author

GnatorX commented Jun 10, 2020

Closing this since this will get addressed with v12

@GnatorX GnatorX closed this as completed Jun 10, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Categorizes issue or PR as related to a bug.
Projects
None yet
Development

No branches or pull requests

2 participants