|
@@ -6,7 +6,12 @@ ENV NODE_ENV=production
|
|
|
ENV PORT=3000
|
|
ENV PORT=3000
|
|
|
|
|
|
|
|
COPY package*.json ./
|
|
COPY package*.json ./
|
|
|
-RUN npm install --omit=dev --no-audit --no-fund
|
|
|
|
|
|
|
+RUN set -eux; \
|
|
|
|
|
+ npm install --omit=dev --no-audit --no-fund --loglevel verbose; \
|
|
|
|
|
+ if grep -R "Exit handler never called" /root/.npm/_logs 2>/dev/null; then \
|
|
|
|
|
+ cat /root/.npm/_logs/*debug-0.log; \
|
|
|
|
|
+ exit 1; \
|
|
|
|
|
+ fi
|
|
|
RUN node -e "require('express'); require('better-sqlite3'); console.log('runtime dependencies ok')"
|
|
RUN node -e "require('express'); require('better-sqlite3'); console.log('runtime dependencies ok')"
|
|
|
|
|
|
|
|
COPY src ./src
|
|
COPY src ./src
|