diff --git a/Dockerfile b/Dockerfile index fde8e2b..2a6f59a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -4,7 +4,11 @@ #CMD ["/opt/app/index.js", "/var/lib/fritzbox-to-mqtt-gw/config.json"] FROM node:18.12-alpine -COPY app/dist /opt/app/ +COPY app /opt/app/ WORKDIR /opt/app/ +RUN npm install npm-run-all --save-dev +RUN npm run build +WORKDIR /opt/app/dist/ +RUN mkdir /var/lib/fritzbox-to-mqtt-gw CMD ["node", "index.js", "/var/lib/fritzbox-to-mqtt-gw/config.json"] diff --git a/app/package-lock.json b/app/package-lock.json index 640802a..2429f06 100755 --- a/app/package-lock.json +++ b/app/package-lock.json @@ -28,7 +28,7 @@ "jest": "29.2.2", "jest-junit": "14.0.1", "jest-standard-reporter": "2.0.0", - "npm-run-all": "4.1.5", + "npm-run-all": "^4.1.5", "rimraf": "3.0.2", "testcontainers": "9.0.0", "ts-jest": "29.0.3", diff --git a/app/package.json b/app/package.json index 2d5f404..9742a4c 100755 --- a/app/package.json +++ b/app/package.json @@ -32,7 +32,7 @@ "jest": "29.2.2", "jest-junit": "14.0.1", "jest-standard-reporter": "2.0.0", - "npm-run-all": "4.1.5", + "npm-run-all": "^4.1.5", "rimraf": "3.0.2", "testcontainers": "9.0.0", "ts-jest": "29.0.3",