This service can be used to fund accounts with KIN
- Edit the 'seeds.txt' file with the seeds and channels you wish to use.
The main seed is mandatory since all of the funded KIN will be sent from this account.
Channel seeds are optional and are used to improve the handling of high number of requests at the same time.
main seed
channel seed 2
channel seed 3
channel seed 4
channel seed 5
.
.
.
- Edit the docker-compose.yaml file and update the "SEEDS_NUMBER" variable
You can also configure the rest of the variables if you wish to use a custom network.
SEEDS_NUMBER - The number of seeds you are using
# By defualt, these are all configured to the public stellar testnet
# You dont need to change them unless you are using a different network
HORIZON_ENDPOINT - The url of the horizon instance you are using
NETWORK_PASSPHRASE - The passphrase of the horizon instance you are using
KIN_ISSUER - The address of the KIN issuer
- Install docker and docker-compose
- Inside this project's folder, run the command
$ sudo docker-compose up
The faucet will run on localhost:5000
(The remote machine needs to run Ubuntu 16+)
- Install ansible
- Install the angstwad.docker_ubuntu role:
$ ansible-galaxy install angstwad.docker_ubuntu -p playbook/roles/
- Edit the 'hosts' file inside
playbook/inventory
and add the IP of the remote machine - Run the playbook:
$ ansible-playbook -i playbook/inventory/ playbook/main.yml
The faucet will run on <ip>:5000
Success will return http code 200
Expected errors will return http code 400
Unexpected errors will return http code 500
GET '/status'
{
'address': 'GBDUPSZP4APH3PNFIMYMTHIGCQQ2GKTPRBDTPCORALYRYJZJ35O2LOBL',
'network': 'CUSTOM',
'channels':
{
'all': 8,
'free': 8
},
'horizon':
{
'online': true,
'uri': 'https://horizon-testnet.stellar.org',
'error': null
},
'kin_asset':
{
'issuer': 'GCKG5WGBIJP74UDNRIRDFGENNIH5Y3KBI5IHREFAJKV4MQXLELT7EX6V',
'code': 'KIN'
}
}
OR
{
"error": 'unexpected error: exception message'
}
GET '/fund?account=<account>&amount=<amount>'
{
'succsseful': true/false
'error': null/'Account does not exist'/'No KIN trustline established'/
'Invalid address'/'Amount parameter missing'/'Account parameter missing'/'Invalid amount'/
'unexcpected error: exception message'
}