kubernetes / ingress-nginx

Ingress NGINX Controller for Kubernetes
https://kubernetes.github.io/ingress-nginx/
Apache License 2.0
17.6k stars 8.27k forks source link

Ingresses not listed by krew plugin #9991

Open zquestz opened 1 year ago

zquestz commented 1 year ago

When I try to list out all ingresses or lint my configurations using the ingress-nginx krew plugin it fails. Note that it is installed in the default namespace. All other commands work as expected. The ingress functionality works as intended for dozens of sites. Seems to be some small issue with the plugin.

 $ kubectl ingress-nginx ingresses --all-namespaces
the server could not find the requested resource
 $ kubectl ingress-nginx lint --all-namespaces                                                                                                                                                                                          
Checking ingresses...
the server could not find the requested resource
Checking deployments...

It works fine if I list using kubectl. Also note that I installed the plugin using kubectl krew install ingress-nginx. When I build it from source, it actually works...

 $ kubectl get ing --all-namespaces          
NAMESPACE   NAME                                  CLASS    HOSTS                                                   ADDRESS        PORTS     AGE
<huge list of ingresses>

What happened: When I try to list ingresses or lint configurations using the ingress-nginx krew plugin I get an error.

What you expected to happen: I expect to see a list of ingresses, and linting to work correctly.

NGINX Ingress controller version (exec into the pod and run nginx-ingress-controller --version.):

-------------------------------------------------------------------------------
NGINX Ingress controller
  Release:       v1.7.1
  Build:         f48b03be54031491e78472bcf3aa026a81e1ffd3
  Repository:    https://github.com/kubernetes/ingress-nginx
  nginx version: nginx/1.21.6

-------------------------------------------------------------------------------

Kubernetes version (use kubectl version): Client Version: v1.27.1 Kustomize Version: v5.0.1 Server Version: v1.26.2-gke.1000

Environment: Running directly in GKE

How to reproduce this issue: Just try to list the ingresses or use the lint command.

k8s-ci-robot commented 1 year ago

This issue is currently awaiting triage.

If Ingress contributors determines this is a relevant issue, they will accept it by applying the triage/accepted label and provide further guidance.

The triage/accepted label can be added by org members by writing /triage accepted in a comment.

Instructions for interacting with me using PR comments are available [here](https://git.k8s.io/community/contributors/guide/pull-requests.md). If you have questions or suggestions related to my behavior, please file an issue against the [kubernetes/test-infra](https://github.com/kubernetes/test-infra/issues/new?title=Prow%20issue:) repository.
github-actions[bot] commented 1 year ago

This is stale, but we won't close it automatically, just bare in mind the maintainers may be busy with other tasks and will reach your issue ASAP. If you have any question or request to prioritize this, please reach #ingress-nginx-dev on Kubernetes Slack.

zquestz commented 1 year ago

Issue is still present.

rd-michel commented 1 year ago

kubectl version Client Version: v1.27.2 Kustomize Version: v5.0.1 Server Version: v1.27.3-gke.100

im using the latest krew plugin version

kubectl ingress-nginx ingresses --all-namespaces the server could not find the requested resource

kubectl ingress-nginx ingresses --host existing.host.com the server could not find the requested resource

cnwaldron commented 1 year ago

Also ran into this issue, please make this a priority to fix!

zquestz commented 1 month ago

Any progress on this?