CKB is the layer 1 of Nervos Network, a public/permissionless blockchain. CKB uses Proof of Work and improved Nakamoto concensus to achieve maximized performance on average hardware and internet condition, without sacrificing decentralization and security which are the core value of blockchain.
CKB Testnet Faucet is a Testnet Aggron faucet built with React and Ruby on Rails.
It supports claim ckb testnet tokens.
- PostgreSQL 9.4 and above
- Ruby 2.6.4 and above
- Redis 4.0.9 and above
- ckb-sdk-ruby 0.28.0 and above
$ cd ckb-testnet-faucet/
$ EDITOR=vim rails credentials:edit (overwrite configs)
$ bin/setup
$ bundle exec rake migration:create_official_account
REDIS:
URL: redis://172.31.16.215:7379/11
DB:
USERNAME: "your db username"
PASSWORD: "your db password"
HOST: localhost
PORT: 5432
RAILS_MAX_THREADS: 30
CKB_NODE_URL: "http://localhost"
OFFICIAL_WALLET_PRIVATE_KEY: "your private key"
SECP_CELL_TYPE_HASH: "0x9bd7e06f3ecf4be0f2fcd2188b23f1b9fcc88e5d4b65a8637b17723bbda3cce8"
ALLOWED_IPS:
- 127.0.0.1
AGGRON_EXPLORER_HOST: "https://explorer.nervos.org/aggron"
secret_key_base: "your secret key base"
$ bundle exec rails test
# before run project you need to use `get_lock_hash_index_states` rpc check ckb indexer status
$ bundle exec rails s
# start send capacity service
$ ruby lib/claim_event_processor.rb
You can deploy this via mina
$ mina setup
$ mina production deploy
CKB Testnet Faucet is an open source project and your contribution is very much appreciated. Please check out CONTRIBUTING.md for guidelines about how to proceed.
CKB Testnet Faucet is released under the terms of the MIT license. See LICENSE for more information or see https://opensource.org/licenses/MIT.