GithubHelp home page GithubHelp logo

blockchain-faucet-svc's Introduction

Ledgerium Token Faucet

Prerequisites

NodeJS

Confirm you have NodeJS installed by running node -v, output should look like:

v11.1.0

Download NodeJS

Node Package Manager (NPM)

Confirm you have NPM installed by running npm -v, output should look like:

v6.8.0

Download NPM

Redis

Confirm you have Redis installed and running by redis-cli ping, output should look like:

PONG

Download Redis

Docker (optional)

Confirm you have Docker installed and running by docker -v, output should look like:

Docker version 18.09.2, build 6247962

Download Docker

Download and Setup

Clone this repository to your computer

git clone https://github.com/ledgerium-io/ledgeriumfaucet.git

Navigate into the ledgeriumfaucet directory

cd ledgeriumfaucet

Create the .env file

  • Linux/MacOX
touch .env
  • Windows
echo.>.env

Open the .env file in any text editor and insert the following

CAPTCHA_SECRET=6LeIxAcTAAAAAGG-vFI1TnRWxMZNFuojJ4WifJWe
REDIS_URL=redis://127.0.0.1:6379
NODE_URL=http://125.254.27.14:8545
REDIS_EXPIRE_SECONDS=60
REQUEST_LIMIT=3
  • GOOGLE_CAPTCHA_SECRET -> Google Captcha secret key, the one above is public for local testing only

  • REDIS_URL -> Use 'redis' if using in docker, or a url if running locally

  • NODE_URL -> Ledgerium node address and port

  • REDIS_EXPIRE_SECONDS -> Limit (in seconds) how long a user must wait to receive more XLG

  • REQUEST_LIMIT -> Limit how many tokens a user can request per limit time cycle

Install the package dependencies using NPM

npm install

Usage

Locally

Run the faucet

node index [private key]

Example:

node index 29cf428305336e251c117394b0a327b55604230affb888885d871763cf7fe43d

Docker Container (optional)

docker-compose up -d

blockchain-faucet-svc's People

Contributors

skytradeinc avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.