-
Notifications
You must be signed in to change notification settings - Fork 0
/
rwx-fbda.yaml
63 lines (63 loc) · 1.45 KB
/
rwx-fbda.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
kind: StorageClass
apiVersion: storage.k8s.io/v1
metadata:
name: portworx-fbda
provisioner: pxd.portworx.com
parameters:
backend: "pure_file"
pure_export_rules: "*(rw)"
mountOptions:
- nfsvers=3
- tcp
allowVolumeExpansion: true
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: portworx-fbda
spec:
accessModes:
- ReadWriteMany
resources:
requests:
storage: 12Gi
storageClassName: portworx-fbda
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: busybox-rwx-fbda
labels:
app: busybox-rwx-fbda
spec:
replicas: 3
selector:
matchLabels:
app: busybox-rwx-fbda
template:
metadata:
labels:
app: busybox-rwx-fbda
spec:
affinity:
podAntiAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
- labelSelector:
matchExpressions:
- key: app
operator: In
values:
- busybox-rwx-fbda
topologyKey: "kubernetes.io/hostname"
containers:
- name: busybox-rwx
image: busybox
imagePullPolicy: IfNotPresent
command: ['sh', '-c', 'echo $(hostname) is alive and well at $(date)! >> /mnt/busybox-rwx/status.txt ; trap : TERM INT; sleep infinity & wait']
volumeMounts:
- mountPath: /mnt/busybox-rwx
name: busybox-rwx
volumes:
- name: busybox-rwx
persistentVolumeClaim:
claimName: portworx-fbda