Skip to content

Commit 721f07c

Browse files
committed
Install .NET using dotnet-install.
This puts the SDKs in the same place `setup-dotnet` will look for them.
1 parent 9b5c27a commit 721f07c

File tree

1 file changed

+18
-3
lines changed

1 file changed

+18
-3
lines changed

linux/summerwind.Dockerfile

Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,11 +35,26 @@ RUN sudo curl -sLO https://github.com/PowerShell/PowerShell/releases/download/v7
3535
RUN sudo add-apt-repository ppa:dotnet/backports \
3636
&& sudo apt-get update \
3737
&& sudo apt-get install -y \
38+
ca-certificates \
3839
gettext-base \
39-
dotnet-sdk-8.0 \
40-
dotnet-runtime-9.0 \
40+
libc6 \
41+
libgcc-s1 \
42+
libgssapi-krb5-2 \
43+
libicu70 \
44+
libssl3 \
45+
libstdc++6 \
46+
tzdata \
47+
zlib1g \
4148
&& sudo rm -rf /var/lib/apt/lists/*
4249

50+
ENV DOTNET_INSTALL_DIR=/home/runner/.dotnet
51+
52+
RUN curl -L https://dot.net/v1/dotnet-install.sh -o /home/runner/dotnet-install.sh && \
53+
chmod +x /home/runner/dotnet-install.sh && \
54+
/home/runner/dotnet-install.sh --install-dir $DOTNET_INSTALL_DIR --channel 8.0 && \
55+
/home/runner/dotnet-install.sh --install-dir $DOTNET_INSTALL_DIR --channel 9.0 && \
56+
/home/runner/dotnet-install.sh --install-dir $DOTNET_INSTALL_DIR --channel 10.0 && \
57+
rm /home/runner/dotnet-install.sh
58+
4359
COPY docker-system-prune /etc/arc/hooks/job-completed.d/
4460

45-
ENV DOTNET_INSTALL_DIR=/home/runner/.dotnet

0 commit comments

Comments
 (0)