summaryrefslogtreecommitdiff
path: root/core/Dockerfile
blob: 935084f3ef2056e812f6efe9b3bcedfef8a894a3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
FROM microsoft/dotnet:sdk AS build-env    
 MAINTAINER Dennis Kobert <d-kobert@web.de>    
 # Install cgit    
 RUN git clone git://github.com/TrueDoctor/DiscoBot && cd DiscoBot && mkdir app && cp DSACore/*.csproj app/    
 WORKDIR /DiscoBot/app    
     
 RUN dotnet restore    
     
 # Copy everything else and build    
 RUN cp -r ../DSACore/ ../app &&  dotnet publish -c Release -o out    
     
     
 # Build runtime image    
 FROM microsoft/dotnet:aspnetcore-runtime    
 WORKDIR /app/    
 COPY Token ./    
 COPY --from=build-env /DiscoBot/app/out .    
 RUN cp -r DSACore/Properties ./    
 ENTRYPOINT ["dotnet", "DSACore.dll"]