Tutorial – Create a Block Explorer for the Libra Cryptocurrency: Part I – The Backend

A block explorer is one of the most important tools every cryptocurrency needs. It allows the end-user to quickly search the blockchain ledger for addresses and transactions data.

During the first month of Libra testnet existence, several experimental block explorers were created by the Libra open-source developers community.

At Libra Startup, we have developed and released our own Libra block explorer. It is open-source, and currently, you are reading its step-by-step tutorial.

This quick tutorial explains how to create a simple Libra block explorer’s back-end with Node.js and MongoDB, communicating with the Libra blockchain through a lightweight JavaScript gRPC library, and returning data to the front-end through a custom made API.

The front-end guide will be available in the second part of this tutorial. Currently, you can use its beta source code, see GitHub.

The block explorer application, created according to this tutorial, is in its early beta stage, live at Libra Checker.

Part I – The Backend

Below are the steps that need to be taken to set up the back-end from scratch.

1. Install Node.js, nginx, configure the firewall
2. Configure a reverse proxy (and SSL)
3. Install MongoDB
4. Create the API script and run it with PM2
5. Install Libra gRPC client to save Libra blockchain data to MongoDB

We are running this on a fresh Ubuntu 19.04 Linux install in a VM on Google Cloud.

Continue reading “Tutorial – Create a Block Explorer for the Libra Cryptocurrency: Part I – The Backend”

Tutorial – How to set up and run the Libra CLI (Rust) environment

It’s a starting point for every Libra developer. Even if you are not going to use this Rust package in production, it is worth the effort to get familiar with it.

It works on a fresh Ubuntu 19.04 install with a few commands, and is not missing any dependencies or libraries. With some other Linux distributions, people are reporting issues.

So these are the steps to run the Libra CLI:
1. Install Node.js
2. Install Libra CLI
3. Run Libra CLI

Continue reading “Tutorial – How to set up and run the Libra CLI (Rust) environment”