Skip to content

Instantly share code, notes, and snippets.

@atulsingh0
Last active March 22, 2022 15:41
Show Gist options
  • Save atulsingh0/b8a55dc0f792eefe4cf9d54f8ebb46f1 to your computer and use it in GitHub Desktop.
Save atulsingh0/b8a55dc0f792eefe4cf9d54f8ebb46f1 to your computer and use it in GitHub Desktop.
Mount Volume
apiVersion: v1
kind: Pod
metadata:
name: z-test-pod
spec:
containers:
- name: test
image: busybox
command: [ "/bin/sh", "-c", "sleep 7200" ]
volumeMounts:
- mountPath: "/vault/file" # Folder in pod mounting nfsclaim
name: mypd
volumes:
- name: mypd # volume name the container can mount
persistentVolumeClaim: # Source of storage
claimName: data-vault-0 # name of pvc created
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment