-
Notifications
You must be signed in to change notification settings - Fork 3
/
Dockerfile.tests
28 lines (24 loc) · 1.14 KB
/
Dockerfile.tests
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# ===== FIRST STAGE ======
ARG DDC_SMART_CONTRACT_VERSION=2.2.3
ARG ECR_REGISTRY
FROM phusion/baseimage:0.11 as builder
LABEL maintainer="[email protected]"
LABEL description="This is the build stage to create the binary."
WORKDIR /cerenetwork
COPY . /cerenetwork
# ===== SECOND STAGE ======
RUN apt-get update && \
apt-get upgrade -y && \
apt-get install -y cmake pkg-config libssl-dev git clang unzip
# Installation script is taken from https://grpc.io/docs/protoc-installation/
ENV PROTOC_VERSION=3.15.8
RUN PB_REL="https://github.com/protocolbuffers/protobuf/releases" && \
curl -LO $PB_REL/download/v${PROTOC_VERSION}/protoc-${PROTOC_VERSION}-linux-x86_64.zip && \
mkdir -p /usr/local/protoc && \
unzip protoc-${PROTOC_VERSION}-linux-x86_64.zip -d /usr/local/protoc && \
chmod +x /usr/local/protoc/bin/protoc && \
ln -s /usr/local/protoc/bin/protoc /usr/local/bin
RUN curl https://sh.rustup.rs -sSf | sh -s -- -y && \
export PATH=$PATH:$HOME/.cargo/bin && \
scripts/init.sh && \
TRYBUILD=overwrite cargo test --workspace --locked --release --verbose --features runtime-benchmarks --manifest-path node/cli/Cargo.toml