You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

56 lines
1.3 KiB

services:
web:
container_name: web
build:
context: ./web
dockerfile: Dockerfile
ports:
- "3000:3000"
depends_on:
- mongo
environment:
NODE_ENV: production
api:
container_name: api
build:
context: ./api
dockerfile: Dockerfile
target: prod
ports:
- "3005:3005"
depends_on:
- mongo
environment:
NODE_ENV: production
mongo:
container_name: mongo
image: mongo
restart: always
ports:
- "27017:27017"
environment:
MONGO_INITDB_ROOT_USERNAME: adminUser
MONGO_INITDB_ROOT_PASSWORD: adminPassword
MONGO_INITDB_DATABASE: TextBee
volumes:
- textbee-db-data:/data/db
# THe following scripts creates TextBee DB automatically, also the user which web and api are connecting with.
- ./mongo-init:/docker-entrypoint-initdb.d:ro
mongo-express:
container_name: mongo-ee
image: mongo-express
restart: always
ports:
- "8081:8081"
environment:
ME_CONFIG_MONGODB_ADMINUSERNAME: adminUser
ME_CONFIG_MONGODB_ADMINPASSWORD: adminPassword
ME_CONFIG_MONGODB_URL: mongodb://adminUser:adminPassword@mongo:27017/
ME_CONFIG_BASICAUTH: "false"
depends_on:
- mongo
volumes:
textbee-db-data: