mirror of https://github.com/LemmyNet/lemmy.git
Update Dockerfile to run process as non-privileged user. (#3709)
parent
102124b6d2
commit
13a866aeb0
|
@ -37,4 +37,9 @@ RUN apk add --no-cache libpq
|
||||||
# Copy resources
|
# Copy resources
|
||||||
COPY --from=builder /app/lemmy_server /app/lemmy
|
COPY --from=builder /app/lemmy_server /app/lemmy
|
||||||
|
|
||||||
|
# Create non-privileged user
|
||||||
|
RUN adduser -h /app -s sh -S -u 1000 lemmy
|
||||||
|
RUN chown -R lemmy /app
|
||||||
|
USER lemmy
|
||||||
|
|
||||||
CMD ["/app/lemmy"]
|
CMD ["/app/lemmy"]
|
||||||
|
|
Loading…
Reference in New Issue