Skip to content
Snippets Groups Projects
tuxmain's avatar
bb913abb
History
Name Last commit Last update
res
src
.gitignore
Cargo.lock
Cargo.toml
LICENSE
README.md

gcli

CLI client for Duniter-V2S.

Using

Usage

If using a different runtime, update the metadata for the client to compile:

subxt metadata -f bytes > res/metadata.scale

Send 10 ĞD from Alice to Ferdie:

cargo run -- --url ws://localhost:9944 --secret //Alice transfer 1000 5CiPPseXPECbkjWCa6MnjNokrgYjMqmKndv2rSnekmSK2DjL

List certifications and session keys that will expire within one month:

cargo run -- --url wss://gdev.p2p.legal:443/ws expire --blocks 432000

Smith

You want to rotate keys and go online to start forging blocks.

Smith nodes must not expose a public RPC API. Then you can either use SSH directly, or make an SSH bridge by adding this to your local .bashrc:

alias duniter-rpc='ssh -L 9944:localhost:9944 duniter@gdev.example.tld'

Now the command duniter-rpc will open an SSH session and a bridge to your RPC API.

When your node is ready to forge blocks, rotate keys and go online:

gcli --secret "my secret phrase" update-keys
gcli --secret "my secret phrase" go-online