Last active
February 8, 2021 19:10
-
-
Save unreadable/8a5b53c3760a323273303ff69d60b4a3 to your computer and use it in GitHub Desktop.
Docker compose file for node and mongo
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
# change mongo url to mongodb://mongo:27017 | |
version: "3" | |
services: | |
app: | |
container_name: express-api | |
restart: always | |
build: . | |
ports: | |
- '3000:3000' | |
networks: | |
- express-mongo | |
depends_on: | |
- mongo | |
mongo: | |
container_name: mongo | |
image: mongo | |
ports: | |
- '27017:27017' | |
networks: | |
- express-mongo | |
networks: | |
express-mongo: | |
driver: bridge |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment