Development environment for building smart contracts.
-
Install Docker.
-
Pull and run Docker container:
docker pull ghcr.io/gear-foundation/gear-env:stable docker run --rm --name gear-env -itd ghcr.io/gear-foundation/gear-env:stable bash
-
Prepare smart contract for building (here we use
dapp-template
for example):git clone https://github.com/gear-foundation/dapp-template.git --depth 1 docker cp ./dapp-template gear-env:/root
-
Build smart contract on the Docker container:
docker exec -itw /root/dapp-template gear-env cargo build --release
-
Copy build artifacts back to the local machine:
docker cp gear-env:/root/dapp-template/target/wasm32-unknown-unknown/release/. ./
-
Stop the Docker container after using:
docker stop gear-env
- Based on Ubuntu 22.04 LTS
- Stable Rust toolchain:
v1.74.0
(79e9716c9 2023-11-13
) - Nightly Rust toolchain:
v1.74.0-nightly
(203c57dbe 2023-09-17
) - Node.js:
v18.17.1
- Yarn:
v1.22.21
- Gear node binary:
v1.0.2-d02d306f97c
- Based on Ubuntu 22.04 LTS
- Stable Rust toolchain:
v1.74.0
(79e9716c9 2023-11-13
) - Nightly Rust toolchain:
v1.75.0-nightly
(fcab24817 2023-10-13
) - Node.js:
v18.17.1
- Yarn:
v1.22.21
- Gear node binary:
v1.0.1-a3fe307bd8e
- Based on Ubuntu 22.04 LTS
- Stable Rust toolchain:
v1.74.0
(79e9716c9 2023-11-13
) - Nightly Rust toolchain:
v1.71.0-nightly
(f5559e338 2023-04-24
) - Node.js:
v18.17.1
- Yarn:
v1.22.21
- Gear node binary:
v0.2.2-946ac47439c
- Based on Ubuntu 22.04 LTS
- Stable Rust toolchain:
v1.70.0
(90c541806 2023-05-31
) - Nightly Rust toolchain:
v1.71.0-nightly
(f5559e338 2023-04-24
) - Node.js:
v18.16.0
- Yarn:
v1.22.19
- Gear node binary:
v0.1.6-78dfa07ed34
- Based on Ubuntu 22.04 LTS
- Rust toolchain:
v1.69
(stable
) andv1.70.0-nightly
(2023-03-14
) - Node.js:
v18.16
- Yarn:
v1.22
- Gear node binary:
v0.1.4-5c685d0
git clone https://github.com/gear-foundation/gear-env.git
cd gear-env
docker build -t gear-env docker
docker run --rm --name gear-env -itd gear-env bash
The source code is licensed under the MIT license.