Connect sidecar
Run Connect Sidecar
Please find the connect binary or image based on your deployment preference
From binary: https://github.com/MANTRA-Chain/connect/releases/tag/v2.3.0-mantra-1.2 From image: ghcr.io/mantra-chain/connect-sidecar:2.3.0-mantra-1.2
To run Connect, which starts the service on the default port of 8080
, enter the following command:
connect --market-map-endpoint="<YOUR_VALIDATOR_GRPC_URL>:<YOUR_VALIDATOR_GRPC_PORT>"
If you are running connect and validator in the same server, it should be like
connect --market-map-endpoint=localhost:9090
Verify Connect
To verify Connect is working, run the following command:
curl 'http://localhost:8080/connect/oracle/v2/prices' | jq .
The output of the command should look similar to this:
{
"prices": {
"ATOM/USD": "4308207537",
"BTC/USD": "6693024042",
"ETH/USD": "2602324302",
"OM/USD": "1501599",
"OSMO/USD": "53054083",
"USDT/USD": "999750064",
"USDY/USD": "1054483"
},
"timestamp": "2024-10-17T12:09:39.899360574Z",
"version": "v2.0.1"
}
Update Validator Config
In order for the application to get prices from Connect, we need to add the following lines under the [oracle]
heading in the app.toml
.
Remember to change the oracle_address
value to the address of your Connect sidecar.
[oracle]
enabled = "true" # if you are not running a validator node, set this to "false"
oracle_address = "<YOUR_CONNECT_SIDECAR>:8080" # YOUR_CONNECT_SIDECAR should localhost if running on the same server as validator
client_timeout = "2s"
metrics_enabled = "true"
price_ttl = "0s"
interval = "1.5s"
Lastly, restart your validator. For more information, please check https://docs.skip.build/connect/validators/quickstart#run-connect-sidecar
Last updated