💻Prerequisite Installation
Before you begin, you should confirm that you have installed all the prerequisites below on the platform where you will be running Hyperledger Fabric.
Install Git
Download the latest version of git if it is not already installed.
sudo apt-get update
sudo apt-get install git
Install cURL
Download the latest version of the cURL tool if it is not already installed or if you get errors running the curl commands from the documentation.
sudo apt install curl
Docker and Docker Compose
You will need the following installed on the platform on which you will be operating, or developing (or for), Hyperledger Fabric:
Set up the repository
Update the
apt
package index and install packages to allowapt
to use a repository over HTTPS:
sudo apt-get update
sudo apt-get install \
ca-certificates \
curl \
gnupg \
lsb-release
Add Docker’s official GPG key:
sudo mkdir -m 0755 -p /etc/apt/keyrings
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /etc/apt/keyrings/docker.gpg
Use the following command to set up the repository:
echo \
"deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu \
$(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
Install Docker Engine
Update the
apt
package index:
sudo apt-get update
Install Docker Engine, containerd, and Docker Compose.
To install the latest version, run:
sudo apt-get install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
Make sure the docker daemon is running.
sudo systemctl start docker
sudo systemctl enable docker
sudo groupadd docker
sudo usermod -aG docker ${USER}
sudo setfacl --modify user:$USER:rw /var/run/docker.sock
Check if your Hello-World works fine:
sudo docker run hello-world
Install docker-compose and check its version
sudo curl -L "https://github.com/docker/compose/releases/download/1.29.2/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
sudo chmod +x /usr/local/bin/docker-compose
docker-compose --version
Install GoLang
We would need Go-Lang to run chaincodes on Hyperledger Fabric. Let's Install by running the below commands.
sudo snap install golang --classic
source ~/.profile
Let's check the go version.
go version
Install NVM
NVM is a Node Version Manager tool. Using the NVM utility, you can install multiple node.js versions on a single system. You can also choose a specific Node version for applications.
sudo apt-get install build-essential libssl-dev
curl https://raw.githubusercontent.com/creationix/nvm/master/install.sh | bash
source ~/.profile
Install Node and NPM
You can install multiple node.js versions using nvm. And use the required version for your application from installed node.js.
nvm install 20
nvm use 20
Let's check Node & Npm Versions
node --version
npm --version
Last updated
Was this helpful?