diff --git a/images/Dockerfile.bottlecap.alpine.compile b/images/Dockerfile.bottlecap.alpine.compile index 9858c5662..a460e3406 100644 --- a/images/Dockerfile.bottlecap.alpine.compile +++ b/images/Dockerfile.bottlecap.alpine.compile @@ -17,8 +17,7 @@ RUN set -euo pipefail && \ curl https://sh.rustup.rs -sSf | \ sh -s -- --profile minimal \ --default-host "${PLATFORM}-unknown-linux-musl" \ - --default-toolchain "stable-${PLATFORM}-unknown-linux-musl" \ - --component rust-src \ + --default-toolchain none \ -y ENV PATH="${PATH}:/root/.cargo/bin" @@ -47,7 +46,7 @@ RUN --mount=type=cache,target=/root/.cargo/git \ # -Ctarget-feature=-crt-static so that it is capable of dynamically loading # libclang; while still building bottlecap with a static CRT. RUSTC_WRAPPER=/tmp/dd/.cargo/musl.rustc-wrapper \ - cargo +stable build --verbose --locked --no-default-features \ + cargo build --verbose --locked --no-default-features \ --features="${FEATURES}" \ --profile="${PROFILE:-release}" && \ mkdir -p /tmp/out && \ diff --git a/images/Dockerfile.bottlecap.compile b/images/Dockerfile.bottlecap.compile index 12a23f64b..1e021aeb4 100644 --- a/images/Dockerfile.bottlecap.compile +++ b/images/Dockerfile.bottlecap.compile @@ -16,8 +16,7 @@ RUN chmod +x /install-protoc.sh && /install-protoc.sh RUN curl https://sh.rustup.rs -sSf | \ sh -s -- --profile minimal \ --default-host "${PLATFORM}-unknown-linux-gnu" \ - --default-toolchain "stable-${PLATFORM}-unknown-linux-gnu" \ - --component rust-src \ + --default-toolchain none \ -y ENV PATH="${PATH}:/root/.cargo/bin" @@ -46,7 +45,7 @@ RUN --mount=type=cache,target=/usr/local/cargo/git \ # The `libddwaf` crate links against static objects that require `libclang_rt.builtins`, but # this is not presented to the linker by default on this platform, so we force it in. export RUSTFLAGS="${RUSTFLAGS:-} -Clinker=clang -L$(dirname $(clang --print-file-name="libclang_rt.builtins-$(uname -m).a")) -lclang_rt.builtins-$(uname -m)"; \ - cargo +stable build --verbose --locked --no-default-features --features="${FEATURES}" ${BUILD_FLAG} && \ + cargo build --verbose --locked --no-default-features --features="${FEATURES}" ${BUILD_FLAG} && \ mkdir -p /tmp/out && cp "/tmp/dd/bottlecap/target/${BUILD_MODE}/bottlecap" /tmp/out/bottlecap # Use smallest image possible diff --git a/images/Dockerfile.build_layer b/images/Dockerfile.build_layer index c931f7ddf..e08e6616d 100644 --- a/images/Dockerfile.build_layer +++ b/images/Dockerfile.build_layer @@ -5,19 +5,6 @@ ARG FILE_SUFFIX # Install dependencies RUN apt-get update && apt-get install -y zip binutils wget tar xz-utils -# UPX installation directly from GitHub -ENV UPX_VERSION=5.0.0 -RUN ARCH=$(uname -m) && \ - if [ "$ARCH" = "x86_64" ]; then \ - ARCH_NAME="amd64"; \ - elif [ "$ARCH" = "aarch64" ]; then \ - ARCH_NAME="arm64"; \ - fi && \ - wget https://github.com/upx/upx/releases/download/v${UPX_VERSION}/upx-${UPX_VERSION}-${ARCH_NAME}_linux.tar.xz && \ - tar -xf upx-${UPX_VERSION}-${ARCH_NAME}_linux.tar.xz && \ - mv upx-${UPX_VERSION}-${ARCH_NAME}_linux/upx /usr/local/bin/ && \ - rm -rf upx-${UPX_VERSION}-${ARCH_NAME}_linux upx-${UPX_VERSION}-${ARCH_NAME}_linux.tar.xz - RUN mkdir /extensions WORKDIR /extensions