This repository was archived by the owner on Jul 14, 2025. It is now read-only.
forked from paritytech/substrate-contracts-node
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
40 lines (30 loc) · 1.25 KB
/
Dockerfile
File metadata and controls
40 lines (30 loc) · 1.25 KB
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
37
38
39
40
FROM paritytech/ci-linux:production
LABEL AUTHORS="RAGI"
LABEL VERSION="2022-11-12"
WORKDIR /
ARG WORKING_DIR=/var/www/node-template
ARG CONTAINER_NAME=contracts-node-template-cactus
ARG PORT=9944
ARG DOCKER_PORT=9944
ARG CARGO_HOME=/var/www/node-template/.cargo
ENV CARGO_HOME=${CARGO_HOME}
ENV CACTUS_CFG_PATH=/etc/hyperledger/cactus
VOLUME .:/var/www/node-template
RUN apt update
# Get ubuntu and rust packages
RUN apt install -y build-essential pkg-config git clang curl make libssl-dev llvm libudev-dev
ENV CACTUS_CFG_PATH=/etc/hyperledger/cactus
RUN mkdir -p $CACTUS_CFG_PATH
RUN set -e
RUN echo "*** Instaling Rust environment ***"
RUN curl https://sh.rustup.rs -y -sSf | sh
RUN echo 'source $HOME/.cargo/env' >> $HOME/.bashrc
RUN rustup default nightly
RUN echo "*** Initializing WASM build environment"
RUN rustup target add wasm32-unknown-unknown --toolchain nightly
RUN echo "*** Installing Substrate node environment ***"
RUN git clone https://github.com/ragi96/substrate-contracts-node.git
RUN cd substrate-contracts-node && echo $(ls -1) && echo $(pwd) && cargo build --release
RUN
RUN echo "*** Start Substrate node template ***"
CMD [ "/substrate-contracts-node/target/release/substrate-contracts-node", "--dev", "--unsafe-ws-external", "--rpc-cors=all"]