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

Issue with k8s.io/docs/concepts/overview/working-with-objects/namespaces/ #10889

Closed
1 task
tpstaples opened this issue Nov 5, 2018 · 4 comments
Closed
1 task

Comments

@tpstaples
Copy link

This is a...

  • Feature Request
  • [x ] Bug Report

Problem:
At the bottom of the page it talks about "kubectl api-resources" command.
I am running version v1.10.0 of kubectl and that command is invalid. Here's the output i see.

$> kubectl api-resources --namespaced=true
Error: unknown command "api-resources" for "kubectl"
Run 'kubectl --help' for usage.
unknown command "api-resources" for "kubectl"

Proposed Solution:
update documentation to say in which versions of kubectl that command will work.

Page to Update:
https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/

$> kubectl version
Client Version: version.Info{Major:"1", Minor:"10", GitVersion:"v1.10.0", GitCommit:"fc32d2f3698e36b93322a3465f63a14e9f0eaead", GitTreeState:"clean", BuildDate:"2018-03-26T16:55:54Z", GoVersion:"go1.9.3", Compiler:"gc", Platform:"darwin/amd64"}
Server Version: version.Info{Major:"1", Minor:"9", GitVersion:"v1.9.11", GitCommit:"1bfeeb6f212135a22dc787b73e1980e5bccef13d", GitTreeState:"clean", BuildDate:"2018-09-28T21:35:22Z", GoVersion:"go1.9.3", Compiler:"gc", Platform:"linux/amd64"}

@warmchang
Copy link
Contributor

@tpstaples "kubectl api-resources" command is only exists in v1.11 and later versions.
ref: kubernetes/kubernetes#42873

The default version of site-docs is following the K8S release, and now the "https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/" is describe the v1.12.

You can select a different version via the drop down button in the top right corner of the page.
And there are no "kubectl api-resources" command describe in v1.10/v1.9:
https://v1-10.docs.kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/
https://v1-9.docs.kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/

@warmchang
Copy link
Contributor

If there are no more questions, I will close this issue, thanks.

The following is the execution result of v1.12, for reference. 😃

 ⚡ root@k8s  /home/ubuntu  kubectl version
Client Version: version.Info{Major:"1", Minor:"12", GitVersion:"v1.12.2", GitCommit:"17c77c7898218073f14c8d573582e8d2313dc740", GitTreeState:"archive", BuildDate:"2018-10-29T06:56:23Z", GoVersion:"go1.10.4", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"12", GitVersion:"v1.12.2", GitCommit:"17c77c7898218073f14c8d573582e8d2313dc740", GitTreeState:"archive", BuildDate:"2018-10-29T06:56:23Z", GoVersion:"go1.10.4", Compiler:"gc", Platform:"linux/amd64"}
 ⚡ root@k8s  /home/ubuntu  kubectl api-resources --namespaced=true
NAME                        SHORTNAMES   APIGROUP                    NAMESPACED   KIND
bindings                                                             true         Binding
configmaps                  cm                                       true         ConfigMap
endpoints                   ep                                       true         Endpoints
events                      ev                                       true         Event
limitranges                 limits                                   true         LimitRange
persistentvolumeclaims      pvc                                      true         PersistentVolumeClaim
pods                        po                                       true         Pod
podtemplates                                                         true         PodTemplate
replicationcontrollers      rc                                       true         ReplicationController
resourcequotas              quota                                    true         ResourceQuota
secrets                                                              true         Secret
serviceaccounts             sa                                       true         ServiceAccount
services                    svc                                      true         Service
controllerrevisions                      apps                        true         ControllerRevision
daemonsets                  ds           apps                        true         DaemonSet
deployments                 deploy       apps                        true         Deployment
replicasets                 rs           apps                        true         ReplicaSet
statefulsets                sts          apps                        true         StatefulSet
localsubjectaccessreviews                authorization.k8s.io        true         LocalSubjectAccessReview
horizontalpodautoscalers    hpa          autoscaling                 true         HorizontalPodAutoscaler
cronjobs                    cj           batch                       true         CronJob
jobs                                     batch                       true         Job
leases                                   coordination.k8s.io         true         Lease
events                      ev           events.k8s.io               true         Event
databases                                example.com                 true         Database
daemonsets                  ds           extensions                  true         DaemonSet
deployments                 deploy       extensions                  true         Deployment
ingresses                   ing          extensions                  true         Ingress
networkpolicies             netpol       extensions                  true         NetworkPolicy
replicasets                 rs           extensions                  true         ReplicaSet
networkpolicies             netpol       networking.k8s.io           true         NetworkPolicy
poddisruptionbudgets        pdb          policy                      true         PodDisruptionBudget
rolebindings                             rbac.authorization.k8s.io   true         RoleBinding
roles                                    rbac.authorization.k8s.io   true         Role
 ⚡ root@k8s  /home/ubuntu 

@warmchang
Copy link
Contributor

/close

@k8s-ci-robot
Copy link
Contributor

@warmchang: Closing this issue.

In response to this:

/close

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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants