This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
cd /home/USERNAME/cardano | |
BLOCK_HASH=`/home/USERNAME/.cargo/bin/jcli rest v0 node stats get --host http://127.0.0.1:3100/api | grep 'lastBlockHash:' | sed -e 's/^[[:space:]]*//' | sed -e 's/lastBlockHash: //'` | |
FOUND=`/usr/bin/node /home/USERNAME/cardano/check_for_block.js $BLOCK_HASH` | |
if [[ "$FOUND" -eq 1 ]]; then | |
echo "`date`: Block Found!!" | |
else |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
curl 'http://api.forknote.net:8090/genesis_tx/' -H 'Origin: http://forknote.net' \ | |
-H 'Accept-Encoding: gzip, deflate' -H 'Accept-Language: en-US,en;q=0.9,pt;q=0.8' \ | |
-H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/63.0.3239.132 Safari/537.36' \ | |
-H 'Content-Type: application/x-www-form-urlencoded; charset=UTF-8' -H 'Accept: application/json, text/plain, */*' \ | |
-H 'Referer: http://forknote.net/create/' -H 'Connection: keep-alive' \ | |
--data '{"MoneySupply":"100000000000000000","EmissionSpeedFactor":21,"DifficultyTarget":60,"GenesisBlockReward":"1000000000","AddressPrefix":322560377,"Addresses":["imzt1vK1qVFNP5N4hMrgs96Fz4zvP9gJ5MTh1YpKVVVtBc54Co2K12J1sczeHe6DDQBsBkmfN37rxAWssaf7LU7eVmQWvRboxG31H"]}' \ | |
--compressed |