We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fdf3521 commit 3a238c9Copy full SHA for 3a238c9
PodPreset/README.md
@@ -0,0 +1,9 @@
1
+## PodPreset Example
2
+---
3
+
4
+1. Change the metadata `name` tag to the name you want
5
+2. Set the `role`. The preset will act on all Pods with the same role.
6
+3. Set the environment variables and values you need for the Pods.
7
+4. Mount a volume if wanted.
8
9
+Reference: https://kubernetes.io/docs/tasks/inject-data-application/podpreset/
PodPreset/pod-preset.yaml
@@ -0,0 +1,19 @@
+apiVersion: settings.k8s.io/v1alpha1
+kind: PodPreset
+metadata:
+ name: setup-database
+spec:
+ selector:
+ matchLabels:
+ role: frontend
+ env:
10
+ - name: DB_PORT
11
+ value: "6379"
12
+ volumeMounts:
13
+ - mountPath: /cache
14
+ name: cache-volume
15
+ volumes:
16
+ - name: cache-volume
17
+ emptyDir: {}
18
19
0 commit comments