Last active
March 13, 2020 11:48
-
-
Save Matheus-de-Souza/b5d5eb8c8f101f026aaede0a244bde01 to your computer and use it in GitHub Desktop.
Wordpress + Docker
This file contains 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: '2' | |
services: | |
db: | |
image: mysql:5.7 | |
volumes: | |
- ./data/mysql-db:/var/lib/mysql | |
restart: always | |
environment: | |
MYSQL_ROOT_PASSWORD: 12345678 | |
MYSQL_DATABASE: wordpress | |
MYSQL_USER: usuario_banco | |
MYSQL_PASSWORD: 12345678 | |
wordpress: | |
depends_on: | |
- db | |
build: . | |
volumes: | |
- ./src/wordpress/:/var/www/html/ | |
ports: | |
- "80:80" | |
restart: always | |
environment: | |
WORDPRESS_DB_HOST: db:3306 | |
WORDPRESS_DB_USER: usuario_banco | |
WORDPRESS_DB_PASSWORD: 12345678 | |
volumes: | |
db_data: |
This file contains 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
FROM wordpress:latest | |
RUN chown -Rf www-data.www-data /var/www/html/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment