Jakub Sokołowski
0e2637f02a
Signed-off-by: Jakub Sokołowski <jakub@status.im> |
||
---|---|---|
.. | ||
defaults | ||
handlers | ||
tasks | ||
templates | ||
README.md |
README.md
Description
This role configures the faucet service which provides a REST API for receiving funds from our Goerli node.
Requirements
This role assumes it has a geth
container with JSON RPC port open configured via Docker Compose.
Configuration
It makes sense to set the service name, it should match the Geth name:
faucet_service_name: 'goerli-faucet'
The container needs know the Geth RPC port and account secret:
faucet_geth_rpc_port: 8545
faucet_account_pass: 'my-secret-pass'
In addition to that it needs a domain and network:
faucet_network: 'goerli-faucet.example.org'
faucet_domain: 'goerli'
faucet_cors_rule: '.*'
API
> curl -s http://localhost:3001/ | jq .
{
"message": "Status.im Goerli Faucet",
"methods": [
"GET /",
"POST /queue",
"GET /donate/{address}",
"GET /faucet-info"
]
}
Usage
To check sync state you can use the rpc.sh
wrapper for calling JSON RPC API:
> /docker/goerli-faucet/rpc.sh eth_syncing
{
currentBlock: 202432,
highestBlock: 5120931,
knownStates: 0,
pulledStates: 0,
startingBlock: 149504
}