set NODE_ENV=PRODUCTION

This commit is contained in:
Sebastian Hugentobler 2020-04-05 13:06:49 +02:00
parent 7cec892627
commit 42624303d9

View File

@ -9,9 +9,8 @@ RUN apk add --no-cache \
# to get around errors from differing stack sizes in musl # to get around errors from differing stack sizes in musl
# https://wiki.musl-libc.org/functional-differences-from-glibc.html#Thread_stack_size # https://wiki.musl-libc.org/functional-differences-from-glibc.html#Thread_stack_size
#RUN npm config set unsafe-perm true RUN npm config set unsafe-perm true
#RUN npm install -g webpack webpack-cli RUN npm install -g webpack webpack-cli
RUN yarn global add webpack webpack-cli
ENV WIKIJS_VERSION=2.2.51 ENV WIKIJS_VERSION=2.2.51
@ -20,16 +19,13 @@ ADD nextcloud-auth.patch /build/nextcloud-auth.patch
WORKDIR /build WORKDIR /build
RUN git apply nextcloud-auth.patch RUN git apply nextcloud-auth.patch
#RUN npm install --production RUN npm install
#RUN make build RUN make build
RUN yarn cache clean
RUN yarn --non-interactive
RUN yarn build
RUN rm -rf ./node_modules
RUN yarn --production --non-interactive
FROM thallian/confd-env:latest FROM thallian/confd-env:latest
ENV NODE_ENV=PRODUCTION
RUN addgroup -g 2222 wikijs RUN addgroup -g 2222 wikijs
RUN adduser -h /home/wikijs -S -D -u 2222 -G wikijs wikijs RUN adduser -h /home/wikijs -S -D -u 2222 -G wikijs wikijs