FROM rust:1.88.0-bookworm ENV CARGO_TERM_COLOR=never ENV RUST_BACKTRACE=1 RUN apt-get update \ && apt-get install --no-install-recommends -y \ libpam0g-dev libpam-modules xauth xvfb pkg-config \ && rm -rf /var/lib/apt/lists/* WORKDIR /workspace COPY Cargo.toml Cargo.lock rust-toolchain.toml ./ COPY build.rs ./ COPY rust ./rust COPY crates ./crates COPY scripts ./scripts RUN cargo fmt --all -- --check \ && cargo test --locked --workspace --all-targets \ && cargo clippy --locked --workspace --all-targets --all-features -- -D warnings \ && RUSTDOCFLAGS="-D warnings" cargo doc --locked --workspace --no-deps \ && cargo build --locked --release \ && ./scripts/test-cli.sh target/release/latchd \ && ./scripts/test-system-e2e.sh target/release/latchd