-
Notifications
You must be signed in to change notification settings - Fork 5
/
Dockerfile
22 lines (18 loc) · 826 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 microsoft/dotnet:2.2-sdk-alpine AS build
RUN apk add --no-cache bash
WORKDIR /src
COPY . .
WORKDIR "/src/samples/MicroserviceDemo/microservices/ProductService.Host"
RUN dotnet restore -nowarn:msb3202,nu1503
RUN dotnet build --no-restore -c Release
WORKDIR "/src/samples/MicroserviceDemo/applications/AuthServer.Host"
RUN dotnet restore -nowarn:msb3202,nu1503
RUN dotnet build --no-restore -c Release
FROM build AS final
WORKDIR /src
COPY --from=build /src/samples/MicroserviceDemo/microservices/ProductService.Host ./ProductService.Host
COPY --from=build /src/samples/MicroserviceDemo/applications/AuthServer.Host ./AuthServer.Host
COPY --from=build /src/samples/MicroserviceDemo/databases/entrypoint.sh .
RUN /bin/bash -c "sed -i $'s/\r$//' entrypoint.sh"
RUN chmod +x ./entrypoint.sh
ENTRYPOINT ["./entrypoint.sh"]