forked from openwallet-foundation/owl-agent-test-harness
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile.dotnet
49 lines (36 loc) · 1.5 KB
/
Dockerfile.dotnet
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
# Final image needs indy
# FROM streetcred/dotnet-indy:1.15.0 AS base
# WORKDIR /app
# FROM mcr.microsoft.com/dotnet/core/sdk:3.1 AS build
# WORKDIR /src
# COPY dotnet/server/DotNet.Backchannel.csproj ./DotNet.Backchannel.csproj
# RUN dotnet restore "DotNet.Backchannel.csproj"
# COPY dotnet/server .
# RUN dotnet publish "DotNet.Backchannel.csproj" -c Release -o /app/publish
# FROM base AS final
# WORKDIR /app
# COPY --from=build /app/publish .
# ENTRYPOINT ["dotnet", "DotNet.Backchannel.dll"]
# Temporary fix 2022.05.13 -- "dotnet" build is not working.
# Fix is to comment out the original dotnet Dockerfile above ^^^
# with the "dotnet-master" Dockerfile below vvvv
# That allows both "dotnet" and "dotnet-master" test agents to work -- they are the same.
# Both are pulling from the repo vs. from the published version.
# Final image needs indy
FROM streetcred/dotnet-indy:1.15.0 AS base
WORKDIR /app
FROM mcr.microsoft.com/dotnet/core/sdk:3.1 AS build
WORKDIR /
RUN git clone https://github.com/hyperledger/aries-framework-dotnet.git
WORKDIR /src
COPY dotnet/server/DotNet.Backchannel.Master.csproj ./DotNet.Backchannel.Master.csproj
RUN dotnet restore "DotNet.Backchannel.Master.csproj"
COPY dotnet/server .
RUN dotnet publish "DotNet.Backchannel.Master.csproj" -c Release -o /app/publish
FROM base AS final
WORKDIR /app
COPY --from=build /app/publish .
ADD https://github.com/stedolan/jq/releases/download/jq-1.6/jq-linux64 ./jq
RUN chmod +x ./jq
COPY ./dotnet/ngrok-wait.sh .
ENTRYPOINT ["bash", "./ngrok-wait.sh"]