Created
March 26, 2021 12:23
-
-
Save varsubham/29bdffff6e7ed12eb367aafa6f91b7e5 to your computer and use it in GitHub Desktop.
docker-compose file for nodejs and MYSQL
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.8" | |
services: | |
db: | |
build: ./db | |
environment: | |
MYSQL_ROOT_PASSWORD: password | |
MYSQL_DATABASE: test | |
restart: always | |
web: | |
build: ./web | |
environment: | |
MYSQL_DATABASE: test | |
MYSQL_USER: root | |
MYSQL_PASSWORD: password | |
MYSQL_HOST: db | |
ports: | |
- "5000:5000" | |
depends_on: | |
- db | |
restart: on-failure |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment