Nix
Install Nix using the Determinate Systems installer to get Nix with Flakes installed.
$ curl --proto '=https' --tlsv1.2 -sSf -L https://install.determinate.systems/nix | sh -s -- install
The repository comes with a developer environment (devShell) which can be accessed by running:
$ nix develop
# to exit the shell enviroment enter "exit" in your shell
The devShell provides all the system tools and dependencies required to develop and run the project
(nix:nix-shell-env) $ go version # go version go1.23.7
(nix:nix-shell-env) $ sui version # sui 1.44.3-615516edb0ed
To make sure that you're sui
environment is ready, you can first check the active
address using the cli
(nix:nix-shell-env) $ sui client active-address
Then you can proceed to make sure that you can the local
RPC available in the
list of sui cli environments
(nix:nix-shell-env) $ sui client envs
And if you don't see "local", you can add it as follows
sui client new-env --alias local --rpc http://127.0.0.1:9000
sui client switch --env local
We use Task to execute development tasks. You can find every task referenced in the Taskfile
(nix:nix-shell-env) $ task lint
(nix:nix-shell-env) $ task lint:fix
- Docker
- Docker Compose
- Docker Desktop (or OrbStack)
- Run
docker compose up
to get thesui
devnet up and running - You can now
exec
into the container by runningdocker compose exec -it sui bash
- Run
sui client envs
to view the available sui environments
NOTE: You can view the open ports and the commands used by inspecting the
/sui/docker-compose.yml
file. It is a work in-progress and will likely change.
Once you have the local Sui devnet running, you can deploy the sample contracts using:
./scripts/deploy_contracts.sh
This will build and deploy the contracts in contracts/test
to your local Sui network.
For detailed documentation about using the Sui Relayer Plugin, including how to configure and use the ChainReader and ChainWriter components, see RELAYER.md.