Answer the question
In order to leave comments, you need to log in
How to set up docker?
Hello!
I'm trying to set up docker to work with a project on mern
, this is how the docker configs docker
-compose.yml look like
version: '3'
services:
app:
container_name: node_app
restart: always
build: .
ports:
- '80:8080'
links:
- mongo
mongo:
container_name: mongo
image: mongo
ports:
- '27017:27017'
FROM node:10
WORKDIR /usr/src/app
COPY package*.json ./
RUN npm install
COPY . .
EXPOSE 8080
CMD ["npm", "start"]
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question