Hyperledger Use Case, in Healthcare

Logeswaran Audhikesavan
Coinmonks
4 min readJul 5, 2020

--

In this article, we will understand how blockchain helps healthcare industry in which clinical trials can happen much better than traditional and complex data flow.

Clinical trials are experiments or observations done in clinical research. Such prospective biomedical or behavioral research studies on human participants are designed to answer specific questions about biomedical or behavioral interventions, including new treatments (such as novel vaccines, drugs, dietary choices, dietary supplements, and medical devices) and known interventions that warrant further study and comparison. (Source Wiki)

Having read that, it is very clear that Clinical Trials has to happen under close monitoring circle and every actions they perform or take should be documented and tamper proof. Many existing technologies are there to perform this better, but after “Blockchain” evolved. Healthcare industry have started adopting this in every phases where the data security, integrity & high availability is met.

We will see this use case in 4 article, by end of 4th article you should be able to setup a blockchain network using Hyperledger, write chaincode and create rest-API to access the same.

Unfortunately, I am not a front-end developer, so I cannot promise the front end design, but I will ensure the complete backend is up & running without any flaw.!

No more talking!, Let’s get into business..

Steps to be done

  • Pre-Requisites — Environment Prep
  • Hyperledger Network Setup
  • Chaincode Setup — Use Case
  • REST-API Setup — To read and write into Blockchain

Step 1 — Hyperledger Network Setup — Environment Preparation

# Exit on any failureset -e# Array of supported versionsdeclare -a versions=('trusty' 'xenial' 'yakkety', 'bionic')# check the version and extract codename of ubuntu if release codename not provided by userif [ -z "$1" ]; then   source /etc/lsb-release || \       (echo "Error: Release information not found, run script    passing Ubuntu version codename as a parameter"; exit 1)   CODENAME=${DISTRIB_CODENAME}else   CODENAME=${1}fi

Update Package List

# Updating package listssudo apt-add-repository -y ppa:git-core/ppasudo apt-get update

Install Git

echo "# Installing Git"sudo apt-get install -y git

Install NVM

# Execute nvm installation scriptecho "# Executing nvm installation script"curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.2/install.sh | bash

Setup npm environment without restarting the Shell

export NVM_DIR="${HOME}/.nvm"[ -s "${NVM_DIR}/nvm.sh" ] && . "${NVM_DIR}/nvm.sh"[ -s "${NVM_DIR}/bash_completion" ] && . "${NVM_DIR}/bash_completion"

Install Node

echo "# Installing nodeJS"nvm install 8.16.1nvm use 8.16.1

Ensure CA Certificates are installed

sudo apt-get -y install apt-transport-https ca-certificates

Add Docker repository key to APT keychain

curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -

# Update where APT will search for Docker Packages

echo “deb [arch=amd64] https://download.docker.com/linux/ubuntu ${CODENAME} stable” | \sudo tee /etc/apt/sources.list.d/docker.list

Update Package List

sudo apt-get update

Verifies APT is pulling from the correct Repository

sudo apt-cache policy docker-ce

Install kernel packages which allows us to use aufs storage driver if V14 (trusty/utopic)

if [ "${CODENAME}" == "trusty" ]; then   echo "# Installing required kernel packages"   sudo apt-get -y install linux-image-extra-$(uname -r) linux-image-extra-virtualfi

Install Docker

echo "# Installing Docker"sudo apt-get -y install docker-ce

Add user account to the docker group

sudo usermod -aG docker $(whoami)

# Install docker compose

echo "# Installing Docker-Compose"sudo curl -L "https://github.com/docker/compose/releases/download/1.13.0/docker-compose-$(uname -s)-$(uname -m)" \-o /usr/local/bin/docker-composesudo chmod +x /usr/local/bin/docker-compose

Install python v2 if required

set +eCOUNT="$(python -V 2>&1 | grep -c 2.)"if [ ${COUNT} -ne 1 ]then   sudo apt-get install -y python-minimalfi

Install unzip, required to install hyperledger fabric.

sudo apt-get -y install unzipsudo apt-get -y install zip

Install Nginx

echo "# Installing Nginx"sudo apt install nginx

# Install mongodb

echo "# Installing mongodb"sudo apt install -y mongodbsudo apt-get install jq

# Install Go & Setup path

1) sudo apt install -y golang
2) export GOROOT=/usr/lib/golang
3) export GOPATH=$HOME/projects
4) export PATH=$PATH:$GOROOT/bin
5) Set this in .profile file for permenantly
6) . ~/.profile -> this command will help you to refresh the profile without loggingout

# Install Fabric

------curl -sSL http://bit.ly/2ysbOFE | bash -s <fabric> <fabric-ca> <thirdparty>----1) curl -sSL http://bit.ly/2ysbOFE | bash -s 1.4.4 1.4.4 0.4.18So if you want 1.4.0 version, change that accordingly in above command

This will take some time to download images for Fabric & once it is done. You should be able to see fabric-samples folder.

If you can able to setup this environment without any issues, you are ready to move into next article.

let’s catch up in next article.

Get Best Software Deals Directly In Your Inbox

--

--

Logeswaran Audhikesavan
Coinmonks

Happy to learn, what I have experienced in Blockchain & Analytics Space, watch out www.blockchaindreamlab.com & www.zuiverinfotech.com