Get up and running with Kimi, GLM, MiniMax, DeepSeek, gpt-oss, Qwen, Gemma and other models.
ci: harden download steps with retries (#18883)
Daniel Hiltgen007decd15761
diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yamlindex 9f2a6103a..8517dcd1e 100644--- a/.github/workflows/release.yaml+++ b/.github/workflows/release.yaml@@ -202,8 +202,9 @@ jobs:- if: matrix.preset == 'CPU'name: Install Windows ARM64 cross compilerrun: |- Invoke-WebRequest -Uri "https://github.com/mstorsjo/llvm-mingw/releases/download/20240619/llvm-mingw-20240619-ucrt-x86_64.zip" -OutFile "${{ runner.temp }}\llvm-mingw-ucrt.zip"+ Invoke-WebRequest -Uri "https://github.com/mstorsjo/llvm-mingw/releases/download/20240619/llvm-mingw-20240619-ucrt-x86_64.zip" -OutFile "${{ runner.temp }}\llvm-mingw-ucrt.zip" -MaximumRetryCount 3 -RetryIntervalSec 2Expand-Archive -Path ${{ runner.temp }}\llvm-mingw-ucrt.zip -DestinationPath "C:\Program Files\"+ Remove-Item "${{ runner.temp }}\llvm-mingw-ucrt.zip"$installPath=(Resolve-Path -Path "C:\Program Files\llvm-mingw-*-ucrt-x86_64").pathif (!(Test-Path "$installPath\bin\aarch64-w64-mingw32-gcc.exe")) {throw "llvm-mingw x86_64 package is missing the aarch64 cross compiler"@@ -224,18 +225,10 @@ jobs:$ErrorActionPreference = "Stop"$ProgressPreference = 'SilentlyContinue'if ("${{ steps.cache-install.outputs.cache-hit }}" -ne 'true') {- for ($attempt = 1; $attempt -le 3; $attempt++) {- try {- Invoke-WebRequest -Uri "${{ matrix.install }}" -OutFile "install.exe"- break- } catch {- if ($attempt -eq 3) { throw }- Write-Host "CUDA installer download attempt $attempt failed: $($_.Exception.Message); retrying in 15s"- Start-Sleep -Seconds 15- }- }+ Invoke-WebRequest -Uri "${{ matrix.install }}" -OutFile "install.exe" -MaximumRetryCount 3 -RetryIntervalSec 2$subpackages = @(${{ join(matrix.cuda-components, ', ') }}) | Foreach-Object {"${_}_${{ matrix.cuda-version }}"}Start-Process -FilePath .\install.exe -ArgumentList (@("-s") + $subpackages) -NoNewWindow -Wait+ Remove-Item install.exe}$cudaPath = (Resolve-Path "C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\*").path@@ -245,8 +238,9 @@ jobs:run: |$ErrorActionPreference = "Stop"if ("${{ steps.cache-install.outputs.cache-hit }}" -ne 'true') {- Invoke-WebRequest -Uri "${{ matrix.install }}" -OutFile "install.exe"+ Invoke-WebRequest -Uri "${{ matrix.install }}" -OutFile "install.exe" -MaximumRetryCount 3 -RetryIntervalSec 2Start-Process -FilePath .\install.exe -ArgumentList '-install' -NoNewWindow -Wait+ Remove-Item install.exe}$hipPath = (Resolve-Path "C:\Program Files\AMD\ROCm\*").path@@ -261,8 +255,9 @@ jobs:run: |$ErrorActionPreference = "Stop"if ("${{ steps.cache-install.outputs.cache-hit }}" -ne 'true') {- Invoke-WebRequest -Uri "${{ matrix.install }}" -OutFile "install.exe"+ Invoke-WebRequest -Uri "${{ matrix.install }}" -OutFile "install.exe" -MaximumRetryCount 3 -RetryIntervalSec 2Start-Process -FilePath .\install.exe -ArgumentList "-c","--am","--al","in" -NoNewWindow -Wait+ Remove-Item install.exe}$vulkanPath = (Resolve-Path "C:\VulkanSDK\*").path@@ -278,11 +273,13 @@ jobs:$ErrorActionPreference = "Stop"$cudnnRoot = "C:\Program Files\NVIDIA\CUDNN"if ("${{ steps.cache-install.outputs.cache-hit }}" -ne 'true') {- Invoke-WebRequest -Uri "${{ matrix.cudnn-install }}" -OutFile "cudnn.zip"+ Invoke-WebRequest -Uri "${{ matrix.cudnn-install }}" -OutFile "cudnn.zip" -MaximumRetryCount 3 -RetryIntervalSec 2Expand-Archive -Path cudnn.zip -DestinationPath cudnn-extracted+ Remove-Item cudnn.zip$cudnnDir = (Get-ChildItem -Path cudnn-extracted -Directory)[0].FullNameNew-Item -ItemType Directory -Force -Path $cudnnRootCopy-Item -Path "$cudnnDir\*" -Destination "$cudnnRoot\" -Recurse+ Remove-Item cudnn-extracted -Recurse}echo "CUDNN_ROOT_DIR=$cudnnRoot" | Out-File -FilePath $env:GITHUB_ENV -Append@@ -344,8 +341,9 @@ jobs:run: |$ErrorActionPreference = "Stop"Set-ExecutionPolicy Bypass -Scope Process -Force- Invoke-WebRequest -Uri "https://github.com/mstorsjo/llvm-mingw/releases/download/20240619/llvm-mingw-20240619-ucrt-x86_64.zip" -OutFile "${{ runner.temp }}\llvm-mingw-ucrt.zip"+ Invoke-WebRequest -Uri "https://github.com/mstorsjo/llvm-mingw/releases/download/20240619/llvm-mingw-20240619-ucrt-x86_64.zip" -OutFile "${{ runner.temp }}\llvm-mingw-ucrt.zip" -MaximumRetryCount 3 -RetryIntervalSec 2Expand-Archive -Path ${{ runner.temp }}\llvm-mingw-ucrt.zip -DestinationPath "C:\Program Files\"+ Remove-Item "${{ runner.temp }}\llvm-mingw-ucrt.zip"$installPath=(Resolve-Path -Path "C:\Program Files\llvm-mingw-*-ucrt-x86_64").pathecho "$installPath\bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Appendif (!(Test-Path "$installPath\bin\aarch64-w64-mingw32-gcc.exe")) {@@ -412,11 +410,13 @@ jobs:credentials_json: ${{ secrets.GOOGLE_SIGNING_CREDENTIALS }}- run: |$ErrorActionPreference = "Stop"- Invoke-WebRequest -Uri "https://go.microsoft.com/fwlink/p/?LinkId=323507" -OutFile "${{ runner.temp }}\sdksetup.exe"+ Invoke-WebRequest -Uri "https://go.microsoft.com/fwlink/p/?LinkId=323507" -OutFile "${{ runner.temp }}\sdksetup.exe" -MaximumRetryCount 3 -RetryIntervalSec 2Start-Process "${{ runner.temp }}\sdksetup.exe" -ArgumentList @("/q") -NoNewWindow -Wait+ Remove-Item "${{ runner.temp }}\sdksetup.exe"- Invoke-WebRequest -Uri "https://github.com/GoogleCloudPlatform/kms-integrations/releases/download/cng-v1.0/kmscng-1.0-windows-amd64.zip" -OutFile "${{ runner.temp }}\plugin.zip"+ Invoke-WebRequest -Uri "https://github.com/GoogleCloudPlatform/kms-integrations/releases/download/cng-v1.0/kmscng-1.0-windows-amd64.zip" -OutFile "${{ runner.temp }}\plugin.zip" -MaximumRetryCount 3 -RetryIntervalSec 2Expand-Archive -Path "${{ runner.temp }}\plugin.zip" -DestinationPath "${{ runner.temp }}\plugin\"+ Remove-Item "${{ runner.temp }}\plugin.zip"& "${{ runner.temp }}\plugin\*\kmscng.msi" /quietecho "${{ vars.OLLAMA_CERT }}" >ollama_inc.crtdiff --git a/.github/workflows/test-llamacpp-update.yaml b/.github/workflows/test-llamacpp-update.yamlindex 6b6f73e05..542c766e2 100644--- a/.github/workflows/test-llamacpp-update.yaml+++ b/.github/workflows/test-llamacpp-update.yaml@@ -366,8 +366,9 @@ jobs:- if: matrix.preset == 'CPU'name: Install Windows ARM64 cross compilerrun: |- Invoke-WebRequest -Uri "https://github.com/mstorsjo/llvm-mingw/releases/download/20240619/llvm-mingw-20240619-ucrt-x86_64.zip" -OutFile "${{ runner.temp }}\llvm-mingw-ucrt.zip"+ Invoke-WebRequest -Uri "https://github.com/mstorsjo/llvm-mingw/releases/download/20240619/llvm-mingw-20240619-ucrt-x86_64.zip" -OutFile "${{ runner.temp }}\llvm-mingw-ucrt.zip" -MaximumRetryCount 3 -RetryIntervalSec 2Expand-Archive -Path ${{ runner.temp }}\llvm-mingw-ucrt.zip -DestinationPath "C:\Program Files\"+ Remove-Item "${{ runner.temp }}\llvm-mingw-ucrt.zip"$installPath=(Resolve-Path -Path "C:\Program Files\llvm-mingw-*-ucrt-x86_64").pathif (!(Test-Path "$installPath\bin\aarch64-w64-mingw32-gcc.exe")) {throw "llvm-mingw x86_64 package is missing the aarch64 cross compiler"@@ -387,18 +388,10 @@ jobs:$ErrorActionPreference = "Stop"$ProgressPreference = 'SilentlyContinue'if ("${{ steps.cache-install.outputs.cache-hit }}" -ne 'true') {- for ($attempt = 1; $attempt -le 3; $attempt++) {- try {- Invoke-WebRequest -Uri "${{ matrix.install }}" -OutFile "install.exe"- break- } catch {- if ($attempt -eq 3) { throw }- Write-Host "CUDA installer download attempt $attempt failed: $($_.Exception.Message); retrying in 15s"- Start-Sleep -Seconds 15- }- }+ Invoke-WebRequest -Uri "${{ matrix.install }}" -OutFile "install.exe" -MaximumRetryCount 3 -RetryIntervalSec 2$subpackages = @(${{ join(matrix.cuda-components, ', ') }}) | Foreach-Object {"${_}_${{ matrix.cuda-version }}"}Start-Process -FilePath .\install.exe -ArgumentList (@("-s") + $subpackages) -NoNewWindow -Wait+ Remove-Item install.exe}$cudaPath = (Resolve-Path "C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\*").path@@ -408,8 +401,9 @@ jobs:run: |$ErrorActionPreference = "Stop"if ("${{ steps.cache-install.outputs.cache-hit }}" -ne 'true') {- Invoke-WebRequest -Uri "${{ matrix.install }}" -OutFile "install.exe"+ Invoke-WebRequest -Uri "${{ matrix.install }}" -OutFile "install.exe" -MaximumRetryCount 3 -RetryIntervalSec 2Start-Process -FilePath .\install.exe -ArgumentList '-install' -NoNewWindow -Wait+ Remove-Item install.exe}$hipPath = (Resolve-Path "C:\Program Files\AMD\ROCm\*").path@@ -424,8 +418,9 @@ jobs:run: |$ErrorActionPreference = "Stop"if ("${{ steps.cache-install.outputs.cache-hit }}" -ne 'true') {- Invoke-WebRequest -Uri "${{ matrix.install }}" -OutFile "install.exe"+ Invoke-WebRequest -Uri "${{ matrix.install }}" -OutFile "install.exe" -MaximumRetryCount 3 -RetryIntervalSec 2Start-Process -FilePath .\install.exe -ArgumentList "-c","--am","--al","in" -NoNewWindow -Wait+ Remove-Item install.exe}$vulkanPath = (Resolve-Path "C:\VulkanSDK\*").path@@ -487,8 +482,9 @@ jobs:run: |$ErrorActionPreference = "Stop"Set-ExecutionPolicy Bypass -Scope Process -Force- Invoke-WebRequest -Uri "https://github.com/mstorsjo/llvm-mingw/releases/download/20240619/llvm-mingw-20240619-ucrt-x86_64.zip" -OutFile "${{ runner.temp }}\llvm-mingw-ucrt.zip"+ Invoke-WebRequest -Uri "https://github.com/mstorsjo/llvm-mingw/releases/download/20240619/llvm-mingw-20240619-ucrt-x86_64.zip" -OutFile "${{ runner.temp }}\llvm-mingw-ucrt.zip" -MaximumRetryCount 3 -RetryIntervalSec 2Expand-Archive -Path ${{ runner.temp }}\llvm-mingw-ucrt.zip -DestinationPath "C:\Program Files\"+ Remove-Item "${{ runner.temp }}\llvm-mingw-ucrt.zip"$installPath=(Resolve-Path -Path "C:\Program Files\llvm-mingw-*-ucrt-x86_64").pathecho "$installPath\bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Appendif (!(Test-Path "$installPath\bin\aarch64-w64-mingw32-gcc.exe")) {diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yamlindex f7ea8bf56..7404905a5 100644--- a/.github/workflows/test.yaml+++ b/.github/workflows/test.yaml@@ -130,15 +130,19 @@ jobs:$sudo apt-get update# Add LunarG Vulkan SDK apt repo for Ubuntu 22.04if [ "${{ matrix.preset }}" = "Vulkan" ]; then- $sudo apt-get install -y --no-install-recommends wget gnupg ca-certificates software-properties-common- wget -qO - https://packages.lunarg.com/lunarg-signing-key-pub.asc | $sudo gpg --dearmor -o /usr/share/keyrings/lunarg-archive-keyring.gpg+ $sudo apt-get install -y --no-install-recommends curl gnupg ca-certificates software-properties-common+ curl --retry 3 -fsSL https://packages.lunarg.com/lunarg-signing-key-pub.asc -o "$RUNNER_TEMP/lunarg.asc"+ $sudo gpg --dearmor -o /usr/share/keyrings/lunarg-archive-keyring.gpg "$RUNNER_TEMP/lunarg.asc"+ rm "$RUNNER_TEMP/lunarg.asc"# Use signed-by to bind the repo to the installed keyring to avoid NO_PUBKEYecho "deb [signed-by=/usr/share/keyrings/lunarg-archive-keyring.gpg] https://packages.lunarg.com/vulkan/1.4.313 jammy main" | $sudo tee /etc/apt/sources.list.d/lunarg-vulkan-1.4.313-jammy.list > /dev/null$sudo apt-get updatefi$sudo apt-get install -y cmake ccache curl git ${{ matrix.extra-packages }}# Use a current CMake for upstream llama.cpp and Vulkan dependency discovery.- curl -fsSL https://github.com/Kitware/CMake/releases/download/v3.31.2/cmake-3.31.2-linux-$(uname -m).tar.gz | $sudo tar xz -C /usr/local --strip-components 1+ curl --retry 3 -fsSL https://github.com/Kitware/CMake/releases/download/v3.31.2/cmake-3.31.2-linux-$(uname -m).tar.gz -o "$RUNNER_TEMP/cmake.tar.gz"+ $sudo tar xzf "$RUNNER_TEMP/cmake.tar.gz" -C /usr/local --strip-components 1+ rm "$RUNNER_TEMP/cmake.tar.gz"# Export VULKAN_SDK if provided by LunarG package (defensive)if [ -d "/usr/lib/x86_64-linux-gnu/vulkan" ] && [ "${{ matrix.preset }}" = "Vulkan" ]; thenecho "VULKAN_SDK=/usr" >> $GITHUB_ENV@@ -150,7 +154,9 @@ jobs:run: |[ -n "${{ matrix.container }}" ] || sudo=sudoGO_VERSION=$(awk '/^go / { print $2 }' go.mod)- curl -fsSL "https://golang.org/dl/go${GO_VERSION}.linux-$(dpkg --print-architecture).tar.gz" | $sudo tar xz -C /usr/local+ curl --retry 3 -fsSL "https://golang.org/dl/go${GO_VERSION}.linux-$(dpkg --print-architecture).tar.gz" -o "$RUNNER_TEMP/go.tar.gz"+ $sudo tar xzf "$RUNNER_TEMP/go.tar.gz" -C /usr/local+ rm "$RUNNER_TEMP/go.tar.gz"echo "/usr/local/go/bin" >> $GITHUB_PATH- uses: actions/cache@v4with:@@ -261,9 +267,10 @@ jobs:run: |$ErrorActionPreference = "Stop"if ("${{ steps.cache-install.outputs.cache-hit }}" -ne 'true') {- Invoke-WebRequest -Uri "${{ matrix.install }}" -OutFile "install.exe"+ Invoke-WebRequest -Uri "${{ matrix.install }}" -OutFile "install.exe" -MaximumRetryCount 3 -RetryIntervalSec 2$subpackages = @(${{ join(matrix.cuda-components, ', ') }}) | Foreach-Object {"${_}_${{ matrix.cuda-version }}"}Start-Process -FilePath .\install.exe -ArgumentList (@("-s") + $subpackages) -NoNewWindow -Wait+ Remove-Item install.exe}$cudaPath = (Resolve-Path "C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\*").path@@ -273,8 +280,9 @@ jobs:run: |$ErrorActionPreference = "Stop"if ("${{ steps.cache-install.outputs.cache-hit }}" -ne 'true') {- Invoke-WebRequest -Uri "${{ matrix.install }}" -OutFile "install.exe"+ Invoke-WebRequest -Uri "${{ matrix.install }}" -OutFile "install.exe" -MaximumRetryCount 3 -RetryIntervalSec 2Start-Process -FilePath .\install.exe -ArgumentList '-install' -NoNewWindow -Wait+ Remove-Item install.exe}$hipPath = (Resolve-Path "C:\Program Files\AMD\ROCm\*").path@@ -289,8 +297,9 @@ jobs:run: |$ErrorActionPreference = "Stop"if ("${{ steps.cache-install.outputs.cache-hit }}" -ne 'true') {- Invoke-WebRequest -Uri "${{ matrix.install }}" -OutFile "install.exe"+ Invoke-WebRequest -Uri "${{ matrix.install }}" -OutFile "install.exe" -MaximumRetryCount 3 -RetryIntervalSec 2Start-Process -FilePath .\install.exe -ArgumentList "-c","--am","--al","in" -NoNewWindow -Wait+ Remove-Item install.exe}$vulkanPath = (Resolve-Path "C:\VulkanSDK\*").path@@ -306,11 +315,13 @@ jobs:$ErrorActionPreference = "Stop"$cudnnRoot = "C:\Program Files\NVIDIA\CUDNN"if ("${{ steps.cache-install.outputs.cache-hit }}" -ne 'true') {- Invoke-WebRequest -Uri "${{ matrix.cudnn-install }}" -OutFile "cudnn.zip"+ Invoke-WebRequest -Uri "${{ matrix.cudnn-install }}" -OutFile "cudnn.zip" -MaximumRetryCount 3 -RetryIntervalSec 2Expand-Archive -Path cudnn.zip -DestinationPath cudnn-extracted+ Remove-Item cudnn.zip$cudnnDir = (Get-ChildItem -Path cudnn-extracted -Directory)[0].FullNameNew-Item -ItemType Directory -Force -Path $cudnnRootCopy-Item -Path "$cudnnDir\*" -Destination "$cudnnRoot\" -Recurse+ Remove-Item cudnn-extracted -Recurse}echo "CUDNN_ROOT_DIR=$cudnnRoot" | Out-File -FilePath $env:GITHUB_ENV -Appenddiff --git a/Dockerfile b/Dockerfileindex e68861205..32722808a 100644--- a/Dockerfile+++ b/Dockerfile@@ -29,9 +29,11 @@ ENV CC=clang CXX=clang++FROM base-${TARGETARCH} AS baseARG CMAKEVERSIONARG NINJAVERSION-RUN curl -fsSL https://github.com/Kitware/CMake/releases/download/v${CMAKEVERSION}/cmake-${CMAKEVERSION}-linux-$(uname -m).tar.gz | tar xz -C /usr/local --strip-components 1+RUN curl --retry 3 -fsSL https://github.com/Kitware/CMake/releases/download/v${CMAKEVERSION}/cmake-${CMAKEVERSION}-linux-$(uname -m).tar.gz -o /tmp/cmake.tar.gz \+ && tar xzf /tmp/cmake.tar.gz -C /usr/local --strip-components 1 \+ && rm /tmp/cmake.tar.gzRUN dnf install -y unzip \- && curl -fsSL -o /tmp/ninja.zip https://github.com/ninja-build/ninja/releases/download/v${NINJAVERSION}/ninja-linux$([ "$(uname -m)" = "aarch64" ] && echo "-aarch64").zip \+ && curl --retry 3 -fsSL -o /tmp/ninja.zip https://github.com/ninja-build/ninja/releases/download/v${NINJAVERSION}/ninja-linux$([ "$(uname -m)" = "aarch64" ] && echo "-aarch64").zip \&& unzip /tmp/ninja.zip -d /usr/local/bin \&& rm /tmp/ninja.zipENV CMAKE_GENERATOR=Ninja@@ -61,7 +63,7 @@ ENV PATH=/opt/rocm/llvm/bin:/opt/rocm/hcc/bin:/opt/rocm/hip/bin:/opt/rocm/bin:$PFROM base AS vulkan-depsARG VULKANVERSIONRUN ln -s /usr/bin/python3 /usr/bin/python \- && wget https://sdk.lunarg.com/sdk/download/${VULKANVERSION}/linux/vulkansdk-linux-x86_64-${VULKANVERSION}.tar.xz -O /tmp/vulkansdk.tar.xz \+ && curl --retry 3 -fsSL https://sdk.lunarg.com/sdk/download/${VULKANVERSION}/linux/vulkansdk-linux-x86_64-${VULKANVERSION}.tar.xz -o /tmp/vulkansdk.tar.xz \&& tar xvf /tmp/vulkansdk.tar.xz -C /tmp \&& /tmp/${VULKANVERSION}/vulkansdk -j 8 vulkan-headers \&& /tmp/${VULKANVERSION}/vulkansdk -j 8 spirv-headers \@@ -162,8 +164,10 @@ FROM --platform=linux/arm64 nvcr.io/nvidia/l4t-jetpack:${JETPACK5VERSION} AS jetARG CMAKEVERSIONARG NINJAVERSIONRUN apt-get update && apt-get install -y curl ccache git unzip \- && curl -fsSL https://github.com/Kitware/CMake/releases/download/v${CMAKEVERSION}/cmake-${CMAKEVERSION}-linux-$(uname -m).tar.gz | tar xz -C /usr/local --strip-components 1 \- && curl -fsSL -o /tmp/ninja.zip https://github.com/ninja-build/ninja/releases/download/v${NINJAVERSION}/ninja-linux-aarch64.zip \+ && curl --retry 3 -fsSL https://github.com/Kitware/CMake/releases/download/v${CMAKEVERSION}/cmake-${CMAKEVERSION}-linux-$(uname -m).tar.gz -o /tmp/cmake.tar.gz \+ && tar xzf /tmp/cmake.tar.gz -C /usr/local --strip-components 1 \+ && rm /tmp/cmake.tar.gz \+ && curl --retry 3 -fsSL -o /tmp/ninja.zip https://github.com/ninja-build/ninja/releases/download/v${NINJAVERSION}/ninja-linux-aarch64.zip \&& unzip /tmp/ninja.zip -d /usr/local/bin \&& rm /tmp/ninja.zipENV CMAKE_GENERATOR=Ninja@@ -183,8 +187,10 @@ FROM --platform=linux/arm64 nvcr.io/nvidia/l4t-jetpack:${JETPACK6VERSION} AS jetARG CMAKEVERSIONARG NINJAVERSIONRUN apt-get update && apt-get install -y curl ccache git unzip \- && curl -fsSL https://github.com/Kitware/CMake/releases/download/v${CMAKEVERSION}/cmake-${CMAKEVERSION}-linux-$(uname -m).tar.gz | tar xz -C /usr/local --strip-components 1 \- && curl -fsSL -o /tmp/ninja.zip https://github.com/ninja-build/ninja/releases/download/v${NINJAVERSION}/ninja-linux-aarch64.zip \+ && curl --retry 3 -fsSL https://github.com/Kitware/CMake/releases/download/v${CMAKEVERSION}/cmake-${CMAKEVERSION}-linux-$(uname -m).tar.gz -o /tmp/cmake.tar.gz \+ && tar xzf /tmp/cmake.tar.gz -C /usr/local --strip-components 1 \+ && rm /tmp/cmake.tar.gz \+ && curl --retry 3 -fsSL -o /tmp/ninja.zip https://github.com/ninja-build/ninja/releases/download/v${NINJAVERSION}/ninja-linux-aarch64.zip \&& unzip /tmp/ninja.zip -d /usr/local/bin \&& rm /tmp/ninja.zipENV CMAKE_GENERATOR=Ninja@@ -224,7 +230,9 @@ COPY mlx mlxCOPY mlxrunner/xgrammar/native mlxrunner/xgrammar/nativeCOPY go.mod go.sum .COPY MLX_VERSION MLX_C_VERSION .-RUN curl -fsSL https://golang.org/dl/go$(awk '/^go/ { print $2 }' go.mod).linux-$(case $(uname -m) in x86_64) echo amd64 ;; aarch64) echo arm64 ;; esac).tar.gz | tar xz -C /usr/local+RUN curl --retry 3 -fsSL https://golang.org/dl/go$(awk '/^go/ { print $2 }' go.mod).linux-$(case $(uname -m) in x86_64) echo amd64 ;; aarch64) echo arm64 ;; esac).tar.gz -o /tmp/go.tar.gz \+ && tar xzf /tmp/go.tar.gz -C /usr/local \+ && rm /tmp/go.tar.gzENV PATH=/usr/local/go/bin:$PATHRUN go mod downloadRUN --mount=type=cache,target=/root/.ccache \@@ -249,7 +257,9 @@ COPY --from=mlx /go/src/github.com/ollama/ollama/dist/lib/ollama /lib/ollama/FROM base AS buildWORKDIR /go/src/github.com/ollama/ollamaCOPY go.mod go.sum .-RUN curl -fsSL https://golang.org/dl/go$(awk '/^go/ { print $2 }' go.mod).linux-$(case $(uname -m) in x86_64) echo amd64 ;; aarch64) echo arm64 ;; esac).tar.gz | tar xz -C /usr/local+RUN curl --retry 3 -fsSL https://golang.org/dl/go$(awk '/^go/ { print $2 }' go.mod).linux-$(case $(uname -m) in x86_64) echo amd64 ;; aarch64) echo arm64 ;; esac).tar.gz -o /tmp/go.tar.gz \+ && tar xzf /tmp/go.tar.gz -C /usr/local \+ && rm /tmp/go.tar.gzENV PATH=/usr/local/go/bin:$PATHRUN go mod downloadCOPY . .