Skip to content

Latest commit

 

History

History

contract-builder

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 

Contract Builder

This is a helper Dockerfile that allows to build contracts in a reproducible way.

The contract built in the Docker will result in a binary that is the same if built on other machines.

For this you need to setup Docker first.

Build container

./build.sh

Start docker instance

By default, the following command will launch a docker instance and will mount this near-sdk-rs under /host.

./run.sh

If you need to compile some other contracts, you can first export the path to the contracts, e.g.

export HOST_DIR=/root/contracts/

Build contracts in docker

Enter mounted path first:

cd /host

For example, to build contracts in near-sdk-rs do the following:

cd examples
./build_all.sh