Summary
When running workflows with --enable-chroot mode, binary execution is being intercepted in a way that causes failures for Rust, Java, and Bun runtimes. The symptoms vary but appear to share a common root cause.
Symptoms
Rust
cargo test fails with linker error:
lld-wrapper: executable has unexpected name: Some("bash")
collect2: error: ld returned 1 exit status
cargo build succeeds, but test compilation fails
Java
- All Java/Maven commands return bash help instead of executing:
BUILD_ENV_FAILURE: Java and Maven commands are intercepted by bash and return bash help instead of executing
java -version, mvn compile, etc. all output bash version info
Bun
bun install fails with:
error: An internal error occurred (NotDir)
Working Runtimes
The following runtimes work correctly in chroot mode:
- Node.js - All tests pass
- Go - All tests pass
- C++ - All builds pass
- Deno - All tests pass
Root Cause Analysis
The common pattern in all failing cases is that something in the chroot environment is intercepting binary execution and involving "bash" in unexpected ways:
- Rust sees the linker wrapper expecting a specific executable but finding "bash"
- Java commands return bash help/version output
- Bun has internal errors related to file system operations
Reproduction
- Run the "Build Test Rust", "Build Test Java", or "Build Test Bun" workflows on any PR
- Check the agent logs for the errors described above
Relevant Files
containers/agent/entrypoint.sh - Sets up the chroot environment
containers/agent/setup-iptables.sh - Configures iptables NAT rules
src/docker-manager.ts - Generates the docker-compose configuration
Related PRs
🤖 Created with Claude Code
Summary
When running workflows with
--enable-chrootmode, binary execution is being intercepted in a way that causes failures for Rust, Java, and Bun runtimes. The symptoms vary but appear to share a common root cause.Symptoms
Rust
cargo testfails with linker error:cargo buildsucceeds, but test compilation failsJava
java -version,mvn compile, etc. all output bash version infoBun
bun installfails with:Working Runtimes
The following runtimes work correctly in chroot mode:
Root Cause Analysis
The common pattern in all failing cases is that something in the chroot environment is intercepting binary execution and involving "bash" in unexpected ways:
Reproduction
Relevant Files
containers/agent/entrypoint.sh- Sets up the chroot environmentcontainers/agent/setup-iptables.sh- Configures iptables NAT rulessrc/docker-manager.ts- Generates the docker-compose configurationRelated PRs
🤖 Created with Claude Code