Skip to content

Commit

Permalink
try it on CI
Browse files Browse the repository at this point in the history
  • Loading branch information
fbielejec committed Nov 29, 2024
1 parent 2c1ee64 commit 317b42e
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
2 changes: 1 addition & 1 deletion crates/shielder-relayer/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ lint: ## Run linter

.PHONY: build-image
build-image: ## Builds a Docker image with the Relayer service binary
@cd ../.. && docker build --ssh default --tag "${RELAYER_DOCKER_IMAGE}" -f "crates/shielder-relayer/$(DOCKERFILE_PATH)" .
@cd ../.. && DOCKER_BUILDKIT=1 docker build --ssh default --tag "${RELAYER_DOCKER_IMAGE}" -f "crates/shielder-relayer/$(DOCKERFILE_PATH)" .

.PHONY: run
run: build-image stop ## Start the Relayer service in a local Docker container
Expand Down
11 changes: 9 additions & 2 deletions crates/shielder-relayer/docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# syntax=docker/dockerfile:experimental

FROM debian:bookworm-slim AS build

RUN apt-get update && \
Expand All @@ -18,8 +20,13 @@ COPY ./Cargo.toml ./zkos/Cargo.toml
COPY ./Cargo.lock ./zkos/Cargo.lock
COPY ./rust-toolchain.toml ./zkos/rust-toolchain.toml

RUN cd zkos && cargo build --release -p shielder-relayer \
--config "patch.'ssh://git@github.com/Cardinal-Cryptography/poseidon-gadget'.halo2_poseidon.git='https://github.com/privacy-scaling-explorations/poseidon-gadget'"
# download public key for github.com
RUN mkdir -p -m 0600 ~/.ssh && ssh-keyscan github.com >> ~/.ssh/known_hosts

# RUN cd zkos && cargo build --release -p shielder-relayer \
# --config "patch.'ssh://git@github.com/Cardinal-Cryptography/poseidon-gadget'.halo2_poseidon.git='https://github.com/privacy-scaling-explorations/poseidon-gadget'"

RUN --mount=type=ssh cd zkos && cargo build --release -p shielder-relayer

FROM debian:bookworm-slim

Expand Down

0 comments on commit 317b42e

Please sign in to comment.