19 lines
614 B
Docker
19 lines
614 B
Docker
FROM mcr.microsoft.com/dotnet/runtime:6.0 AS base
|
|
WORKDIR /app
|
|
|
|
FROM mcr.microsoft.com/dotnet/sdk:6.0 AS build
|
|
WORKDIR /src
|
|
COPY ["BlueWest.Api.Gateway/BlueWest.Api.Gateway.csproj", "BlueWest.Api.Gateway/"]
|
|
RUN dotnet restore "BlueWest.Api.Gateway/BlueWest.Api.Gateway.csproj"
|
|
COPY . .
|
|
WORKDIR "/src/BlueWest.Api.Gateway"
|
|
RUN dotnet build "BlueWest.Api.Gateway.csproj" -c Release -o /app/build
|
|
|
|
FROM build AS publish
|
|
RUN dotnet publish "BlueWest.Api.Gateway.csproj" -c Release -o /app/publish
|
|
|
|
FROM base AS final
|
|
WORKDIR /app
|
|
COPY --from=publish /app/publish .
|
|
ENTRYPOINT ["dotnet", "BlueWest.Api.Gateway.dll"]
|