2022-03-05 16:02:04 +00:00
|
|
|
FROM mcr.microsoft.com/dotnet/sdk:6.0-focal AS base
|
2021-04-10 00:11:48 +05:00
|
|
|
|
2019-10-31 17:25:49 +05:00
|
|
|
# Native libgdiplus dependencies
|
|
|
|
RUN apt-get update
|
2020-06-02 18:02:29 +05:00
|
|
|
RUN apt-get install -y --allow-unauthenticated libc6-dev libgdiplus libx11-dev fonts-roboto
|
2021-04-10 00:11:48 +05:00
|
|
|
|
2021-01-27 22:11:49 +05:00
|
|
|
# debian-specific?
|
|
|
|
#RUN rm -rf /var/lib/apt/lists/*
|
|
|
|
#RUN ln -s /lib/x86_64-linux-gnu/libdl-2.24.so /lib/x86_64-linux-gnu/libdl.so
|
2021-04-10 00:11:48 +05:00
|
|
|
|
2019-10-31 17:25:49 +05:00
|
|
|
# Regular stuff
|
2021-04-10 00:11:48 +05:00
|
|
|
#COPY packages /root/.nuget/packages/
|
2019-08-24 20:46:10 +05:00
|
|
|
WORKDIR /src
|
|
|
|
COPY . .
|
2021-04-10 00:11:48 +05:00
|
|
|
#RUN rm -rf ./packages
|
2022-03-05 15:10:32 +00:00
|
|
|
RUN git status
|
2022-03-06 12:26:32 +00:00
|
|
|
# Asks for user/pw otherwise..
|
|
|
|
RUN git remote set-url origin git://github.com/RPCS3/discord-bot
|
2019-10-31 17:25:49 +05:00
|
|
|
# Build and test everything
|
2021-04-10 00:11:48 +05:00
|
|
|
RUN dotnet restore "CompatBot/CompatBot.csproj"
|
2019-08-24 20:46:10 +05:00
|
|
|
RUN dotnet build "CompatBot/CompatBot.csproj" -c Release
|
|
|
|
ENV RUNNING_IN_DOCKER true
|
2020-07-30 17:06:50 +05:00
|
|
|
# Limit server GC to 512 MB heap max
|
2020-07-30 17:05:40 +05:00
|
|
|
ENV COMPlus_gcServer 1
|
2020-11-10 22:05:52 +05:00
|
|
|
# ENV COMPlus_GCHeapHardLimit 0x20000000
|
2019-08-24 20:46:10 +05:00
|
|
|
WORKDIR /src/CompatBot
|
|
|
|
RUN dotnet run -c Release --dry-run
|
2019-09-24 14:56:49 +05:00
|
|
|
ENTRYPOINT ["dotnet", "run", "-c", "Release", "CompatBot.csproj"]
|