I am running Docker on Windows 10 and when I run docker-compose up -d
I get this errror but I don’t know why.
npm WARN saveError ENOENT: no such file or directory, open '/var/www/package.json'
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN enoent ENOENT: no such file or directory, open '/var/www/package.json'
npm WARN www No description
npm WARN www No repository field.
npm WARN www No README data
npm WARN www No license field.
Here is my docker-compose.yaml file
version: '3'
services:
# Nginx client app server
nginx-client:
container_name: nginx-client
build:
context: ./docker/nginx-client
dockerfile: Dockerfile
restart: unless-stopped
ports:
- 28874:3000
volumes:
- ./client:/var/www
networks:
- app-network
# Networks
networks:
app-network:
driver: bridge
And here is my Dockerfile
FROM node:12
WORKDIR /var/www
RUN npm install
CMD ["npm", "run", "serve"]