Skip to content

Commit

Permalink
run as non root on docker
Browse files Browse the repository at this point in the history
  • Loading branch information
omerlh committed Jun 17, 2018
1 parent f89bc07 commit 9564bfc
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,9 @@ RUN dotnet publish -c Release -o out -r linux-x64

# Build runtime image
FROM microsoft/dotnet:2.0-runtime-deps
WORKDIR /app
RUN useradd -d /home/dotnet -ms /bin/bash dotnet
USER dotnet
WORKDIR /home/ubuntu/app
ENV ASPNETCORE_URLS=http://+:9999
COPY --from=build-env /app/out ./
ENTRYPOINT ["./Hamuste"]

0 comments on commit 9564bfc

Please sign in to comment.