Files
Assignment6/Dockerfile
Chris 30a86a5890
All checks were successful
Build and Push Docker Image / docker (push) Successful in 48s
reworking git structure
2026-04-08 12:30:29 +00:00

19 lines
328 B
Docker

FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build-env
WORKDIR /app
COPY Example.csproj ./
RUN dotnet restore
COPY . .
RUN dotnet publish -c Release -o out
FROM mcr.microsoft.com/dotnet/aspnet:8.0
WORKDIR /app
COPY --from=build-env /app/out .
ENV ASPNETCORE_URLS=http://+:8080
EXPOSE 8080
ENTRYPOINT ["dotnet", "Example.dll"]