Don't need to create a user in Docker anymore with .NET 8

This commit is contained in:
Tyrrrz 2023-11-14 23:24:28 +02:00
parent 73574ade48
commit 6a71c59b6d

View file

@ -42,14 +42,11 @@ ENV DOTNET_SYSTEM_GLOBALIZATION_INVARIANT=false
ENV LC_ALL=en_US.UTF-8
ENV LANG=en_US.UTF-8
# Create a non-root user to run the app, so that the output files can be accessed by the host
# https://github.com/Tyrrrz/DiscordChatExporter/issues/851
RUN adduser --disabled-password --no-create-home dce
USER dce
# This directory is exposed to the user for mounting purposes, so it's important that it always
# stays the same for backwards compatibility.
WORKDIR /out
COPY --from=build /tmp/dce/DiscordChatExporter.Cli/bin/publish /opt/dce
USER $APP_UID
ENTRYPOINT ["/opt/dce/DiscordChatExporter.Cli"]