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

error when creating "deploy/crds/example_v1alpha1_nginx_cr.yaml #1053

Closed
spanichella opened this issue Feb 4, 2019 · 5 comments
Closed

error when creating "deploy/crds/example_v1alpha1_nginx_cr.yaml #1053

spanichella opened this issue Feb 4, 2019 · 5 comments
Assignees
Labels
language/helm Issue is related to a Helm operator project

Comments

@spanichella
Copy link

Bug Report

What did you do?
I followed the guideline for installing the operator as described here: https://github.com/operator-framework/operator-sdk/blob/master/doc/helm/user-guide.md

The steps I did are the following:
Helm operator.pdf

when I have executed
$kubectl apply -f deploy/crds/example_v1alpha1_nginx_cr.yaml
I get the following error:

Error from server (NotFound): error when creating "deploy/crds/example_v1alpha1_nginx_cr.yaml": the server could not find the requested resource (post nginxs.example.com)

What did you expect to see?
A clear and concise description of what you expected to happen (or insert a code snippet).

Something like:
$ kubectl get deployment
NAME DESIRED CURRENT UP-TO-DATE AVAILABLE AGE
example-nginx-b9phnoz9spckcrua7ihrbkrt1 2 2 2 2 1m
Check the pods to confirm 2 replicas were created:

$ kubectl get pods
NAME READY STATUS RESTARTS AGE
example-nginx-b9phnoz9spckcrua7ihrbkrt1-f8f9c875d-fjcr9 1/1 Running 0 1m
example-nginx-b9phnoz9spckcrua7ihrbkrt1-f8f9c875d-ljbzl 1/1 Running 0 1m

What did you see instead? Under which circumstances?
A clear and concise description of what you expected to happen (or insert a code snippet).
"Error from server (NotFound): error when creating "deploy/crds/example_v1alpha1_nginx_cr.yaml": the server could not find the requested resource (post nginxs.example.com)"

Environment

  • operator-sdk version:

operator-sdk version v0.3.0+git

  • Kubernetes version information:

    Insert output of kubectl version here

lient Version: version.Info{Major:"1", Minor:"11", GitVersion:"v1.11.2", GitCommit:"bb9ffb1654d4a729bb4cec18ff088eacc153c239", GitTreeState:"clean", BuildDate:"2018-08-07T23:17:28Z", GoVersion:"go1.10.3", Compiler:"gc", Platform:"darwin/amd64"}
Server Version: version.Info{Major:"1", Minor:"10+", GitVersion:"v1.10.0+b81c8f8", GitCommit:"b81c8f8", GitTreeState:"clean", BuildDate:"2019-01-13T08:18:56Z", GoVersion:"go1.10.3", Compiler:"gc", Platform:"linux/amd64"}

  • Kubernetes cluster kind:

"I'm using minishift"

  • Are you writing your operator in ansible, helm, or go?
    Helm

Possible Solution

Additional context
Add any other context about the problem here.

@spanichella
Copy link
Author

One thing that I noticed is that when I run:

$kubectl get service
I get:
"No resources found"

Maybe this is the main problem?

@joelanford
Copy link
Member

@spanichella There is an issue in Kubernetes prior to 1.11.2 that causes pluralization issues with certain CRDs. The CRD name "nginx" triggers the bug. That's why we recommend 1.11.3+ in the Helm user guide.

Can you upgrade your Kubernetes version (both client and server) to 1.11.3+ and try again?

@joelanford joelanford self-assigned this Feb 4, 2019
@joelanford joelanford added the language/helm Issue is related to a Helm operator project label Feb 4, 2019
@ron1
Copy link

ron1 commented Feb 11, 2019

Are you able to identify the specific Kubernetes CRD pluralization issue? Do you know if the fix has been back-ported to any of the OpenShift 3.11.x releases?

@joelanford
Copy link
Member

@ron1 The original issue is documented here: kubernetes/kubernetes#67235. And it was fixed here: kubernetes/kubernetes#66249

OpenShift 3.11 includes this fix as well (openshift/origin#20392)

@joelanford
Copy link
Member

@spanichella I'm closing this since I think upgrading will resolve your issue. If it doesn't please feel free to re-open!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
language/helm Issue is related to a Helm operator project
Projects
None yet
Development

No branches or pull requests

3 participants