Skip to content

Instantly share code, notes, and snippets.

@PabloHiro
Last active February 27, 2024 08:39
Show Gist options
  • Save PabloHiro/09dc6c02bf41abb2865346494ef25dd5 to your computer and use it in GitHub Desktop.
Save PabloHiro/09dc6c02bf41abb2865346494ef25dd5 to your computer and use it in GitHub Desktop.
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: sharedvolume-claim
spec:
accessModes:
- ReadWriteMany
resources:
requests:
storage: 1Gi
storageClassName: managed-csi
volumeMode: Block
---
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: minimal-sharedvolume-test
spec:
selector:
matchLabels:
name: minimal-sharedvolume-test
template:
metadata:
labels:
name: minimal-sharedvolume-test
spec:
tolerations:
containers:
- name: minimal-sharedvolume-test
image: nginx
resources:
limits:
memory: 200Mi
requests:
cpu: 10m
memory: 10Mi
volumeMounts:
- name: sharedvolume
mountPath: /mnt
terminationGracePeriodSeconds: 30
volumes:
- name: sharedvolume
persistentVolumeClaim:
claimName: sharedvolume-claim
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment