From cea6cd882e97f16f18fe70e491f603a8d5223982 Mon Sep 17 00:00:00 2001 From: Wildan M Date: Fri, 12 Dec 2025 16:32:14 +0700 Subject: [PATCH] Skip binstall and directly download binaries --- podman/rustinstall.sh | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/podman/rustinstall.sh b/podman/rustinstall.sh index d4ae427a..31bd594c 100755 --- a/podman/rustinstall.sh +++ b/podman/rustinstall.sh @@ -3,9 +3,19 @@ # This script install the Rust toolchain and the build system dependencies # in Podman after the image has been built +echo Installing rust... curl https://sh.rustup.rs -sSf | sh -s -- -y --default-toolchain stable --profile minimal -curl -sSLf https://raw.githubusercontent.com/cargo-bins/cargo-binstall/main/install-from-binstall-release.sh | bash -cargo +stable binstall --no-confirm --force --version 0.10.0 sccache -cargo +stable binstall --no-confirm --force --version 1.42.4 just -cargo +stable binstall --no-confirm --force --version 0.29.0 cbindgen +echo Downloading sccache... +SCCACHE_URL=https://github.com/mozilla/sccache/releases/download/v0.10.0/sccache-v0.10.0-$(uname -m)-unknown-linux-musl.tar.gz +wget -qO- --show-progress $SCCACHE_URL | tar -xz -C ~/.cargo/bin --strip-components=1 --wildcards '*/sccache' + +echo Downloading just... +JUST_URL=https://github.com/casey/just/releases/download/1.45.0/just-1.45.0-$(uname -m)-unknown-linux-musl.tar.gz +wget -qO- --show-progress $JUST_URL | tar -xz -C ~/.cargo/bin --wildcards 'just' + +echo Downloading cbindgen... +CBINDGEN_NAME=$( [[ $(uname -m) = "x86_64" ]] && echo "ubuntu22.04" || echo "ubuntu22.04-aarch64" ) +CBINDGEN_URL=https://github.com/mozilla/cbindgen/releases/download/0.29.0/cbindgen-$CBINDGEN_NAME +wget -qO- --show-progress $CBINDGEN_URL > ~/.cargo/bin/cbindgen +chmod +x ~/.cargo/bin/cbindgen