57 lines
1.2 KiB
YAML
57 lines
1.2 KiB
YAML
# --------------------------------------
|
|
# Exascaler CSI Driver - Storage Class
|
|
# --------------------------------------
|
|
|
|
apiVersion: storage.k8s.io/v1
|
|
kind: StorageClass
|
|
metadata:
|
|
name: user-nas
|
|
provisioner: exa.csi.ddn.com
|
|
parameters:
|
|
reclaimPolicy: Retain
|
|
# projectId: "100001" # Points to a project id to be used to set volume quota.
|
|
# bindMount: "false"
|
|
---
|
|
|
|
# ------------------------------------------------
|
|
# Exaxscaler CSI Driver - Persistent Volume Claim
|
|
# ------------------------------------------------
|
|
|
|
apiVersion: v1
|
|
kind: PersistentVolumeClaim
|
|
metadata:
|
|
name: nginx-pvc
|
|
spec:
|
|
storageClassName: user-nas
|
|
accessModes:
|
|
- ReadWriteMany
|
|
resources:
|
|
requests:
|
|
storage: 1Gi
|
|
---
|
|
|
|
# ---------
|
|
# Nginx pod
|
|
# ---------
|
|
|
|
apiVersion: v1
|
|
kind: Pod
|
|
metadata:
|
|
name: nginx-volume
|
|
spec:
|
|
containers:
|
|
- image: nginxinc/nginx-unprivileged
|
|
imagePullPolicy: IfNotPresent
|
|
name: nginx
|
|
ports:
|
|
- containerPort: 80
|
|
protocol: TCP
|
|
volumeMounts:
|
|
- mountPath: /data
|
|
name: nginx-data
|
|
volumes:
|
|
- name: nginx-data
|
|
persistentVolumeClaim:
|
|
claimName: nginx-pvc
|
|
readOnly: false
|