lbryio / block-explorer

The new LBRY block explorer
https://explorer.lbry.com
MIT License
18 stars 22 forks source link
blockchain explorer lbry

LBRY Block Explorer

A simple PHP block explorer for browsing transactions and claims on the LBRY blockchain. The explorer was developed using CakePHP which is a model-view-controller (MVC) PHP framework.

Requirements

There are some prerequisites that need to be installed before the explorer can be accessed.

on ubuntu you may use this to install php requirements

sudo apt install php7.4-gmp php7.4-intl php7.4-mbstring php7.4-mysql php7.4-bcmath php7.4-gd

Installation steps

Cron jobs

There are a few scripts which can be set up as cron jobs or scheduled tasks.

blocks.sh

Detect new LBRY blocks. Can also be configured to be triggered using the lbrycrd blocknotify flag. This cron will create new blocks obtained from lbrycrd starting from the highest block number in the database, and then create the corresponding block transactions. If there are pending transactions created by the forevermempool script, they will be automatically associated with the respective blocks.

claimindex.sh

Create claims found on the LBRY blockchain in the database. This requires the Python decoder to be running in the background.

pricehistory.sh

Get the current LBC price in USD and store the value in the PriceHistory table. This also caches the most recent price in Redis.

forever.sh

Run the forevermempool script, and restart if necessary. The forevermempool script checks the LBRY blockchain mempool every second and creates transactions found in the database. The script makes use of Redis for caching the pending transaction IDs.

Usage

Launch the URL for the configured web server root in a browser.

Contributing

Contributions to this project are welcome, encouraged, and compensated. For more details, see https://lbry.tech/contribute

License

This project is MIT licensed. For the full license, see LICENSE.

Security

We take security seriously. Please contact security@lbry.io regarding any security issues. Our PGP key is here if you need it.

Contact

The primary contact for this project is @akinwale (akinwale@lbry.com)