Update sharder image via cli

After the mainnet release, we will be continously monitoring the chain performance and will do releases over time. To update your sharders, please follow the below steps:

  1. ssh into the sharder server using below command. Replace <SERVER-IP-ADDRESS> with ip address of sharder server. It will ask for password to ssh so, you need to input server password.

    ssh -o StrictHostKeyChecking=no root@<SERVER-IP-ADDRESS>
  2. Run the following command to set the TAG

    export TAG=v1.20.1
  3. Proceed to updating images using command below:

    yq e -i ".services.sharder.image = \"0chaindev/sharder:${TAG}\"" /var/0chain/sharder/ssd/docker.local/build.sharder/p0docker-compose.yaml
  4. Start sharder with updated image using command below:

    cd /var/0chain/sharder/ssd/docker.local/sharder1/
    sudo bash ../bin/start.p0sharder.sh /var/0chain/sharder/ssd /var/0chain/sharder/hdd

This will automatically pull the latest images and will restart the sharders with the new image.

You can confirm the changes by running:

sudo docker ps -a | grep 0chaindev/sharder:${TAG}

The above command should show 1 line of output.

Last updated