Created
February 19, 2018 02:40
-
-
Save dfa1234/4f0521ab22e09de3470ad93032f69dc9 to your computer and use it in GitHub Desktop.
Docker compose for wordpress
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3.3' | |
services: | |
db: | |
image: mariadb:latest | |
volumes: | |
- ./db_data:/var/lib/mysql | |
ports: | |
- "3308:3306" | |
restart: always | |
environment: | |
MYSQL_ROOT_PASSWORD: wordpressROOT_PASSWORD | |
MYSQL_DATABASE: wordpress | |
MYSQL_USER: wordpressUSER | |
MYSQL_PASSWORD: wordpressPASSWORD | |
wordpress: | |
depends_on: | |
- db | |
image: wordpress:latest | |
volumes: | |
- ./www:/var/www/html | |
ports: | |
- "85:80" | |
restart: always | |
environment: | |
WORDPRESS_DB_HOST: db:3306 | |
WORDPRESS_DB_USER: wordpressUSER | |
WORDPRESS_DB_PASSWORD: wordpressPASSWORD | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment