Browse Source

Expose CLightning-Rest to BTCPay and external use (#258)

* Expose CLightning-Rest to BTCPay and external use

This should allow Zeus wallet to use clightning

* fix redirect rule
master
Andrew Camilleri 5 years ago
committed by Nicolas Dorier
parent
commit
a5da75901f
  1. 6
      Production/nginx.tmpl
  2. 2
      docker-compose-generator/docker-fragments/bitcoin-clightning.yml

6
Production/nginx.tmpl

@ -56,6 +56,12 @@
{{ if (eq $serviceName "clightning_bitcoin_charge") }}
location /lightning-charge/btc/ {
proxy_pass http://clightning_bitcoin_charge:9112/;
}
{{ end }}
{{ if (eq $serviceName "clightning_bitcoin_rest") }}
location /clightning-rest/btc/ {
rewrite ^/clightning-rest/btc/(.*) /$1 break;
proxy_pass http://clightning_bitcoin_rest:3001/;
}
{{ end }}
{{ if (eq $serviceName "clightning_groestlcoin_spark") }}

2
docker-compose-generator/docker-fragments/bitcoin-clightning.yml

@ -92,11 +92,13 @@ services:
BTCPAY_BTCEXTERNALSPARK: "server=/spark/btc/;cookiefile=/etc/clightning_bitcoin_spark/.cookie"
BTCPAY_BTCEXTERNALCHARGE: "server=/lightning-charge/btc/;cookiefilepath=/etc/clightning_bitcoin_charge/.cookie"
BTCPAY_BTCEXTERNALRTL: "server=/rtl/api/authenticate/cookie;cookiefile=/etc/clightning_bitcoin_rtl/.cookie"
BTCPAY_BTCEXTERNALCLIGHTNINGREST: "server=/clightning-rest/btc;macaroonfilepath=/etc/clightning_bitcoin_rest/certs/access.macaroon;macaroondirectorypath=/etc/clightning_bitcoin_rest/certs"
volumes:
- "clightning_bitcoin_datadir:/etc/clightning_bitcoin"
- "clightning_bitcoin_spark:/etc/clightning_bitcoin_spark"
- "clightning_bitcoin_charge:/etc/clightning_bitcoin_charge"
- "clightning_bitcoin_rtl_datadir:/etc/clightning_bitcoin_rtl"
- "clightning_bitcoin_rest_datadir:/etc/clightning_bitcoin_rest"
links:
- clightning_bitcoin
volumes:

Loading…
Cancel
Save