From 7784a6fa71cb4aae9882b2813ff13fcd9132b285 Mon Sep 17 00:00:00 2001 From: LRVT <21357789+l4rm4nd@users.noreply.github.com> Date: Sun, 19 Feb 2023 18:22:09 +0100 Subject: [PATCH] Create docker-compose.yml --- wordpress/docker-compose.yml | 46 ++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 wordpress/docker-compose.yml diff --git a/wordpress/docker-compose.yml b/wordpress/docker-compose.yml new file mode 100644 index 0000000..bb5e2f9 --- /dev/null +++ b/wordpress/docker-compose.yml @@ -0,0 +1,46 @@ +version: '3.3' + +services: + wordpress-db: + image: mariadb:10.6.4-focal + container_name: wordpress-db + hostname: wordpress-db + command: '--default-authentication-plugin=mysql_native_password' + #networks: + # - proxy + volumes: + - /mnt/docker-volumes/wordpress/mysql:/var/lib/mysql + restart: unless-stopped + environment: + - MYSQL_ROOT_PASSWORD=wordpressroot + - MYSQL_DATABASE=wordpress + - MYSQL_USER=wordpress + - MYSQL_PASSWORD=wordpress + + wordpress: + image: wordpress:latest + container_name: wordpress + hostname: wordpress + volumes: + - /mnt/docker-volumes/wordpress/data:/var/www/html + ports: + - 80:80 + #networks: + # - proxy + restart: unless-stopped + environment: + - WORDPRESS_DB_HOST=wordpress-db + - WORDPRESS_DB_USER=wordpress + - WORDPRESS_DB_PASSWORD=wordpress + - WORDPRESS_DB_NAME=wordpress + #labels: + # - traefik.enable=true + # - traefik.http.routers.wordpress.rule=Host(`blog.example.com`) # please adjust + # - traefik.http.services.wordpress.loadbalancer.server.port=80 + # - traefik.docker.network=proxy + # # Part for optional traefik middlewares + # - traefik.http.routers.wordpress.middlewares=local-ipwhitelist@file + +#networks: +# proxy: +# external: true