Dockerfile
FROM node:alpine
WORKDIR '/app'
COPY package.json .
RUN npm install
COPY . .
CMD ["npm", "run", "start"]
docker-compose.yml
version: "3"
services:
web:
build:
context: .
dockerfile: Dockerfile
ports:
- "3000:3000"
volumes:
- /app/node_modules
- .:/app
command: ["npm", "start"]
Commands which I fired to get this up
docker-compose -f docker-compose.yml up --build
After this I went to https://localhost:3000 and this project did not load. Here is reproducible repo https://github.com/reyanshmishra/My-Portfolio-ReactJS
Thanks