-
Notifications
You must be signed in to change notification settings - Fork 15
/
Dockerfile
22 lines (19 loc) · 786 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
FROM mcr.microsoft.com/dotnet/aspnet:8.0 AS base
WORKDIR /app
EXPOSE 59919
EXPOSE 44339
EXPOSE 80
FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build
WORKDIR /src
COPY ["HueLightDJ.BlazorWeb/Server/HueLightDJ.BlazorWeb.Server.csproj", "HueLightDJ.BlazorWeb/Server/"]
COPY ["HueLightDJ.Effects/HueLightDJ.Effects.csproj", "HueLightDJ.Effects/"]
RUN dotnet restore "HueLightDJ.BlazorWeb/Server/HueLightDJ.BlazorWeb.Server.csproj"
COPY . .
WORKDIR "/src/HueLightDJ.BlazorWeb/Server"
RUN dotnet build "HueLightDJ.BlazorWeb.Server.csproj" -c Release -o /app/build
FROM build AS publish
RUN dotnet publish "HueLightDJ.BlazorWeb.Server.csproj" -c Release -o /app/publish
FROM base AS final
WORKDIR /app
COPY --from=publish /app/publish .
ENTRYPOINT ["dotnet", "HueLightDJ.BlazorWeb.Server.dll"]