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

Deployment via Helm chart fail #76

Closed
paullaffitte opened this issue Jun 30, 2021 · 5 comments · Fixed by #81
Closed

Deployment via Helm chart fail #76

paullaffitte opened this issue Jun 30, 2021 · 5 comments · Fixed by #81
Assignees
Labels
bug Something isn't working
Milestone

Comments

@paullaffitte
Copy link

paullaffitte commented Jun 30, 2021

I know that 2 issues already exists about installing kube-fledged via YAML and operator fail but this one is about installing it with Helm, and it's not exactly the same problem.

When I run:

$ curl -fsSL https://raw.githubusercontent.com/senthilrch/kube-fledged/master/deploy/webhook-create-signed-cert.sh | bash -s -- --namespace ${KUBEFLEDGED_NAMESPACE}

I got this error message: The CertificateSigningRequest "kubefledged-webhook-server.kube-fledged" is invalid: spec.signerName: Invalid value: "kubernetes.io/legacy-unknown": the legacy signerName is not allowed via this API version.

My k8s version:

$ kubectl version
Client Version: version.Info{Major:"1", Minor:"19", GitVersion:"v1.19.2", GitCommit:"f5743093fd1c663cb0cbc89748f730662345d44d", GitTreeState:"clean", BuildDate:"2020-09-16T13:41:02Z", GoVersion:"go1.15", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"19", GitVersion:"v1.19.2", GitCommit:"f5743093fd1c663cb0cbc89748f730662345d44d", GitTreeState:"clean", BuildDate:"2020-09-16T13:32:58Z", GoVersion:"go1.15", Compiler:"gc", Platform:"linux/amd64"}

PS: FYI, if it can be useful:

$ kubectl api-versions | grep certificates.k8s.io | head -1
certificates.k8s.io/v1

EDIT:

If I try to edit the script and remove the signerName key, I got this quite interesting error message:
error: error validating "STDIN": error validating data: ValidationError(CertificateSigningRequest.spec): missing required field "signerName" in io.k8s.api.certificates.v1.CertificateSigningRequestSpec; if you choose to ignore these errors, turn validation off with --validate=false. Not sure if the issue is coming from kube-fledged or k8s itself 🤔

@paullaffitte
Copy link
Author

I found something interesting. According to k8s docs:

The stable CertificateSigningRequest API (version certificates.k8s.io/v1 and later) does not allow to set the signerName as kubernetes.io/legacy-unknown

If I try to change signerName and replace kubernetes.io/legacy-unknown by an arbitrary value it works.

@senthilrch
Copy link
Owner

@paullaffitte : thanks for posting this issue. Please use the workaround mentioned in following issue:-
#75

@senthilrch senthilrch self-assigned this Jul 1, 2021
@senthilrch senthilrch added this to the v0.8.1 milestone Jul 1, 2021
@senthilrch senthilrch added the bug Something isn't working label Jul 1, 2021
@paullaffitte
Copy link
Author

Thanks, but unfortunately, it doesn't work either.

error: unable to recognize "STDIN": no matches for kind "CertificateSigningRequest" in version "apiVersion=certificates.k8s.io/v1beta1"

@senthilrch
Copy link
Owner

Please share the output of following command:-

kubectl api-versions | grep certificates.k8s.io

@paullaffitte
Copy link
Author

paullaffitte commented Jul 1, 2021

$ kubectl api-versions | grep certificates.k8s.io
certificates.k8s.io/v1
certificates.k8s.io/v1beta1

EDIT: My bad, I was too fast and did a mistake, I wrote apiVersion='apiVersion=certificates.k8s.io/v1beta1' instead of apiVersion='certificates.k8s.io/v1beta1'. It's now working. Thanks

@senthilrch senthilrch linked a pull request Jul 23, 2021 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants