Quick Start Guide (<10 minutes)
This guide will help you set up and run PATH to serve requests using Morse or Shannon protocol in under 10 minutes.
This guide covers running PATH without any authentication or authorization mechanisms. Work is underway to provide these capabilities.
See PATH Guard documentation for details.
Prerequisites
- Docker installed and running on your system
1. Prepare Your Configuration
First, prepare your configuration file by following the PATH Config File instructions.
After you have your configuration file, you can proceed with the following steps:
-
Create a config directory for PATH:
mkdir -p ./path/config
-
Copy your configuration file to the new directory with the correct name:
export CONFIG_FILE=/PATH/TO/YOUR/CONFIG/FILE
cp $CONFIG_FILE ./path/config/.config.yaml
2. Set Up the PATH Container
TODO_IMPROVE: Replace main
with latest
once the artifact release CI is complete.
-
Set the PATH container image version from the set of available tags:
export PATH_IMAGE_TAG='main'
-
Start the PATH container:
docker run \
-itd \
--name path \
-p 3069:3069 \
-v ./path/config:/app/config \
ghcr.io/buildwithgrove/path:$PATH_IMAGE_TAGParameter explanation:
-p 3069:3069
: Map port 3069 on host to port 3069 in container. PATH listens on port 3069 for requests.-v ./path/config:/app/config
: Mount the config directory. PATH expects its configuration file at/app/config/.config.yaml
3. Verify PATH is Running
-
Check the PATH container logs:
docker logs path --follow --tail 100
-
Wait for PATH to be ready to serve requests:
curl -s http://localhost:3069/healthz
When PATH is ready, this command will return a
200 status code
and the response body will contain the JSON:"status": "ready"
Example response:
{
"status": "ready",
"imageTag": "development",
"readyStates": {
"endpoint-hydrator": true,
"pokt-morse": true
},
"configuredServiceIDs": ["F00C", "F021"]
}
4. Test Relays
A) If using Shannon
protocol
curl http://localhost:3069/v1 \
-H "Target-Service-Id: anvil" \
-d '{"jsonrpc": "2.0", "id": 1, "method": "eth_blockNumber" }'
You should expect to see a response similar to the following:
{ "id": 1, "jsonrpc": "2.0", "result": "0x2f01a" }
B) If using Morse
protocol
curl http://localhost:3069/v1 \
-H "Target-Service-Id: F00C" \
-d '{"jsonrpc": "2.0", "id": 1, "method": "eth_blockNumber" }'
You should expect to see a response similar to the following:
{ "id": 1, "jsonrpc": "2.0", "result": "0x2f01a" }
Troubleshooting
If PATH doesn't show as ready after a few minutes:
- Check the logs for error messages:
docker logs path
- Verify your configuration file is correct:
cat ./path/config/.config.yaml
- Ensure the ports aren't already in use:
lsof -i :3069
Next Steps
Once PATH is running successfully:
- Configure your client applications to connect to PATH
- Monitor PATH's performance and logs as needed
- For more advanced configuration options, refer to the full documentation
TODO_IMPROVE(@adshmh): Add additional instructions on how to test this and improve next steps