Skip to content

ethgasstation/ethgasstation-frontend

Repository files navigation

ETH Gas Station

EthGasStation is a tool for monitoring the time transactions take to be confirmed on the ETH network. It also monitors and estimates miner policies with respect to gas prices and formats the data for viewing over http.

Note that this UI is facing deprecation and will not be supported long-term. Many changes have been made to this UI in order to move EGS forward, and a new UI/frontend is in the works that relies on the new API layer.

You can view a working legacy implementation of ETH Gas Station at gasstation-legacy.etheria.io. Note that this is a demo version of this code, and thus should not be relied upon for production data. Use ethgasstation.info for all production data.

Requirements

This version of the ETH Gas Station frontend has multiple requirements:

  • PHP
  • Python 3 for running regressions, or if you want to use Redis
  • A MySQL-compatible data store
  • A working ETH Gas Station backend service

The frontend reads JSON files generated by the ETH Gas Station backend, which is a submodule for this project. See the backend repository for information on running the backend. Run the backend with --generate-report so this frontend will get the files it needs.

Usage

  1. Update build/php/common.php with your own data.
  2. Set up the backend to export data to json/ in the root directory.
  3. Run the backend. The backend will need time to generate files from transactions.
  4. Run the frontend and view the data.

If you are having trouble, make sure that json files are in json/ and you can view the JSON files appropriately.

Using Redis with this legacy frontend

It is possible to separate the backend and frontend, and not run all of the ETH Gas Station on a single server. In fact, this is how ETH Gas Station works in production. JSON generated by the ETH Gas Station backend is placed into Redis, and all database data is in a separate MariaDB instance on a different computer.

This legacy frontend assumes it will get JSON from flat files in the json/ directory. data_analysis/make_json.py contains a Python script that will take the JSON files generated by the backend in Redis and write them down to flat files in the directory structure. Running this script will attempt to update the JSON for the UI every 15 seconds (roughly once per block created.) You will need to update make_json.py with the info that points at your Redis cluster.

License

The ETH Gas Station frontend, like the backend, is GNU GPL 3.0. We have chosen the GPL 3.0 specifically to compel disclosure of modifications to the ETH Gas Station. We have created all of this as a community service, and licenses such as MIT give too much permission for commercial projects that have wanted to profit off of the ETH Gas Station without making their own modifications available to the Ethereum community or supporting the ETH Gas Station project.

If you are interested in commercially licensing ETH Gas Station technology for closed-source use, please reach out to ethgasstation AT protonmail {dot} com.

About

ETH Gas Station PHP Frontend. Deprecated.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published