Difference between revisions of "Kubectl create secret generic"
Jump to navigation
Jump to search
(7 intermediate revisions by 2 users not shown) | |||
Line 3: | Line 3: | ||
[[kubectl create secret]] generic | [[kubectl create secret]] generic | ||
[[kubectl create secret generic -h]] | [[kubectl create secret generic -h]] | ||
+ | |||
+ | [[kubectl create secret]] generic yoursecret | ||
+ | secret/yoursecret created | ||
kubectl create secret generic | kubectl create secret generic | ||
Line 9: | Line 12: | ||
[[kubectl create secret]] generic your-secret-name -f /var/tmp/your-secret-definition.yml | [[kubectl create secret]] generic your-secret-name -f /var/tmp/your-secret-definition.yml | ||
+ | secret/your-secret-name created | ||
+ | |||
+ | kubectl create secret generic [[cronitor]]-secret | ||
+ | -n <namespace> | ||
+ | --from-literal=CRONITOR_API_KEY=XXXXXXXXXXX | ||
+ | |||
+ | [[kubectl create secret generic]] regcred --from-file=.dockerconfigjson=<path/to/.docker/config.json> --type=[[kubernetes.io/dockerconfigjson]] | ||
+ | |||
+ | == Related == | ||
+ | * <code>[[aws-ebs-csi-driver]]</code> | ||
+ | * <code>[[kubectl get secrets]]</code> | ||
== See also == | == See also == | ||
+ | * {{kubectl create secret}} | ||
* {{kubernetes secrets}} | * {{kubernetes secrets}} | ||
[[Category:K8s]] | [[Category:K8s]] |
Latest revision as of 20:48, 17 July 2024
kubectl create secret generic kubectl create secret generic -h
kubectl create secret generic yoursecret secret/yoursecret created
kubectl create secret generic error: exactly one NAME is required, got 0 See 'kubectl create secret generic -h' for help and examples
kubectl create secret generic your-secret-name -f /var/tmp/your-secret-definition.yml secret/your-secret-name created
kubectl create secret generic cronitor-secret -n <namespace> --from-literal=CRONITOR_API_KEY=XXXXXXXXXXX
kubectl create secret generic regcred --from-file=.dockerconfigjson=<path/to/.docker/config.json> --type=kubernetes.io/dockerconfigjson
Related[edit]
See also[edit]
kubectl create secret [ docker-registry | generic | tls | --help ]
- Kubernetes secrets:
kubectl [ get | create | describe | delete | secret ] secrets
,secret.yml, kind: Secret, secretKeyRef, default-token, imagePullSecrets:, kubernetes.io/dockerconfigjson
Advertising: