I recently applied this CRD file
https://raw.githubusercontent.com/jetstack/cert-manager/release-0.11/deploy/manifests/00-crds.yaml
With kubectl apply
to install this: https://hub.helm.sh/charts/jetstack/cert-manager
I think I managed to apply it successfully:
xetra11@x11-work configuration]$ kubectl apply -f ./helm-charts/certificates/00-crds.yaml --validate=false customresourcedefinition.apiextensions.k8s.io/challenges.acme.cert-manager.io created customresourcedefinition.apiextensions.k8s.io/orders.acme.cert-manager.io created customresourcedefinition.apiextensions.k8s.io/certificaterequests.cert-manager.io created customresourcedefinition.apiextensions.k8s.io/certificates.cert-manager.io created customresourcedefinition.apiextensions.k8s.io/clusterissuers.cert-manager.io created customresourcedefinition.apiextensions.k8s.io/issuers.cert-manager.io created
But now I would like to "see" what I just applied here. I have no idea how to list those definitions or for example remove them if I think they will screw up my cluster somehow.
I was not able to find any information to that here: https://kubernetes.io/docs/concepts/extend-kubernetes/api-extension/custom-resources/#preparing-to-install-a-custom-resource
kubectl get customresourcedefinitions
, or kubectl get crd
.
You can then use kubectl describe crd <crd_name>
to get a description of the CRD. And of course kubectl get crd <crd_name> -o yaml
to get the complete definition of the CRD.
To remove you can use kubectl delete crd <crd_name>
.
Custom Resources are like any other native kubernetes resources. All the basic kubecl CRUD operations works fine for CRDs. so just use any the below commands.
kubectl get crd <name of crd> kubectl describe crd <name of crd> kubectl get crd <name of crd> -o yaml
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With