Skip to content

A demo web-shop where you can buy fortune-cookies with Lightning BTC payments.

Notifications You must be signed in to change notification settings

crypto-coins/fortuneCookies

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

68 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

lightning fortune cookies

Buy Chinese Fortune Cookies with Lightning satoshis. A demo-site to show how to accept Lightning payments.

Technology

  • Docker + Docker-Compose
  • BTCD daemon to download blockchain
  • LND daemon to interact with lightning network.
  • Node.js app interacts with LND.
  • Web UI via RTL LND web admin
  • Gotty to display realtime logs in webbrowser
  • tmux / byobu to not terminate the batch file on shell disconnect

Requirements

Port to be opened

  • 22 SSH
  • 80 web frontend
  • 8051 gotty realtime logs
  • 3000 RTL LND admin
  • 9735 public LND port for other peers to connect to

Build it

./build.sh

Run it

./startGotty.sh

Data (gets stored outside of docker images)

/datadrive/LND      LND settings and LND wallet
/datadive/shared    BTCD credentials
/datadrive/Bitcoin  blockchain storage

Logs

./logsBtcd.sh
./logsLND.sh
./logsApp.sh

Testing

./telnetBTCD.sh
./telnetLND.sh
./telnetApp.sh

BTC CTL

./telnetBTCD and then inside:

btcctl --rpccert=/rpc/rpc.cert --rpcuser=devuser --rpcpass=devpass version
btcctl --rpccert=/rpc/rpc.cert --rpcuser=devuser --rpcpass=devpass uptime
btcctl -u myuser -P mypass -s X.X.X.X:xxxx getpeerinfo --rpccert=rpc.cert

LND CONFIGURATION

./telnetLND.sh and then inside:

./createwallet.sh      (and write down the recovery mnemonic codes, they protect your BTC balance) DO THIS ONLY ONCE!
./unlock.sh            (do this every time you re-start the lnd daemon.)
./connectJOLTFUN.sh    (establish a connection to the peer at joltfun)
./openJOLTFUN.sh       (open a channel and fund it with 100,000 sats)

About

A demo web-shop where you can buy fortune-cookies with Lightning BTC payments.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published