-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
36 lines (25 loc) · 1.02 KB
/
Dockerfile
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
28
29
30
31
32
33
34
35
36
# Note: This is currently designed to simplify development
# To get a smaller docker image, there should be 2 images generated, in 2 stages.
FROM rustlang/rust:nightly
ARG PROFILE=release
WORKDIR /frontier
# Upcd dates core parts
RUN apt-get update -y && \
apt-get install -y cmake pkg-config libssl-dev git gcc build-essential clang libclang-dev
# Install rust wasm. Needed for substrate wasm engine
RUN rustup target add wasm32-unknown-unknown
# Download Frontier repo
RUN git clone https://github.com/paritytech/frontier /frontier
RUN cd /frontier && git submodule init && git submodule update
# Download rust dependencies and build the rust binary
RUN cargo build "--$PROFILE"
# 30333 for p2p traffic
# 9933 for RPC call
# 9944 for Websocket
# 9615 for Prometheus (metrics)
EXPOSE 30333 9933 9944 9615
ENV PROFILE ${PROFILE}
# The execution will re-compile the project to run it
# This allows to modify the code and not have to re-compile the
# dependencies.
CMD cargo run --bin frontier-template-node "--$PROFILE" -- --dev