Created
November 21, 2019 16:02
-
-
Save zedtux/79dd0b38d00a2bb6b4a825c88f6edb66 to your computer and use it in GitHub Desktop.
Kubernetes Debug pod to access PV from PVC name
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: v1 | |
kind: Pod | |
metadata: | |
name: mysql-debug | |
spec: | |
containers: | |
- name: mysql-debug | |
image: mysql:5.7 | |
command: | |
- sleep | |
- "3600" | |
resources: | |
requests: | |
cpu: 250m | |
memory: 500Mi | |
limits: | |
cpu: 1000m | |
memory: 1Gi | |
imagePullPolicy: Always | |
volumeMounts: | |
- mountPath: /var/lib/mysql | |
name: mysql-data | |
imagePullSecrets: | |
- name: regcred | |
restartPolicy: Always | |
volumes: | |
- name: mysql-data | |
persistentVolumeClaim: | |
claimName: mysql-data-0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment