Skip to content

Commit

Permalink
ci: pin zkLLVM 0.0.58 and toolchain 0.0.31
Browse files Browse the repository at this point in the history
zkLLVM and Proof Market toolchain are based on a few common libraries,
which should be updated simultaneously in both tools.

Now CI and ci.sh script will use explicitly pinned versions of both tools
to show how to use them together.

Resolve #30
  • Loading branch information
NickVolynkin committed Jun 26, 2023
1 parent e8aa67e commit 45b35aa
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 5 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@ concurrency:
format('{0}/{1}', github.workflow, github.ref) }}
cancel-in-progress: true

env:
ZKLLVM_VERSION: 0.0.58
TOOLCHAIN_VERSION: 0.0.31

jobs:
test-zkllvm-workflow:
runs-on: ubuntu-22.04
Expand Down
4 changes: 3 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,14 +1,16 @@
# build to ghcr.io/nilfoundation/zkllvm-template:latest
FROM ghcr.io/nilfoundation/build-base:1.76.0

ARG ZKLLVM_VERSION=0.0.58

RUN DEBIAN_FRONTEND=noninteractive \
echo 'deb [trusted=yes] http://deb.nil.foundation/ubuntu/ all main' >> /etc/apt/sources.list \
&& apt-get update \
&& apt-get -y --no-install-recommends --no-install-suggests install \
build-essential \
cmake \
git \
zkllvm \
zkllvm=${ZKLLVM_VERSION} \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*

Expand Down
8 changes: 4 additions & 4 deletions scripts/ci.sh
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ compile() {
--platform=linux/amd64 \
--user $(id -u ${USER}):$(id -g ${USER}) \
--volume $(pwd):/opt/zkllvm-template \
ghcr.io/nilfoundation/zkllvm-template:latest \
ghcr.io/nilfoundation/zkllvm-template:${ZKLLVM_VERSION} \
sh -c "bash ./scripts/ci.sh compile"
cd -
else
Expand All @@ -62,7 +62,7 @@ run_assigner() {
--platform=linux/amd64 \
--user $(id -u ${USER}):$(id -g ${USER}) \
--volume $(pwd):/opt/zkllvm-template \
ghcr.io/nilfoundation/zkllvm-template:latest \
ghcr.io/nilfoundation/zkllvm-template:${ZKLLVM_VERSION} \
sh -c "bash ./scripts/ci.sh run_assigner"
cd -
else
Expand Down Expand Up @@ -90,7 +90,7 @@ build_statement() {
--platform=linux/amd64 \
--user $(id -u ${USER}):$(id -g ${USER}) \
--volume $(pwd):/opt/zkllvm-template \
ghcr.io/nilfoundation/proof-market-toolchain:latest \
ghcr.io/nilfoundation/proof-market-toolchain:${TOOLCHAIN_VERSION} \
sh -c "bash /opt/zkllvm-template/scripts/ci.sh build_statement"
cd -
else
Expand Down Expand Up @@ -121,7 +121,7 @@ prove() {
--volume $(pwd):/opt/zkllvm-template \
--volume $(pwd)/.config:/root/.config \
--volume $(pwd)/.config:/proof-market-toolchain/.config \
ghcr.io/nilfoundation/proof-market-toolchain:latest \
ghcr.io/nilfoundation/proof-market-toolchain:${TOOLCHAIN_VERSION} \
sh -c "bash /opt/zkllvm-template/scripts/ci.sh prove"
cd -
else
Expand Down

0 comments on commit 45b35aa

Please sign in to comment.