Update wordpress.yaml

This commit is contained in:
gitea_admin committed 2026-10-02 18:50:19 +00:00
1 parent 1430f4fd54
commit 0a51ac0a31
1 file changed
+20
+20
View File
@@ -13,6 +13,20 @@ spec:
labels: labels:
app: wordpress app: wordpress
spec: spec:
initContainers:
- name: init-pg4wp
image: hub.hamdocker.ir/library/busybox:latest
command:
- sh
- -c
- |
wget -O /tmp/pg4wp.zip https://github.com/kevinoid/postgresql-for-wordpress/archive/refs/heads/master.zip
unzip /tmp/pg4wp.zip -d /var/www/html/wp-content/plugins/
mv /var/www/html/wp-content/plugins/postgresql-for-wordpress-master /var/www/html/wp-content/plugins/pg4wp
cp /var/www/html/wp-content/plugins/pg4wp/db.php /var/www/html/wp-content/db.php
volumeMounts:
- name: wordpress-data
mountPath: /var/www/html
containers: containers:
- name: wordpress - name: wordpress
image: wordpress:latest image: wordpress:latest
@@ -27,6 +41,12 @@ spec:
value: "wordpress" value: "wordpress"
ports: ports:
- containerPort: 80 - containerPort: 80
volumeMounts:
- name: wordpress-data
mountPath: /var/www/html
volumes:
- name: wordpress-data
emptyDir: {}
--- ---
apiVersion: v1 apiVersion: v1
kind: Service kind: Service