From adb0d7dd21c022b4be5bc18bc140ae8b8f78de30 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?M=C3=A1rcio=20Fernandes?= Date: Sat, 26 Sep 2026 03:05:39 +0000 Subject: [PATCH] modified: README.md --- README.md | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 3460929..42ab31c 100644 --- a/README.md +++ b/README.md @@ -35,6 +35,7 @@ Kubernetes is an open‑source platform that automates the deployment, scaling, - [Manifest - StringData](#manifest---stringdata) - [Inline with heredoc and environment variables](#inline-with-heredoc-and-environment-variables) - [substr](#substr) + - [using as env](#using-as-env) - [mounting](#mounting) - [annotations](#annotations) - [nodes](#nodes) @@ -684,10 +685,24 @@ envsubst < ./secret.yaml | kubectl apply -f - ``` +### using as env + +``` yaml +containers: + image: myimage + env: + - name: DB_PASSWORD + valueFrom: + secretKeyRef: + name: my-secret + key: PASSWORD +``` + ### mounting ``` yaml - +containers: + - name: test volumeMounts: - name: secret-name mountPath: /secret