added mongo credentials

This commit is contained in:
Gautier DELEGLISE 2021-09-20 11:13:00 +02:00 committed by GitHub
parent aaf04367e6
commit 147ff33530
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -656,6 +656,9 @@ services:
build: ./mongo build: ./mongo
ports: ports:
- "${MONGODB_PORT}:27017" - "${MONGODB_PORT}:27017"
environment:
- MONGO_INITDB_ROOT_USERNAME=${MONGO_USERNAME}
- MONGO_INITDB_ROOT_PASSWORD=${MONGO_PASSWORD}
volumes: volumes:
- ${DATA_PATH_HOST}/mongo:/data/db - ${DATA_PATH_HOST}/mongo:/data/db
- ${DATA_PATH_HOST}/mongo_config:/data/configdb - ${DATA_PATH_HOST}/mongo_config:/data/configdb