Skip to content

Commit

Permalink
Run as a non-root user
Browse files Browse the repository at this point in the history
  • Loading branch information
Inkvi committed May 28, 2024
1 parent 2777f58 commit 680e471
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,17 @@ FROM node:18-alpine

WORKDIR /app

RUN npm install -g ts-node

COPY package*.json ./

RUN npm install
RUN adduser -D polymer
RUN chown -R polymer:polymer /app
USER polymer

COPY src src
RUN npm install

RUN npm install -g ts-node
COPY src src

EXPOSE 8000

Expand Down

0 comments on commit 680e471

Please sign in to comment.