Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reworked adding non-root user to docker images. #1052

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@ LABEL org.opencontainers.image.licenses="Apache-2.0, GPL-2.0"
LABEL org.opencontainers.image.title="ntfy"
LABEL org.opencontainers.image.description="Send push notifications to your phone or desktop using PUT/POST"

RUN apk add --no-cache tzdata
RUN apk add --no-cache tzdata \
&& /usr/sbin/adduser -D -u 10001 ntfy
COPY ntfy /usr/bin

EXPOSE 80/tcp
Expand Down
2 changes: 2 additions & 0 deletions Dockerfile-build
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,8 @@ LABEL org.opencontainers.image.licenses="Apache-2.0, GPL-2.0"
LABEL org.opencontainers.image.title="ntfy"
LABEL org.opencontainers.image.description="Send push notifications to your phone or desktop using PUT/POST"

RUN /usr/sbin/adduser -D -u 10001 ntfy

COPY --from=builder /app/dist/ntfy_linux_server/ntfy /usr/bin/ntfy

EXPOSE 80/tcp
Expand Down
Loading