From cb24d6c3d5db154adefd4064e7803e446891ce04 Mon Sep 17 00:00:00 2001 From: Ygal Blum Date: Tue, 21 Mar 2023 11:33:21 +0200 Subject: [PATCH 1/2] Kube Play Doc: Document the support for K8S Secret Signed-off-by: Ygal Blum --- docs/source/markdown/podman-kube-play.1.md.in | 35 +++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/docs/source/markdown/podman-kube-play.1.md.in b/docs/source/markdown/podman-kube-play.1.md.in index dbbd2d6e4b..502e7b8c58 100644 --- a/docs/source/markdown/podman-kube-play.1.md.in +++ b/docs/source/markdown/podman-kube-play.1.md.in @@ -22,6 +22,7 @@ Currently, the supported Kubernetes kinds are: - Deployment - PersistentVolumeClaim - ConfigMap +- Secret `Kubernetes Pods or Deployments` @@ -122,6 +123,40 @@ spec: and as a result environment variable `FOO` will be set to `bar` for container `container-1`. +`Kubernetes Secret` + +Kubernetes Secret represents a Podman named secret. The Kubernetes Secret is saved as a whole and may be referred as a source of environment variables or volumes in Pods or Deployments. + +For example, the following YAML document defines a Secret and then uses it in a Pod: + +``` +kind: Secret +apiVersion: v1 +metadata: + name: foo +data: + foo: YmFy # base64 for bar +--- +apiVersion: v1 +kind: Pod +metadata: + name: foobar +spec: + containers: + - command: + - top + name: container-1 + image: foobar + env: + - name: FOO + valueFrom: + secretKeyRef: + name: foo + key: foo +``` + +and as a result environment variable `FOO` will be set to `bar` for container `container-1`. + ## OPTIONS @@option annotation.container From dd8ee49f676eee8e63657f3b56f621f0819fc4e2 Mon Sep 17 00:00:00 2001 From: Ygal Blum Date: Tue, 28 Mar 2023 10:20:16 +0300 Subject: [PATCH 2/2] Update docs/source/markdown/podman-kube-play.1.md.in Grammar fixes Co-authored-by: Valentin Rothberg Signed-off-by: Ygal Blum --- docs/source/markdown/podman-kube-play.1.md.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/source/markdown/podman-kube-play.1.md.in b/docs/source/markdown/podman-kube-play.1.md.in index 502e7b8c58..eaa40f3744 100644 --- a/docs/source/markdown/podman-kube-play.1.md.in +++ b/docs/source/markdown/podman-kube-play.1.md.in @@ -125,7 +125,7 @@ and as a result environment variable `FOO` will be set to `bar` for container `c `Kubernetes Secret` -Kubernetes Secret represents a Podman named secret. The Kubernetes Secret is saved as a whole and may be referred as a source of environment variables or volumes in Pods or Deployments. +Kubernetes Secret represents a Podman named secret. The Kubernetes Secret is saved as a whole and may be referred to as a source of environment variables or volumes in Pods or Deployments. For example, the following YAML document defines a Secret and then uses it in a Pod: