Created
July 19, 2020 13:04
-
-
Save rochamarcelo/57ec366be4b734a9cf5bf82d461e6067 to your computer and use it in GitHub Desktop.
CakePHP docker setup
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: "3.1" | |
services: | |
php-fpm: | |
image: webdevops/php-nginx:7.4 | |
container_name: myapp-webserver | |
working_dir: /app | |
volumes: | |
- ./:/app | |
environment: | |
- WEB_DOCUMENT_ROOT=/app/webroot | |
ports: | |
- "80:80" | |
mysql: | |
image: mysql:5.6 | |
container_name: myapp-mysql | |
working_dir: /app | |
volumes: | |
- .:/app | |
- ./tmp/data/mysql_db:/var/lib/mysql | |
env_file: | |
- mysql.env | |
command: mysqld --character-set-server=utf8 --init-connect='SET NAMES UTF8;' | |
ports: | |
- "3306:3306" |
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
## DO NOT USE THESE VALUES ON PRODUCTION | |
## ONLY USE THIS FOR YOUR LOCAL ENVIRONMENT | |
MYSQL_ROOT_PASSWORD=password | |
MYSQL_DATABASE=my_app | |
MYSQL_USER=my_user | |
MYSQL_PASSWORD=password |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment