NOTE: The service we used for cryptocurrency mining (Coinhive) for this website shut down, so this no longer works. |
---|
Simple Zcash(ZEC) faucet built with Node.
Install Zcash
Use the Zcash Debian binary packages install guide. The Zcash 1.0 User Guide has additional information if needed. You will have to fully sync the node before you can send any payments.
sudo apt-get install apt-transport-https
wget -qO - https://apt.z.cash/zcash.asc | sudo apt-key add -
echo "deb [arch=amd64] https://apt.z.cash/ jessie main" | sudo tee /etc/apt/sources.list.d/zcash.list
sudo apt-get update && sudo apt-get install zcash
Install Redis
wget http://download.redis.io/releases/redis-4.0.9.tar.gz
tar xzf redis-4.0.9.tar.gz
cd redis-4.0.9
make
src/redis-server
Clone the repo.
git clone https://github.com/ovsoinc/zfaucet
cd ~/zfaucet
npm install
Save this under ~/zfaucet/.env
.
RPCUSER=[Zcash RPC Username]
RPCPASS=[Zcash RPC Password]
PORT=[Webserver Port]
COINHIVEPUBKEY=[Coinhive Public Key]
COINHIVEPRIVKEY=[Coinhive Private Key]
WITHDRAWTHRESHOLD=[Coinhive Hashes Needed to Withdraw]
Run with PM2.
npm install pm2 -g
pm2 start process.json
We run this as a crontab */5 * * * * ~/script.sh
every 5 minutes.
#!/usr/bin/env sh
cd ~/zfaucet
git fetch && git reset --hard origin/master
node admin external new-key
node admin external list-keys
super3 | montyanderson | marktellez |