Merge pull request #1372 from jpeeler/secrets-docs

Fix incorrect wording with secrets
This commit is contained in:
devin-donnelly
2016-10-05 14:11:48 -07:00
committed by GitHub
+3 -3
View File
@@ -377,7 +377,7 @@ To use a secret in an environment variable in a pod:
1. Modify your Pod definition in each container that you wish to consume the value of a secret key to add an environment variable for each secret key you wish to consume. The environment variable that consumes the secret key should populate the secret's name and key in `env[x].valueFrom.secretKeyRef`.
1. Modify your image and/or command line so that the program looks for values in the specified environment variables
This is an example of a pod that mounts a secret in a volume:
This is an example of a pod that uses secrets from environment variables:
```yaml
apiVersion: v1
@@ -543,9 +543,9 @@ credentials.
Make the secrets:
```shell
$ kubectl create secret generic prod-db-secret --from-literal=user=produser --from-literal=password=Y4nys7f11
$ kubectl create secret generic prod-db-secret --from-literal=username=produser --from-literal=password=Y4nys7f11
secret "prod-db-secret" created
$ kubectl create secret generic test-db-secret --from-literal=user=testuser --from-literal=password=iluvtests
$ kubectl create secret generic test-db-secret --from-literal=username=testuser --from-literal=password=iluvtests
secret "test-db-secret" created
```