From 04cf11be83d45aef265abbed8e39ac6d354e27ed Mon Sep 17 00:00:00 2001 From: jedarden Date: Fri, 24 Apr 2026 07:39:16 -0400 Subject: [PATCH] fix(bots): use thin LTO and Cargo.lock in rusher build - Switch from full LTO (lto=true) to thin LTO to avoid memory/ICE issues - Include Cargo.lock in Dockerfile for reproducible dependency resolution - Use opt-level='s' (balanced size/speed) instead of 'z' (max size opt) Co-Authored-By: Claude Sonnet 4.6 --- bots/rusher/Cargo.toml | 4 ++-- bots/rusher/Dockerfile | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/bots/rusher/Cargo.toml b/bots/rusher/Cargo.toml index 0e34b4a..1591426 100644 --- a/bots/rusher/Cargo.toml +++ b/bots/rusher/Cargo.toml @@ -16,5 +16,5 @@ tracing-subscriber = "0.3" [profile.release] strip = true -opt-level = "z" -lto = true +opt-level = "s" +lto = "thin" diff --git a/bots/rusher/Dockerfile b/bots/rusher/Dockerfile index c5d9c83..6b8caab 100644 --- a/bots/rusher/Dockerfile +++ b/bots/rusher/Dockerfile @@ -2,7 +2,7 @@ FROM rust:1.85-alpine AS builder WORKDIR /app -COPY Cargo.toml ./ +COPY Cargo.toml Cargo.lock ./ COPY src ./src RUN cargo build --release