bunkerweb/examples/wordpress/autoconf.yml
2022-12-05 11:47:56 +01:00

39 lines
1.1 KiB
YAML

version: "3"
services:
mywp:
image: wordpress:6.1.1-apache
volumes:
- ./wp-data:/var/www/html
networks:
bw-services:
aliases:
- mywp
environment:
- WORDPRESS_DB_HOST=mydb
- WORDPRESS_DB_NAME=wp
- WORDPRESS_DB_USER=user
- WORDPRESS_DB_PASSWORD=db-user-pwd # replace with a stronger password (must match MYSQL_PASSWORD)
- WORDPRESS_TABLE_PREFIX=prefix_ # best practice : replace with a random prefix
labels:
- bunkerweb.SERVER_NAME=www.example.com
- bunkerweb.MAX_CLIENT_SIZE=50m
- bunkerweb.USE_REVERSE_PROXY=yes
- bunkerweb.REVERSE_PROXY_URL=/
- bunkerweb.REVERSE_PROXY_HOST=http://mywp
- |
bunkerweb.CUSTOM_CONF_MODSEC_CRS_wordpress=
SecAction \
"id:900130,\
phase:1,\
nolog,\
pass,\
t:none,\
setvar:tx.crs_exclusions_wordpress=1"
# For the database, you can refer to the autoconf integration example including a database
networks:
bw-services:
external:
name: bw-services