Skip to content

Commit

Permalink
Create the loot user with a fixed uid because `COPY --link --chown=<u…
Browse files Browse the repository at this point in the history
…sername>` is unsupported, but `COPY --link --chown=<uid>` is
  • Loading branch information
scottohara committed Oct 17, 2024
1 parent 37f0ed3 commit c8445bb
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ RUN apk add --no-cache \
libpq \
tzdata

RUN adduser --system loot
RUN adduser --system --uid 100 loot
USER loot
WORKDIR /loot
ENV RACK_ENV=production
Expand All @@ -71,17 +71,17 @@ RUN \

RUN mkdir -p tmp/pids

COPY --link --chown=loot \
COPY --link --chown=100 \
.tool-versions \
config.ru \
Gemfile* \
Rakefile ./

COPY --link --chown=loot db db/
COPY --link --chown=loot config config/
COPY --link --chown=loot app app/
COPY --link --chown=loot --from=backend build/vendor/bundle vendor/bundle/
COPY --link --chown=loot --from=frontend build/public public/
COPY --link --chown=100 db db/
COPY --link --chown=100 config config/
COPY --link --chown=100 app app/
COPY --link --chown=100 --from=backend build/vendor/bundle vendor/bundle/
COPY --link --chown=100 --from=frontend build/public public/

EXPOSE 3000

Expand Down

0 comments on commit c8445bb

Please sign in to comment.