Define environment variable container style (#8743)
* define-environment-variable-container format * run-stateless-application-deployment format
This commit is contained in:
+4
-4
@@ -36,11 +36,11 @@ Pod:
|
||||
|
||||
1. Create a Pod based on the YAML configuration file:
|
||||
|
||||
kubectl create -f https://k8s.io/docs/tasks/inject-data-application/envars.yaml
|
||||
kubectl create -f https://k8s.io/docs/tasks/inject-data-application/envars.yaml
|
||||
|
||||
1. List the running Pods:
|
||||
|
||||
kubectl get pods -l purpose=demonstrate-envars
|
||||
kubectl get pods -l purpose=demonstrate-envars
|
||||
|
||||
The output is similar to this:
|
||||
|
||||
@@ -49,11 +49,11 @@ Pod:
|
||||
|
||||
1. Get a shell to the container running in your Pod:
|
||||
|
||||
kubectl exec -it envar-demo -- /bin/bash
|
||||
kubectl exec -it envar-demo -- /bin/bash
|
||||
|
||||
1. In your shell, run the `printenv` command to list the environment variables.
|
||||
|
||||
root@envar-demo:/# printenv
|
||||
root@envar-demo:/# printenv
|
||||
|
||||
The output is similar to this:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user