pwt-final-countdown/Dockerfile.dev
surtur d63715392e
All checks were successful
continuous-integration/drone/push Build is passing
initial commit
2020-12-17 14:53:05 +01:00

23 lines
534 B
Docker

FROM mcr.microsoft.com/dotnet/core/sdk:3.1-alpine
ENV UID 1000
ENV GID 1000
ENV UNAME unpriv
RUN adduser -D -u ${UID} -g ${GID} -H ${UNAME} -h /src
WORKDIR /src
COPY global.json ./
RUN sed -i 's/3.1.110/3.1.404/' global.json
COPY *.csproj ./
RUN dotnet restore
COPY . ./
RUN sed -i 's/3.1.110/3.1.404/' global.json
RUN dotnet build -c Debug -o bin/out
RUN chown -R ${UID}:${GID} ./ /root/
USER ${UNAME}
ENV ASPNETCORE_ENVIRONMENT=Development
ENTRYPOINT ["dotnet", "watch", "run", "--no-restore", "--urls", "http://0.0.0.0:5000"]