Something went wrong. Try again.
simple chat app using ASP.net core SignalR and MongoDB
Something went wrong. Try again.
123456789101112131415161718192021222324252627282930# See https://aka.ms/customizecontainer to learn how to customize your debug container and how Visual Studio uses this Dockerfile to build your images for faster debugging.
# This stage is used when running from VS in fast mode (Default for Debug configuration)FROM mcr.microsoft.com/dotnet/aspnet:8.0 AS baseUSER $APP_UIDWORKDIR /appEXPOSE 8080EXPOSE 8081
# This stage is used to build the service projectFROM mcr.microsoft.com/dotnet/sdk:8.0 AS buildARG BUILD_CONFIGURATION=ReleaseWORKDIR /srcCOPY ["Chat.csproj", "."]RUN dotnet restore "./Chat.csproj"COPY . .WORKDIR "/src/."RUN dotnet build "./Chat.csproj" -c $BUILD_CONFIGURATION -o /app/build
# This stage is used to publish the service project to be copied to the final stageFROM build AS publishARG BUILD_CONFIGURATION=ReleaseRUN dotnet publish "./Chat.csproj" -c $BUILD_CONFIGURATION -o /app/publish /p:UseAppHost=false
# This stage is used in production or when running from VS in regular mode (Default when not using the Debug configuration)FROM base AS finalWORKDIR /appCOPY --from=publish /app/publish .ENTRYPOINT ["dotnet", "Chat.dll"]