diff --git a/Dockerfile b/Dockerfile index c5174a6..c1855dd 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM node:14-alpine AS install +FROM node:16-alpine AS install WORKDIR /opt/openbmclapi RUN apk add build-base @@ -7,17 +7,17 @@ RUN npm ci ADD src . RUN npm run build -FROM node:14-alpine AS build +FROM node:16-alpine AS build RUN apk add nginx WORKDIR /opt/openbmclapi ADD package-lock.json package.json ./ +RUN npm ci --prod + COPY --from=install /opt/openbmclapi/dist ./dist COPY nginx/ /opt/openbmclapi/nginx -RUN npm ci --prod - ENV CLUSTER_PORT=4000 EXPOSE 4000 VOLUME /opt/openbmclapi/cache