version: '3' services: app: working_dir: /usr/src/app # command: npm start build: . depends_on: - db volumes: - node_modules:/usr/src/app/node_modules:cached - ./:/usr/src/app:cached ports: - "8082:3000" #host:container, 3000 is the default port of Express.js stdin_open: true tty: true db: image: bitnami/mongodb volumes: - ./db_data:/bitnami/mongodb - ./init-mongo.js:/docker-entrypoint-initdb.d/init-mongo.js volumes: node_modules: