Skip to content

Commit

Permalink
fix: ohhhh
Browse files Browse the repository at this point in the history
  • Loading branch information
qin-guan committed Jul 16, 2023
1 parent 1ca5068 commit 1587e5b
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM docker.io/library/node:lts AS base
FROM docker.io/library/node:lts-alpine AS base

# Prepare work directory
WORKDIR /wsa-tollbooth
Expand All @@ -8,13 +8,15 @@ FROM base AS builder
# Prepare pnpm https://pnpm.io/installation#using-corepack
RUN corepack enable

# Prepare deps
RUN apk update
RUN apk add git --no-cache

# Prepare build deps ( ignore postinstall scripts for now )
COPY .npmrc ./
COPY package.json ./
COPY pnpm-lock.yaml ./

RUN pnpm i --frozen-lockfile --ignore-scripts

# Copy all source files
COPY . ./

Expand All @@ -31,8 +33,8 @@ ARG GID=911

# Create a dedicated user and group
RUN set -eux; \
addgroup --gid $GID wsa-tollbooth; \
adduser --uid $UID --defaults --groups wsa-tollbooth wsa-tollbooth;
addgroup -g $GID wsa-tollbooth; \
adduser -u $UID -D -G wsa-tollbooth wsa-tollbooth;

USER wsa-tollbooth

Expand Down

0 comments on commit 1587e5b

Please sign in to comment.