diff --git a/SwiftParcel.Services.Parcels/Dockerfile b/SwiftParcel.Services.Parcels/Dockerfile new file mode 100644 index 0000000..7825062 --- /dev/null +++ b/SwiftParcel.Services.Parcels/Dockerfile @@ -0,0 +1,13 @@ +# Use the .NET 6.0 SDK image to build the application +FROM mcr.microsoft.com/dotnet/sdk:6.0 AS build +WORKDIR /app +COPY . . +RUN dotnet publish src/SwiftParcel.Services.Parcels.Api/SwiftParcel.Services.Parcels.Api -c release -o out + +# Use the .NET 6.0 runtime image to run the application +FROM mcr.microsoft.com/dotnet/aspnet:6.0 +WORKDIR /app +COPY --from=build /app/out . +ENV ASPNETCORE_URLS http://*:80 +ENV ASPNETCORE_ENVIRONMENT docker +ENTRYPOINT ["dotnet", "SwiftParcel.Services.Parcels.Api.dll"]