Created
November 13, 2019 12:19
-
-
Save rindrasakti/b83c7c0b2c6c5036e21fae86a9de3f67 to your computer and use it in GitHub Desktop.
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: "2" | |
services: | |
www: | |
build: . | |
ports: | |
- "81:80" | |
volumes: | |
- ./www:/var/www/html/ | |
links: | |
- db | |
networks: | |
- default | |
db: | |
image: mysql | |
ports: | |
- 3306:3306 | |
environment: | |
MYSQL_DATABASE: myDb | |
MYSQL_USER: user | |
MYSQL_PASSWORD: abc | |
MYSQL_ROOT_PASSWORD: abc | |
volumes: | |
- ./mysql:/docker-entrypoint-initdb.d | |
- ./mysqld:/var/lib/mysql | |
networks: | |
default: | |
ipv4_address: 172.16.0.2 | |
phpmyadmin: | |
image: phpmyadmin/phpmyadmin | |
links: | |
- db:db | |
ports: | |
- 8000:80 | |
environment: | |
MYSQL_USER: user | |
MYSQL_PASSWORD: abc | |
MYSQL_ROOT_PASSWORD: abc | |
networks: | |
default: | |
driver: bridge | |
ipam: | |
config: | |
- subnet: 172.16.0.0/24 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment