CLI - Set Up
Set up the environment on your computer, and install Sifnode.
Set up your Environment
Thanks to the Cosmos hub for their stellar documentation about using the CLI to interact with Cosmos chains. Sifchain is built on the Cosmos SDK.
Build Requirements
At present, the CLI fully supports installation on linux distributions. For the purpose of this instruction set, we'll be using Ubuntu 20.04.3 LTS
. It is also possible to install on Unix, while Windows may require additional unsupported third party installation (eg. Install WSL and then use it to follow the Linux Instructions). All steps are listed below for a clean install.
Linux:
Update the local package list and install any available updates:
Install make
and gcc
, ensure correct time sync
Unix (Mac):
Ensure you have installed homebrew. Then update and upgrade it:
Now install gcc
Install make
2) Install Go (1.17.7+ is required for Sifchain)
Linux: You can follow these docs to install Go.
The current version required is go 1.17.7 and you can download by launching:
and then installing it in the local directory:
Unix:
3) Add the GOPATH
After installing Go, ensure that you add GOPATH
to your PATH
variable so that we can run the sifnoded binary.
Linux:
Open the profile file (~/.profile) :
add the following:
Apply the changes on the current shell:
Unix:
Open the profile file (~/.profile) :
add the following:
Apply the changes on the current shell:
Or alternatively, launch this command everytime you open the shell:
4) Install Sifnoded
Next, we need to install the Sifnode binaries:
Move to the newly installed folder
Compile and install a non-archive node:
Troubleshooting
You may encounter an error here:
In this instance, from terminal run:
This will return the path to you Go Root directory. If it is not /usr/local/go, copy the path. Now return to step 3 above, "Add the GOPATH", and update the .profile file with the correct path to GOROOT. Save it - you may need to restart terminal for the changes to take effect.
5) Create a wallet
From within the ~/sifnode
folder, create a wallet:
sifnoded keys add <wallet name>
You will be asked to create a passphrase. This will protect the mnemonic that will be generated. Remember to safely back up the mnemonic Note:
If your transaction throws any error, make sure to add the necessary flags. Some of the flags you may need are:
Some useful flags:
--chain-id string
The network chain ID
--fees string
Fees to pay along with transaction
--from string
Name or address of private key with which to sign
--keyring-backend string
Select keyring's backend (os|file|kwallet|pass|test|memory)
--node string
<host>:<port> to tendermint rpc interface for this chain
Logs flag:
--log_format string
The logging format (json|plain) (default "plain")
--log_level string
The logging level (trace|debug|info|warn|error|fatal|panic)
--trace
print out full stack trace on errors
Last updated