SatSale

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README | LICENSE

config_lightning.py (2103B)


      1 # In this example config, we enable lightning payments
      2 # On-chain payments will still be an option for users
      3 
      4 # We will be hosting SatSale on the same machine as our node. For remote, see other example config.
      5 # SatSale & Bitcoin Lightning Node    1.1.1.1     8332, 10009 (bitcoind, lnd)
      6 
      7 # As we are running SatSale on our node,
      8 # it can directly talk to our node at localhost 127.0.0.1
      9 host = "127.0.0.1"
     10 rpcport = "8332"
     11 
     12 # From ~/.bitcoin/bitcoin.conf
     13 username = "bitcoinrpc"
     14 password = "rpcpassword"
     15 
     16 # Wallet (empty "" if your node has a single wallet, OR wallet name/path as shown in `biitcoin-cli listwallets`)
     17 wallet = ""
     18 
     19 # File in which API key will be stored
     20 api_key_path = "SatSale_API_key"
     21 
     22 # As we are running SatSale on our node
     23 # we do not require any remote tunnel, leaving next part as None,
     24 
     25 #### Connect To Remote Node ####
     26 # Can use SSH or TOR
     27 # to tunnel/relay ports required to talk to the node via RPC (gRPC for lightning)
     28 
     29 # SSH tunnel to node
     30 # Make sure this command works `ssh HOST@IP -q -N -L 8332:localhost:8332`
     31 # Use host = "127.0.0.1" and you will be able to see your node on 8332
     32 tunnel_host = None  # "HOST@IP"
     33 
     34 # or tor hidden service for RPC (see docs for how to set up), need onion:
     35 tor_bitcoinrpc_host = None # e.g. "http://if...dwr.onion"
     36 # and a tor proxy, default 127.0.0.1:9050 (for Tor Browser use "127.0.0.1:9150")
     37 tor_proxy = None
     38 
     39 #### Payment method ####
     40 pay_method = "bitcoind"
     41 
     42 #### Lightning ####
     43 # HERE we Switch payment_method to lnd,
     44 pay_method = "lnd"
     45 
     46 # Uncomment lnd_dir,
     47 lnd_dir = "~/.lnd/"
     48 
     49 # And specify the RPC port
     50 lnd_rpcport = "10009"
     51 
     52 # That's all the changes needed to get lightning connected.
     53 
     54 
     55 # Check for payment every xx seconds
     56 pollrate = 15
     57 
     58 # Payment expires after xx seconds
     59 payment_timeout = 60*60
     60 
     61 # Required confirmations for a payment
     62 required_confirmations = 2
     63 
     64 # Global connection attempts
     65 connection_attempts = 3
     66 
     67 # Generic redirect url after payment
     68 redirect = "https://github.com/nickfarrow/satsale"
     69 
     70 # DO NOT CHANGE THIS TO TRUE UNLESS YOU WANT ALL PAYMENTS TO AUTOMATICALLY
     71 # BE CONSIDERED AS PAID.
     72 free_mode = False