Skip to content

Commit

Permalink
fix: dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
karolsojko committed Nov 30, 2023
1 parent 2433bf4 commit 823cf70
Showing 1 changed file with 8 additions and 18 deletions.
26 changes: 8 additions & 18 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,26 +1,16 @@
FROM node:20.6.1-alpine3.15
FROM node:20.6.1-alpine

ARG UID=1001
ARG GID=1001
RUN apk add --update \
curl \
&& rm -rf /var/cache/apk/*

RUN addgroup -S mockevent -g $GID && adduser -D -S mockevent -G mockevent -u $UID
ENV NODE_ENV production

RUN apk add --update --no-cache \
curl \
alpine-sdk \
python3
RUN corepack enable

WORKDIR /var/www
COPY ./ /workspace

RUN chown -R $UID:$GID .

USER mockevent

COPY --chown=$UID:$GID package.json yarn.lock /var/www/

RUN yarn install --immutable

COPY --chown=$UID:$GID . /var/www
WORKDIR /workspace

RUN yarn build

Expand Down

0 comments on commit 823cf70

Please sign in to comment.