docker: fix docker images for arm64
This commit is contained in:
parent
dc0541eabf
commit
e87d5af7ee
1 changed files with 23 additions and 32 deletions
13
Dockerfile
13
Dockerfile
|
|
@ -35,16 +35,7 @@ RUN \
|
||||||
git clone https://github.com/rogerfar/rdt-client.git . && \
|
git clone https://github.com/rogerfar/rdt-client.git . && \
|
||||||
echo "**** Building Source Code for $TARGETPLATFORM on $BUILDPLATFORM ****" && \
|
echo "**** Building Source Code for $TARGETPLATFORM on $BUILDPLATFORM ****" && \
|
||||||
cd server && \
|
cd server && \
|
||||||
if [ "$TARGETPLATFORM" = "linux/arm/v7" ] ; then \
|
dotnet restore --no-cache RdtClient.sln && dotnet publish --no-restore -c Release -o out ;
|
||||||
echo "**** Building $TARGETPLATFORM arm v7 version" && \
|
|
||||||
dotnet restore --no-cache -r linux-arm RdtClient.sln && dotnet publish --no-restore -r linux-arm -c Release -o out ; \
|
|
||||||
elif [ "$TARGETPLATFORM" = "linux/arm/v8" ] ; then \
|
|
||||||
echo "**** Building $TARGETPLATFORM arm v8 version" && \
|
|
||||||
dotnet restore --no-cache -r linux-arm64 RdtClient.sln && dotnet publish --no-restore -r linux-arm64 -c Release -o out ; \
|
|
||||||
else \
|
|
||||||
echo "**** Building $TARGETPLATFORM x64 version" && \
|
|
||||||
dotnet restore --no-cache RdtClient.sln && dotnet publish --no-restore -c Release -o out ; \
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Stage 3 - Build runtime image
|
# Stage 3 - Build runtime image
|
||||||
FROM ghcr.io/linuxserver/baseimage-alpine:3.18
|
FROM ghcr.io/linuxserver/baseimage-alpine:3.18
|
||||||
|
|
@ -77,7 +68,7 @@ RUN \
|
||||||
if [ "$TARGETPLATFORM" = "linux/arm/v7" ] ; then \
|
if [ "$TARGETPLATFORM" = "linux/arm/v7" ] ; then \
|
||||||
wget https://download.visualstudio.microsoft.com/download/pr/c3bf3103-efdb-42e0-af55-bbf861a4215b/dc22eda8877933b8c6569e3823f18d21/aspnetcore-runtime-8.0.0-linux-musl-arm64.tar.gz && \
|
wget https://download.visualstudio.microsoft.com/download/pr/c3bf3103-efdb-42e0-af55-bbf861a4215b/dc22eda8877933b8c6569e3823f18d21/aspnetcore-runtime-8.0.0-linux-musl-arm64.tar.gz && \
|
||||||
tar zxf aspnetcore-runtime-8.0.0-linux-musl-arm64.tar.gz -C /usr/share/dotnet ; \
|
tar zxf aspnetcore-runtime-8.0.0-linux-musl-arm64.tar.gz -C /usr/share/dotnet ; \
|
||||||
elif [ "$TARGETPLATFORM" = "linux/arm/v8" ] ; then \
|
elif [ "$TARGETPLATFORM" = "linux/arm64" ] ; then \
|
||||||
wget https://download.visualstudio.microsoft.com/download/pr/c3bf3103-efdb-42e0-af55-bbf861a4215b/dc22eda8877933b8c6569e3823f18d21/aspnetcore-runtime-8.0.0-linux-musl-arm64.tar.gz && \
|
wget https://download.visualstudio.microsoft.com/download/pr/c3bf3103-efdb-42e0-af55-bbf861a4215b/dc22eda8877933b8c6569e3823f18d21/aspnetcore-runtime-8.0.0-linux-musl-arm64.tar.gz && \
|
||||||
tar zxf aspnetcore-runtime-8.0.0-linux-musl-arm64.tar.gz -C /usr/share/dotnet ; \
|
tar zxf aspnetcore-runtime-8.0.0-linux-musl-arm64.tar.gz -C /usr/share/dotnet ; \
|
||||||
else \
|
else \
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue