Update wordpress.yaml
This commit is contained in:
1 parent
dfc4b6fdfc
commit
a962de35a5
1 file changed
+2
-24
+2
-24
@@ -13,26 +13,10 @@ spec:
|
|||||||
labels:
|
labels:
|
||||||
app: wordpress
|
app: wordpress
|
||||||
spec:
|
spec:
|
||||||
initContainers:
|
|
||||||
- name: init-pg4wp
|
|
||||||
image: hub.hamdocker.ir/library/alpine:latest
|
|
||||||
command:
|
|
||||||
- sh
|
|
||||||
- -c
|
|
||||||
- |
|
|
||||||
apk add --no-cache git
|
|
||||||
git clone http://gitea-http.gitea.svc.cluster.local:3000/gitea_admin/apps.git /tmp/repo
|
|
||||||
mkdir -p /var/www/html/wp-content/plugins/pg4wp
|
|
||||||
cp -r /tmp/repo/pg4wp/* /var/www/html/wp-content/plugins/pg4wp/
|
|
||||||
cp /tmp/repo/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: gitea.ali.atestd.shop/gitea_admin/wordpress-pg:latest
|
||||||
command: ["/bin/sh", "-c"]
|
imagePullPolicy: Never
|
||||||
args: ["sed -i 's|deb.debian.org|mirror.iranserver.com|g' /etc/apt/sources.list.d/debian.sources && apt-get update && apt-get install -y libpq-dev && docker-php-ext-install pgsql pdo_pgsql && exec docker-entrypoint.sh apache2-foreground"]
|
|
||||||
env:
|
env:
|
||||||
- name: WORDPRESS_DB_HOST
|
- name: WORDPRESS_DB_HOST
|
||||||
value: "postgresql:5432"
|
value: "postgresql:5432"
|
||||||
@@ -44,12 +28,6 @@ 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
|
||||||
|
|||||||
Reference in new issue
Block a user