diff --git a/Dockerfile b/Dockerfile index c0342dd2..f52438ef 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,13 +1,14 @@ # BUILD IMAGE --------------------------------------------------------- -FROM rust:1.80.0-slim-bullseye AS builder +FROM rust:1.80.0-slim-bookworm AS builder WORKDIR /nomos COPY . . # Install dependencies needed for building RocksDB. RUN apt-get update && apt-get install -yq \ - git clang libssl-dev pkg-config protobuf-compiler + git gcc g++ clang libssl-dev pkg-config \ + protobuf-compiler RUN cargo install cargo-binstall RUN cargo binstall -y cargo-risczero diff --git a/ci/Dockerfile b/ci/Dockerfile index e39b9093..f19e5c15 100644 --- a/ci/Dockerfile +++ b/ci/Dockerfile @@ -1,4 +1,4 @@ -FROM rust:1.80.0-slim-bullseye +FROM rust:1.80.0-slim-bookworm LABEL maintainer="augustinas@status.im" \ source="https://github.com/logos-co/nomos-node" \ @@ -6,16 +6,23 @@ LABEL maintainer="augustinas@status.im" \ # Dependecies for publishing documentation. RUN apt-get update && apt-get install -yq \ - libssl-dev openssh-client git python3-pip clang \ - pkg-config protobuf-compiler + libssl-dev openssh-client git gcc g++ \ + clang pkg-config protobuf-compiler -RUN pip install ghp-import RUN rustup component add rustfmt clippy +# Jenkins user needs a specific UID/GID to work. +RUN groupadd -g 1001 jenkins \ + && useradd -u 1001 -g jenkins jenkins + +# Create necessary directories and assign correct permissions +RUN mkdir -p /home/jenkins/.local/share/cargo-risczero/toolchains \ + && chown -R jenkins:jenkins /home/jenkins/.local \ + && mkdir -p /home/jenkins/.cargo \ + && chown -R jenkins:jenkins /home/jenkins/.cargo + +USER jenkins + RUN cargo install cargo-binstall RUN cargo binstall -y cargo-risczero RUN cargo risczero install - -# Jenkins user needs a specific UID/GID to work. -RUN groupadd -g 1001 jenkins \ - && useradd -u 1001 -g jenkins jenkins diff --git a/ci/Jenkinsfile.nightly.integration b/ci/Jenkinsfile.nightly.integration index 82ea7430..1e355926 100644 --- a/ci/Jenkinsfile.nightly.integration +++ b/ci/Jenkinsfile.nightly.integration @@ -18,10 +18,11 @@ pipeline { } environment { - /* Avoid cache poisoning by other jobs. */ - GOCACHE = "${env.WORKSPACE_TMP}/go-build" - GOPATH = "${env.WORKSPACE_TMP}/go" RUST_BACKTRACE = 1 + /* Use increased slot time in Nomos consensus */ + CONSENSUS_SLOT_TIME = 5 + /* Run Nomos tests in risc0 development mode */ + RISC0_DEV_MODE = true } options { diff --git a/testnet/Dockerfile b/testnet/Dockerfile index c245aa62..bb408c8c 100644 --- a/testnet/Dockerfile +++ b/testnet/Dockerfile @@ -1,13 +1,14 @@ # BUILD IMAGE --------------------------------------------------------- -FROM rust:1.80.0-slim-bullseye AS builder +FROM rust:1.80.0-slim-bookworm AS builder WORKDIR /nomos COPY . . # Install dependencies needed for building RocksDB and etcd. RUN apt-get update && apt-get install -yq \ - git clang etcd-client libssl-dev pkg-config protobuf-compiler + git gcc g++ clang etcd-client libssl-dev \ + pkg-config protobuf-compiler RUN cargo install cargo-binstall RUN cargo binstall -y cargo-risczero