Guide to setting up and running a local Story network for development and testing
You can easily set up your own local Story network using docker compose, consisting of one boot node and four validator nodes. With this local network, you can test the consensus layer of the Story network or deploy your application using the precompiled primitive, the IP graph, to conduct various tests. Additionally, you can reset the network at any time as needed.
For more detailed information for running Story local network, please refer the repository: https://github.com/piplabs/story-localnet
To set up a local network, Docker is required.
Please run Docker.
You need to clone three repositories: story
, story-geth
, and story-localnet
.
Make sure all three repositories are located within the same subfolder.
Navigate to story-localnet project and start the local network.
If you want to stop the Story local network, you can do so by executing the script below.
You may need to allocate IP tokens to your account for testing in the local network.
To allocate tokens to your account in the genesis block, follow these steps:
config/story/genesis-geth.json
:update-genesis-hash.sh
script to update the genesis block hash:By default, the Story local network has the following ports open for interaction.
Port | Service | Role |
---|---|---|
8545 | story-geth | Endpoint of RPC server for Story execution client |
1317 | story-node | Endpoint of API server for interacting with the Story consensus client |
26657 | story-node | Endpoint of cosmos-sdk RPC server for Story consensus client |
This setup includes a monitoring stack to provide centralized metrics and logs
visualization for the blockchain network. Tools include Prometheus,
Loki, Promtail, and Grafana, all integrated through Docker Compose.
Service | Role | Default Port | Access URL |
---|---|---|---|
Prometheus | Collects metrics from nodes and itself for performance monitoring | 9090 | http://localhost:9090 |
Loki | Aggregates and stores logs from the network nodes via Promtail | 3100 | http://localhost:3100 |
Promtail | Scrapes logs from Docker containers and sends them to Loki | 9080 (API), 9095 (Metrics) | http://localhost:9080 |
Grafana | Provides a dashboard interface for metrics and logs visualization | 3000 | http://localhost:3000 |