dockerized the project for dev
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
services:
|
||||
app: # The name of the service, can be anything
|
||||
image: devcon-backend # Declares which image to use
|
||||
build: . # Declares where to build if image is not found
|
||||
ports: # Declares the ports to publish
|
||||
- 3000:3000
|
||||
mongo:
|
||||
image: mongo
|
||||
ports:
|
||||
- 3456:27017
|
||||
environment:
|
||||
MONGO_INITDB_ROOT_USERNAME: root
|
||||
MONGO_INITDB_ROOT_PASSWORD: example
|
||||
MONGO_INITDB_DATABASE: the_database
|
||||
volumes:
|
||||
- ./mongo/mongo-init.js:/docker-entrypoint-initdb.d/mongo-init.js
|
||||
- mongo_data:/data/db
|
||||
|
||||
volumes:
|
||||
mongo_data:
|
||||
Reference in New Issue
Block a user