https://github.com/nervosnetwork/ckb-discovery
https://github.com/nervosnetwork/ckb-discovery
Last synced: 15 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/nervosnetwork/ckb-discovery
- Owner: cryptape
- Created: 2023-09-04T19:24:16.000Z (almost 3 years ago)
- Default Branch: master
- Last Pushed: 2025-03-31T07:13:25.000Z (about 1 year ago)
- Last Synced: 2025-04-11T00:04:06.265Z (about 1 year ago)
- Language: Rust
- Size: 157 KB
- Stars: 3
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# CKB-Discovery
This is a re-implementation of the CKB-Node-Probe project, Contains 3 module:
## Discovery
This is a dialer/probe module, used to dial/find reachable peers. It won't dial reachable peers directly, instead it will receive peer info from MQTT channel `peer/needs_dial`, and dial for that.
(Except bootnodes)
## Marci
This is the center that controls which peer should be called, which peer should be treated as online and so on.
Think it as a broadcaster and msg channel guider.
## Exposed
This is a query service provided for the frontend
## How to start
First, you'll need to cp .env.example and modify the value to secure your MQTT and Reidis.
For the data center, run `docker-compose up -d`, it will:
1. start a MQTT service, expose at `1883`&`1884`
2. start a Redis server, expose at `6379`
3. start the expose server(query api service), expose at 1800
4. start marci service
If you want to run a dialer, run `docker build . -t ckb-discovery && docker run --restart always --name ckb-discovery -e MQTT_URL="mqtt://54.255.71.126:1883" -d ckb-discovery`
Remember to replace `127.0.0.1` with the data center ip.