Skip to content

Commit bcd13d3

Browse files
authored
Merge pull request #36 from AdaWorldAPI/claude/continue-session-0mAVa
fix(ci): require Rust 1.94.0 in Dockerfile via rustup
2 parents cf8e702 + 1d5657d commit bcd13d3

1 file changed

Lines changed: 15 additions & 6 deletions

File tree

Dockerfile

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,27 @@
11
# ndarray — Railway compile-test image
22
# Verifies the HPC module builds cleanly (default + jit-native features)
3+
# Requires Rust 1.94.0 (LazyLock, simd_caps, modern std APIs)
34
#
45
# Build: docker build -t ndarray-test .
56
# Run: docker run --rm ndarray-test
67

7-
FROM rust:1.85-slim AS builder
8+
FROM debian:bookworm-slim AS builder
89

9-
WORKDIR /app
10-
11-
# System deps for Cranelift JIT
10+
# System deps
1211
RUN apt-get update && apt-get install -y --no-install-recommends \
13-
pkg-config libssl-dev \
12+
curl ca-certificates gcc libc6-dev pkg-config libssl-dev \
1413
&& rm -rf /var/lib/apt/lists/*
1514

15+
# Install Rust 1.94.0 via rustup
16+
ENV RUSTUP_HOME=/usr/local/rustup \
17+
CARGO_HOME=/usr/local/cargo \
18+
PATH=/usr/local/cargo/bin:$PATH
19+
RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | \
20+
sh -s -- -y --default-toolchain 1.94.0 --profile minimal \
21+
&& rustc --version | grep -q "1.94.0"
22+
23+
WORKDIR /app
24+
1625
# Copy workspace files first for layer caching
1726
COPY Cargo.toml Cargo.lock ./
1827
COPY ndarray-rand/Cargo.toml ndarray-rand/Cargo.toml
@@ -34,4 +43,4 @@ RUN cargo test --release --lib -- hpc:: 2>&1 && echo "=== HPC TESTS OK ==="
3443
# Minimal runtime image — just proves it compiled
3544
FROM debian:bookworm-slim
3645
COPY --from=builder /app/target/release/libndarray.rlib /usr/local/lib/
37-
CMD ["echo", "ndarray build verified"]
46+
CMD ["echo", "ndarray build verified — Rust 1.94.0"]

0 commit comments

Comments
 (0)