'wordpress_example/docker-compose.yml' toevoegen
This commit is contained in:
parent
be8998ecc4
commit
7f90b3f8cf
1 changed files with 34 additions and 0 deletions
34
wordpress_example/docker-compose.yml
Normal file
34
wordpress_example/docker-compose.yml
Normal file
|
@ -0,0 +1,34 @@
|
||||||
|
# https://hub.docker.com/_/wordpress
|
||||||
|
# https://hub.docker.com/_/mysql
|
||||||
|
|
||||||
|
version: '3.3'
|
||||||
|
|
||||||
|
services:
|
||||||
|
db:
|
||||||
|
image: mysql:8
|
||||||
|
container_name: wordpress-example-db
|
||||||
|
volumes:
|
||||||
|
- ./db_data:/var/lib/mysql
|
||||||
|
- ./db_data:/docker-entrypoint-initdb.d
|
||||||
|
restart: unless-stopped
|
||||||
|
environment:
|
||||||
|
MYSQL_ROOT_PASSWORD: "xxx"
|
||||||
|
MYSQL_DATABASE: wordpress
|
||||||
|
MYSQL_USER: wordpress
|
||||||
|
MYSQL_PASSWORD: "xxx"
|
||||||
|
|
||||||
|
wordpress:
|
||||||
|
depends_on:
|
||||||
|
- db
|
||||||
|
image: wordpress:latest
|
||||||
|
container_name: wordpress-example-wp
|
||||||
|
ports:
|
||||||
|
- "xx:80"
|
||||||
|
restart: unless-stopped
|
||||||
|
environment:
|
||||||
|
WORDPRESS_DB_HOST: db:3306
|
||||||
|
WORDPRESS_DB_USER: wordpress
|
||||||
|
WORDPRESS_DB_PASSWORD: "xxx"
|
||||||
|
volumes:
|
||||||
|
- ./config/php.conf.uploads.ini:/usr/local/etc/php/conf.d/uploads.ini
|
||||||
|
- ./wp-app/:/var/www/html # Full wordpress project
|
Loading…
Reference in a new issue