Refactored deployment files

This commit is contained in:
2026-05-09 17:11:43 +02:00
parent b08e891020
commit bd109abb26
5 changed files with 275 additions and 56 deletions
+4 -4
View File
@@ -3,10 +3,10 @@ FROM mcr.microsoft.com/dotnet/sdk:10.0 AS build
WORKDIR /app
COPY ["../nuget.config", "./"]
COPY ["../LeadGenerator/LeadGenerator.csproj", "LeadGenerator/"]
RUN dotnet restore "LeadGenerator/LeadGenerator.csproj" --configfile nuget.config
COPY ["../Shop/Shop.csproj", "Shop/"]
RUN dotnet restore "Shop/Shop.csproj" --configfile nuget.config
COPY . .
RUN dotnet publish "../LeadGenerator/LeadGenerator.csproj" -c Release -o /app/publish /p:UseAppHost=false
RUN dotnet publish "../Shop/Shop.csproj" -c Release -o /app/publish /p:UseAppHost=false
# Stage 2: Final Image
FROM mcr.microsoft.com/dotnet/aspnet:10.0 AS final
@@ -22,4 +22,4 @@ COPY --from=build /app/publish .
RUN chown -R appuser:appgroup /app
USER appuser
ENTRYPOINT ["dotnet", "LeadGenerator.dll"]
ENTRYPOINT ["dotnet", "Shop.dll"]