Installation Steps
Obtaining the binary can be done by either of the following methods:
Method 1: Download Binary from GitHub
Method 2: Compile Binary Locally Using Script (Recommended)
Method 3: Compile Binary Manually
Method 1: Download Binary from GitHub
First make sure you have golang installed and $PATH is pointing to where go binary is installed. Also set the $GOPATH environment variable.
Head over to the Releases Page and download the latest version of the Onomy Binary.
Default structure for Onomy files:
3. Copy the downloaded binary to $HOME/.onomy/bin
directory and add executable permission chmod +x onomyd
4. Add $HOME/.onomy/bin
to $PATH environment variable. export PATH=$PATH:$HOME/.onomy/bin
5. To make changes in PATH variable persistent, run the following command, which will add an export command to your .bashrc
file:
echo "export PATH=$PATH:$HOME/.onomy/bin" >> ~/.bashrc
Move on to installing the full node
Method 2: Compile Binary Locally Using Script
Download the bin.sh script
Add the executable permission using
chmod +x bin.sh
Run the script using
bash bin.sh
Restart terminal so changes made in environment can take effect
This script downloads and compiles Onomy binary. A new directory .onomy
will be created in your home directory. All the source code will be downloaded in the .onomy/src
directory. Compiled binary will be in .onomy/bin
directory.
You are done and ready to go! Move on to installing the full node
Method 3: Compile Binary Manually
Create onomy Directory Tree
We can start a full node with Cosmovisor which changes and uses new binary automatically after a chain upgrade.
mkdir –p .onomy/bin
Create Cosmovisor directory if using Cosmovisor
mkdir –p .onomy/cosmovisor
Install Necessary Packages
Install packages needed to build Onomy binary.
This example is for ubuntu based systems
Install GO
Download the latest version of Go and extract it.
Setup environment variables
Check if go installation is working
go version
Compile Onomy
Download onomy repo and compile binary. Be sure to use the latest release.
If using Cosmovisor, move the binary to Cosmovisor directory
mv onomyd $HOME/.onomy/cosmovisor/genesis/bin/onomyd
Otherwise, we move it to bin directory
mv onomyd $HOME/.onomy/bin/onomyd
Compile Cosmovisor
Download and compile Cosmovisor
Post-installation
Verify $ONOMY_HOME
Environment Variable
Ensure that the $ONOMY_HOME
environment variable is correctly set to point to your ~/.onomy
directory. You can verify this by echoing the variable:
echo $ONOMY_HOME
If the output is not your ~/.onomy
path or is empty, you need to set it correctly. Add the following line to your ~/.bashrc
or ~/.profile
file to ensure it's set in every session:
source ~/.bashrc
or source ~/.profile
Now, make the binaries executable
Add onomy paths to PATH variable
Add to bashrc to make changes persistent
These variables are needed only for Cosmovisor
Move on to installing the full node
NOTE: Do not run the script as a super user. If you run script as a super user, then the .onomy directory will be created in home directory of super user. Script will ask for super user privileges while installing and updating packages.
Last updated