diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..8c42416 --- /dev/null +++ b/.dockerignore @@ -0,0 +1,16 @@ +Dockerfile +.git +.dockerignore +**/node_modules +**/target +**/phase1radix2m* +/phase2/pkg +/phase2/*.params +/phase2/*.json +/phase2/*.bin +/phase2/*.circom +/phase2/verifier.sol +/powersoftau/challenge* +/powersoftau/response* +/powersoftau/transcript +/powersoftau/tmp_* \ No newline at end of file diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..33c79a5 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,16 @@ +FROM rust:slim as builder +RUN apt-get update && \ + apt-get install -y pkg-config libssl-dev && \ + rm -rf /var/lib/apt/lists/* +WORKDIR /build +COPY . . +RUN mkdir bin +RUN cd powersoftau && \ + cargo build --release --bins && \ + find ./target/release/ -maxdepth 1 -type f -perm /a+x -exec sh -c 'mv {} /build/bin/phase1_$(basename {})' \; +RUN cd phase2 && \ + cargo build --release --bins && \ + find ./target/release/ -maxdepth 1 -type f -perm /a+x -exec sh -c 'mv {} /build/bin/phase2_$(basename {})' \; + +FROM debian:buster-slim +COPY --from=builder /build/bin/* /usr/bin/ \ No newline at end of file diff --git a/README.md b/README.md index e69de29..ea32f8e 100644 --- a/README.md +++ b/README.md @@ -0,0 +1 @@ +# Trusted setup ceremony [![Docker Cloud Build Status](https://img.shields.io/docker/cloud/build/tornadocash/phase2-bn254.svg)](https://hub.docker.com/r/tornadocash/phase2-bn254/builds) \ No newline at end of file