-
Notifications
You must be signed in to change notification settings - Fork 2
/
Dockerfile.Thumbs
28 lines (21 loc) · 999 Bytes
/
Dockerfile.Thumbs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
FROM mcr.microsoft.com/dotnet/sdk:6.0 AS build
WORKDIR /src
COPY ["Thumbs/Thumbs.csproj", "Thumbs/"]
COPY ["DLCS.Core/DLCS.Core.csproj", "DLCS.Core/"]
COPY ["DLCS.AWS/DLCS.AWS.csproj", "DLCS.AWS/"]
COPY ["DLCS.Repository/DLCS.Repository.csproj", "DLCS.Repository/"]
COPY ["DLCS.Model/DLCS.Model.csproj", "DLCS.Model/"]
COPY ["DLCS.Web/DLCS.Web.csproj", "DLCS.Web/"]
RUN dotnet restore "Thumbs/Thumbs.csproj"
COPY . .
WORKDIR "/src/Thumbs"
RUN dotnet build "Thumbs.csproj" -c Release -o /app/build
FROM build AS publish
RUN dotnet publish "Thumbs.csproj" -c Release -o /app/publish
FROM mcr.microsoft.com/dotnet/aspnet:6.0-bullseye-slim AS base
LABEL maintainer="Donald Gray <[email protected]>,Tom Crane <[email protected]>"
LABEL org.opencontainers.image.source=https://github.com/dlcs/protagonist
LABEL org.opencontainers.image.description="DLCS Thumbs. Serves pregenerated images derivatives."
WORKDIR /app
COPY --from=publish /app/publish .
ENTRYPOINT ["dotnet", "Thumbs.dll"]