docker-compose not working , app filed to build
chchang@hqdc039:~/git/share$ cp .env.example .env
chchang@hqdc039:~/git/share$ vim .env
chchang@hqdc039:~/git/share$ docker-compose up -d
Creating network "share" with the default driver
Creating volume "share_share-mongodb-data" with default driver
Pulling mongodb (mongo:latest)...
latest: Pulling from library/mongo
f22ccc0b8772: Already exists
3cf8fb62ba5f: Already exists
e80c964ece6a: Already exists
329e632c35b3: Pull complete
3e1bd1325a3d: Pull complete
4aa6e3d64a4a: Pull complete
035bca87b778: Pull complete
874e4e43cb00: Pull complete
0e50e71d834e: Pull complete
27768a0d0c67: Pull complete
be4e0bd8b992: Pull complete
c887415d0643: Pull complete
Digest: sha256:7722bd2778a299b6f4a62b93a0d2741c734ba7332a090131030ca28261a9a198
Status: Downloaded newer image for mongo:latest
Building app
Step 1/12 : FROM node:10-alpine as builder
10-alpine: Pulling from library/node
0a6724ff3fcd: Pull complete
b258c56640f1: Pull complete
51a5f3cdff58: Pull complete
5e1af1677b84: Pull complete
Digest: sha256:aa38d0212b474344d2a0d180a1a656a34cff8a4c785adcb116de510d3f17f699
Status: Downloaded newer image for node:10-alpine
---> deec1e19c524
Step 2/12 : ARG NODE_ENV=development
---> Running in 2b0a8d867fae
Removing intermediate container 2b0a8d867fae
---> 8c090c58639a
Step 3/12 : ENV NODE_ENV=${NODE_ENV}
---> Running in 830e2c4d9508
Removing intermediate container 830e2c4d9508
---> dd1bc91cffbc
Step 4/12 : COPY package*.json ./
---> c67be2c04aed
Step 5/12 : RUN npm ci
---> Running in defe5e23940e
npm ERR! cipm can only install packages with an existing package-lock.json or npm-shrinkwrap.json with lockfileVersion >= 1. Run an install with npm@5 or later to generate it, then try again.
npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2021-01-06T01_32_18_129Z-debug.log
ERROR: Service 'app' failed to build: The command '/bin/sh -c npm ci' returned a non-zero code: 1
chchang@hqdc039:~/git/share$ docker-compose up -d
I'm getting the same.
Looks like I forgot to keep the package-lock.json. Which is why the npm ci is not working.
I can try to get a valid one for you or you could run npm i on the host to create one.
Really sorry have not put as much love into this as I wanted too. Trying to rebuild it in a better way which will allow me to integration a clean speedy front-end. Been slowly doing this and learning front-end on a deeper level.
the bug is still there ? I can not run with docker-compose today (2022/05/05)
Yes, me neither. Is this on the roadmap?