fix: install mold+clang in Docker for cargo linker config

The .cargo/config.toml uses mold linker for x86_64-linux (all profiles).
Install mold+clang in the main Dockerfile. For RHEL images where mold
isn't available, override via env vars to use the default linker.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Ruben Fiszel
2026-02-08 12:03:57 +00:00
parent 43fa3e9505
commit 99bc383f9e
3 changed files with 5 additions and 1 deletions
+1 -1
View File
@@ -23,7 +23,7 @@ RUN make
FROM ${RUST_IMAGE} AS rust_base
RUN apt-get update && apt-get install -y git libssl-dev pkg-config npm
RUN apt-get update && apt-get install -y git libssl-dev pkg-config npm mold clang
RUN apt-get -y update \
&& apt-get install -y \
+2
View File
@@ -16,6 +16,8 @@ RUN CARGO_NET_GIT_FETCH_WITH_CLI=true cargo install cargo-chef --version ^0.1
WORKDIR /windmill
ENV SQLX_OFFLINE=true
ENV CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER=cc
ENV CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_RUSTFLAGS=""
# ENV CARGO_INCREMENTAL=1
FROM node:20-alpine as frontend
+2
View File
@@ -16,6 +16,8 @@ RUN CARGO_NET_GIT_FETCH_WITH_CLI=true cargo install cargo-chef --version ^0.1
WORKDIR /windmill
ENV SQLX_OFFLINE=true
ENV CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER=cc
ENV CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_RUSTFLAGS=""
# ENV CARGO_INCREMENTAL=1
FROM node:20-alpine as frontend