PVC sharing inside one pod -> works!
This commit is contained in:
parent
a131fe805d
commit
112860e2f7
1 changed files with 48 additions and 0 deletions
48
tests/pvc-rwo-multimount-same-pod.yaml
Normal file
48
tests/pvc-rwo-multimount-same-pod.yaml
Normal file
|
@ -0,0 +1,48 @@
|
||||||
|
---
|
||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: pvcrwotest
|
||||||
|
spec:
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
app: pvcrwotest
|
||||||
|
replicas: 1
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app: pvcrwotest
|
||||||
|
spec:
|
||||||
|
containers:
|
||||||
|
- name: nginx
|
||||||
|
image: nginx:1.21-alpine
|
||||||
|
ports:
|
||||||
|
- containerPort: 443
|
||||||
|
volumeMounts:
|
||||||
|
- name: data
|
||||||
|
mountPath: "/var/www/html"
|
||||||
|
- name: busybox
|
||||||
|
image: busybox
|
||||||
|
args:
|
||||||
|
- sleep
|
||||||
|
- "100000000"
|
||||||
|
volumeMounts:
|
||||||
|
- name: data
|
||||||
|
mountPath: "/data"
|
||||||
|
volumes:
|
||||||
|
- name: data
|
||||||
|
persistentVolumeClaim:
|
||||||
|
claimName: pvcrwotest-data
|
||||||
|
|
||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: PersistentVolumeClaim
|
||||||
|
metadata:
|
||||||
|
name: pvcrwotest-data
|
||||||
|
spec:
|
||||||
|
accessModes:
|
||||||
|
- ReadWriteOnce
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 1Gi
|
||||||
|
storageClassName: rook-ceph-block
|
Loading…
Add table
Reference in a new issue