mirror of
https://github.com/aljazceru/btcpayserver.git
synced 2025-12-17 14:04:26 +01:00
Add Lightning Service Torq (#4296)
This commit is contained in:
@@ -77,7 +77,8 @@ namespace BTCPayServer.Configuration
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (new[] { ExternalServiceTypes.Charge, ExternalServiceTypes.RTL, ExternalServiceTypes.ThunderHub, ExternalServiceTypes.Spark, ExternalServiceTypes.Configurator }.Contains(serviceType))
|
if (new[] { ExternalServiceTypes.Charge, ExternalServiceTypes.RTL, ExternalServiceTypes.ThunderHub,
|
||||||
|
ExternalServiceTypes.Spark, ExternalServiceTypes.Configurator, ExternalServiceTypes.Torq }.Contains(serviceType))
|
||||||
{
|
{
|
||||||
// Read access key from cookie file
|
// Read access key from cookie file
|
||||||
if (connectionString.CookieFilePath != null)
|
if (connectionString.CookieFilePath != null)
|
||||||
@@ -97,7 +98,8 @@ namespace BTCPayServer.Configuration
|
|||||||
}
|
}
|
||||||
connectionString.CookieFilePath = null;
|
connectionString.CookieFilePath = null;
|
||||||
|
|
||||||
if (serviceType == ExternalServiceTypes.RTL || serviceType == ExternalServiceTypes.Configurator || serviceType == ExternalServiceTypes.ThunderHub)
|
if (serviceType == ExternalServiceTypes.RTL || serviceType == ExternalServiceTypes.Configurator ||
|
||||||
|
serviceType == ExternalServiceTypes.ThunderHub || serviceType == ExternalServiceTypes.Torq)
|
||||||
{
|
{
|
||||||
connectionString.AccessKey = cookieFileContent;
|
connectionString.AccessKey = cookieFileContent;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -36,6 +36,10 @@ namespace BTCPayServer.Configuration
|
|||||||
$"Valid example: 'server=https://btcpay.example.com/rtl/btc/;cookiefile=/etc/clightning_bitcoin_rtl/.cookie'" + Environment.NewLine +
|
$"Valid example: 'server=https://btcpay.example.com/rtl/btc/;cookiefile=/etc/clightning_bitcoin_rtl/.cookie'" + Environment.NewLine +
|
||||||
"Error: {1}",
|
"Error: {1}",
|
||||||
"Ride The Lightning");
|
"Ride The Lightning");
|
||||||
|
Load(configuration, cryptoCode, "torq", ExternalServiceTypes.Torq, "Invalid setting {0}, " + Environment.NewLine +
|
||||||
|
$"Valid example: 'server=https://btcpay.example.com/torq/cookie-login/;cookiefile=/etc/lnd_bitcoin_rtl/.cookie'" + Environment.NewLine +
|
||||||
|
"Error: {1}",
|
||||||
|
"Torq");
|
||||||
Load(configuration, cryptoCode, "thunderhub", ExternalServiceTypes.ThunderHub, "Invalid setting {0}, " + Environment.NewLine +
|
Load(configuration, cryptoCode, "thunderhub", ExternalServiceTypes.ThunderHub, "Invalid setting {0}, " + Environment.NewLine +
|
||||||
$"Valid example: 'server=https://btcpay.example.com/thub/;cookiefile=/etc/clightning_bitcoin_rtl/.cookie'" + Environment.NewLine +
|
$"Valid example: 'server=https://btcpay.example.com/thub/;cookiefile=/etc/clightning_bitcoin_rtl/.cookie'" + Environment.NewLine +
|
||||||
"Error: {1}",
|
"Error: {1}",
|
||||||
@@ -93,7 +97,8 @@ namespace BTCPayServer.Configuration
|
|||||||
{
|
{
|
||||||
ExternalServiceTypes.Spark,
|
ExternalServiceTypes.Spark,
|
||||||
ExternalServiceTypes.RTL,
|
ExternalServiceTypes.RTL,
|
||||||
ExternalServiceTypes.ThunderHub
|
ExternalServiceTypes.ThunderHub,
|
||||||
|
ExternalServiceTypes.Torq
|
||||||
};
|
};
|
||||||
|
|
||||||
public static readonly string[] LightningServiceNames =
|
public static readonly string[] LightningServiceNames =
|
||||||
@@ -130,6 +135,7 @@ namespace BTCPayServer.Configuration
|
|||||||
P2P,
|
P2P,
|
||||||
RPC,
|
RPC,
|
||||||
Configurator,
|
Configurator,
|
||||||
CLightningRest
|
CLightningRest,
|
||||||
|
Torq
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -512,6 +512,7 @@ namespace BTCPayServer.Controllers
|
|||||||
case ExternalServiceTypes.RTL:
|
case ExternalServiceTypes.RTL:
|
||||||
case ExternalServiceTypes.ThunderHub:
|
case ExternalServiceTypes.ThunderHub:
|
||||||
case ExternalServiceTypes.Spark:
|
case ExternalServiceTypes.Spark:
|
||||||
|
case ExternalServiceTypes.Torq:
|
||||||
if (connectionString.AccessKey == null)
|
if (connectionString.AccessKey == null)
|
||||||
{
|
{
|
||||||
TempData[WellKnownTempData.ErrorMessage] = $"The access key of the service is not set";
|
TempData[WellKnownTempData.ErrorMessage] = $"The access key of the service is not set";
|
||||||
|
|||||||
@@ -13,6 +13,7 @@
|
|||||||
"BTCPAY_BTCEXTERNALCHARGE": "server=https://127.0.0.1:53280/mycharge/btc/;cookiefilepath=fake",
|
"BTCPAY_BTCEXTERNALCHARGE": "server=https://127.0.0.1:53280/mycharge/btc/;cookiefilepath=fake",
|
||||||
"BTCPAY_BTCEXTERNALRTL": "server=/rtl/api/authenticate/cookie;cookiefile=fake",
|
"BTCPAY_BTCEXTERNALRTL": "server=/rtl/api/authenticate/cookie;cookiefile=fake",
|
||||||
"BTCPAY_BTCEXTERNALTHUNDERHUB": "server=/thub/sso;cookiefile=fake",
|
"BTCPAY_BTCEXTERNALTHUNDERHUB": "server=/thub/sso;cookiefile=fake",
|
||||||
|
"BTCPAY_BTCEXTERNALTORQ": "server=/torq/cookie-login;cookiefile=fake",
|
||||||
"BTCPAY_EXTERNALSERVICES": "totoservice:totolink;Lightning Terminal:/lit/;",
|
"BTCPAY_EXTERNALSERVICES": "totoservice:totolink;Lightning Terminal:/lit/;",
|
||||||
"BTCPAY_BTCEXPLORERURL": "http://127.0.0.1:32838/",
|
"BTCPAY_BTCEXPLORERURL": "http://127.0.0.1:32838/",
|
||||||
"BTCPAY_ALLOW-ADMIN-REGISTRATION": "true",
|
"BTCPAY_ALLOW-ADMIN-REGISTRATION": "true",
|
||||||
@@ -48,6 +49,7 @@
|
|||||||
"BTCPAY_BTCEXTERNALCHARGE": "server=https://127.0.0.1:53280/mycharge/btc/;cookiefilepath=fake",
|
"BTCPAY_BTCEXTERNALCHARGE": "server=https://127.0.0.1:53280/mycharge/btc/;cookiefilepath=fake",
|
||||||
"BTCPAY_BTCEXTERNALRTL": "server=/rtl/api/authenticate/cookie;cookiefile=fake",
|
"BTCPAY_BTCEXTERNALRTL": "server=/rtl/api/authenticate/cookie;cookiefile=fake",
|
||||||
"BTCPAY_BTCEXTERNALTHUNDERHUB": "server=/thub/sso;cookiefile=fake",
|
"BTCPAY_BTCEXTERNALTHUNDERHUB": "server=/thub/sso;cookiefile=fake",
|
||||||
|
"BTCPAY_BTCEXTERNALTORQ": "server=/torq/cookie-login;cookiefile=fake",
|
||||||
"BTCPAY_EXTERNALSERVICES": "totoservice:totolink;Lightning Terminal:/lit/;",
|
"BTCPAY_EXTERNALSERVICES": "totoservice:totolink;Lightning Terminal:/lit/;",
|
||||||
"BTCPAY_EXTERNALCONFIGURATOR": "passwordfile=testpwd;server=/configurator",
|
"BTCPAY_EXTERNALCONFIGURATOR": "passwordfile=testpwd;server=/configurator",
|
||||||
"BTCPAY_BTCEXPLORERURL": "http://127.0.0.1:32838/",
|
"BTCPAY_BTCEXPLORERURL": "http://127.0.0.1:32838/",
|
||||||
@@ -86,6 +88,7 @@
|
|||||||
"BTCPAY_BTCEXTERNALCHARGE": "server=https://127.0.0.1:53280/mycharge/btc/;cookiefilepath=fake",
|
"BTCPAY_BTCEXTERNALCHARGE": "server=https://127.0.0.1:53280/mycharge/btc/;cookiefilepath=fake",
|
||||||
"BTCPAY_BTCEXTERNALRTL": "server=/rtl/api/authenticate/cookie;cookiefile=fake",
|
"BTCPAY_BTCEXTERNALRTL": "server=/rtl/api/authenticate/cookie;cookiefile=fake",
|
||||||
"BTCPAY_BTCEXTERNALTHUNDERHUB": "server=/thub/sso;cookiefile=fake",
|
"BTCPAY_BTCEXTERNALTHUNDERHUB": "server=/thub/sso;cookiefile=fake",
|
||||||
|
"BTCPAY_BTCEXTERNALTORQ": "server=/torq/cookie-login;cookiefile=fake",
|
||||||
"BTCPAY_EXTERNALSERVICES": "totoservice:totolink;Lightning Terminal:/lit/;",
|
"BTCPAY_EXTERNALSERVICES": "totoservice:totolink;Lightning Terminal:/lit/;",
|
||||||
"BTCPAY_EXTERNALCONFIGURATOR": "passwordfile=testpwd;server=/configurator",
|
"BTCPAY_EXTERNALCONFIGURATOR": "passwordfile=testpwd;server=/configurator",
|
||||||
"BTCPAY_BTCEXPLORERURL": "http://127.0.0.1:32838/",
|
"BTCPAY_BTCEXPLORERURL": "http://127.0.0.1:32838/",
|
||||||
|
|||||||
BIN
BTCPayServer/wwwroot/img/torq.png
Normal file
BIN
BTCPayServer/wwwroot/img/torq.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 5.1 KiB |
Reference in New Issue
Block a user