diff --git a/deployments/ghost-blog-deployment.yaml b/deployments/ghost-blog-deployment.yaml index 0018c1f..948a804 100644 --- a/deployments/ghost-blog-deployment.yaml +++ b/deployments/ghost-blog-deployment.yaml @@ -18,9 +18,6 @@ spec: image: ghost:latest ports: - containerPort: 2368 - volumeMounts: - - name: ghost-blog-content - mountPath: /var/lib/ghost/content env: - name: url valueFrom: @@ -59,5 +56,10 @@ spec: requests: cpu: "100m" memory: "256Mi" - - + volumeMounts: + - name: ghost-blog-content + mountPath: /var/lib/ghost/content + volumes: + - name: ghost-blog-content + persistentVolumeClaim: + claimName: ghost-blog-pvc \ No newline at end of file diff --git a/deployments/mysql-deployment.yaml b/deployments/mysql-deployment.yaml index ef1aa8e..70afd4e 100644 --- a/deployments/mysql-deployment.yaml +++ b/deployments/mysql-deployment.yaml @@ -18,9 +18,6 @@ spec: image: mysql:8.0 ports: - containerPort: 3306 - volumeMounts: - - name: mysql-storage - mountPath: /var/lib/mysql env: - name: MYSQL_ROOT_PASSWORD valueFrom: @@ -49,4 +46,10 @@ spec: limits: memory: "512Mi" cpu: "500m" - + volumeMounts: + - name: mysql-persistent-storage + mountPath: /var/lib/mysql + volumes: + - name: mysql-persistent-storage + persistentVolumeClaim: + claimName: mysql-pvc