Skip to content

Commit e365245

Browse files
authored
Merge branch 'master' into payment_qr_popup
2 parents 27bdfc1 + 590d73e commit e365245

File tree

10 files changed

+69
-4
lines changed

10 files changed

+69
-4
lines changed

.env.development

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -184,6 +184,7 @@ grpc_proxy=http://tor:7050/
184184

185185
# lnbits
186186
LNBITS_WEB_PORT=5001
187+
LNBITS_WEB_PORT_V1=5002
187188

188189
# CPU shares for each category
189190
CPU_SHARES_IMPORTANT=1024

awards.csv

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -233,5 +233,10 @@ brymut,pr,#2171,#2164,easy,,,,100k,[email protected],2025-05-21
233233
SouthKoreaLN,issue,#2171,#2164,easy,,,,10k,[email protected],2025-05-21
234234
brymut,pr,#2175,#2173,good-first-issue,,,,20k,[email protected],2025-05-21
235235
sutt,pr,#2185,#2183,easy,high,,,200k,[email protected],???
236-
sutt,issue,#2185,#2183,easy,high,,,20k,[email protected],???
237-
axelvyrn,advisory,GHSA-x2xp-x867-4jfc,,,,,100k,[email protected],???
236+
sutt,issue,#2185,#2183,easy,high,,,20k,[email protected],2025-06-06
237+
axelvyrn,advisory,#2205,GHSA-x2xp-x867-4jfc,,,,,100k,[email protected],2025-06-06
238+
brymut,pr,#2184,#2165,easy,,,,100k,[email protected],2025-06-06
239+
sutt,pr,#2190,#2187,easy,,,,100k,[email protected],2025-06-06
240+
sutt,issue,#2190,#2187,easy,,,,10k,[email protected],2025-06-06
241+
sutt,pr,#2192,#2188,medium,,,,250k,[email protected],???
242+
sutt,issue,#2192,#2188,medium,,,,25k,[email protected],???

docker-compose.yml

Lines changed: 33 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -356,7 +356,9 @@ services:
356356
ofelia.job-exec.sn_channel_cron.schedule: "@every 1m"
357357
ofelia.job-exec.sn_channel_cron.command: >
358358
su lnd -c bash -c "
359-
if [ $$(lncli getinfo | jq '.num_active_channels + .num_pending_channels') -ge 3 ]; then
359+
if [ $$(lncli getinfo | jq '.num_active_channels + .num_pending_channels') -ge 6 ]; then
360+
exit 0
361+
elif [ $$(lncli listchannels --peer=$ROUTER_LND_PUBKEY | jq '.channels | length') -ge 3 ]; then
360362
exit 0
361363
else
362364
lncli openchannel --node_key=$ROUTER_LND_PUBKEY --connect router_lnd:9735 --sat_per_vbyte 1 \\
@@ -809,6 +811,36 @@ services:
809811
CONNECT: "localhost:${LNBITS_WEB_PORT}"
810812
TORDIR: "/app/.tor"
811813
cpu_shares: "${CPU_SHARES_LOW}"
814+
lnbits-v1:
815+
build:
816+
context: ./docker/lnbits-v1
817+
container_name: lnbits-v1
818+
profiles:
819+
- wallets
820+
restart: unless-stopped
821+
ports:
822+
- "${LNBITS_WEB_PORT_V1}:5000"
823+
depends_on:
824+
tor:
825+
condition: service_healthy
826+
restart: true
827+
lnd:
828+
condition: service_healthy
829+
restart: true
830+
environment:
831+
- LNBITS_ADMIN_UI=true
832+
- LNBITS_BACKEND_WALLET_CLASS=LndWallet
833+
- LND_GRPC_ENDPOINT=lnd
834+
- LND_GRPC_PORT=10009
835+
- LND_GRPC_CERT=/app/.lnd/tls.cert
836+
- LND_GRPC_MACAROON=/app/.lnd/data/chain/bitcoin/regtest/admin.macaroon
837+
volumes:
838+
- lnd:/app/.lnd
839+
- tordata:/app/.tor
840+
labels:
841+
CONNECT: "localhost:${LNBITS_WEB_PORT_V1}"
842+
TORDIR: "/app/.tor"
843+
cpu_shares: "${CPU_SHARES_LOW}"
812844
dnsmasq:
813845
image: 4km3/dnsmasq:2.90-r3
814846
profiles:

docker/lnbits-v1/Dockerfile

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
FROM lnbits/lnbits:latest
2+
3+
4+
COPY ["./data/database.sqlite3", "/app/data/database.sqlite3"]
5+
COPY ["./data/.super_user", "/app/data/.super_user"]

docker/lnbits-v1/data/.super_user

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
e46288268b67457399a5fca81809573e
100 KB
Binary file not shown.

docker/lnd/router/regtest/wallet.db

0 Bytes
Binary file not shown.

docker/lnd/stacker/tls.cert

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
-----BEGIN CERTIFICATE-----
2+
MIIChTCCAiugAwIBAgIRAJyfH7pGCdHWMRYTj5wZJJAwCgYIKoZIzj0EAwIwODEf
3+
MB0GA1UEChMWbG5kIGF1dG9nZW5lcmF0ZWQgY2VydDEVMBMGA1UEAxMMMGUyOGU4
4+
ODI3NjYwMB4XDTI1MDYwNTE4MjMyNloXDTI2MDczMTE4MjMyNlowODEfMB0GA1UE
5+
ChMWbG5kIGF1dG9nZW5lcmF0ZWQgY2VydDEVMBMGA1UEAxMMMGUyOGU4ODI3NjYw
6+
MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEPMeodXa1vyuqaqZ6IWmx+45Ev0dR
7+
fBF9Ivm1NqASGPiFORnpKqePUnm1ZfeMCDO+pphP0zFaXxePTSppic+ayKOCARQw
8+
ggEQMA4GA1UdDwEB/wQEAwICpDATBgNVHSUEDDAKBggrBgEFBQcDATAPBgNVHRMB
9+
Af8EBTADAQH/MB0GA1UdDgQWBBTbGJ2VCz3yZATwRePmdrGo2xdVajCBuAYDVR0R
10+
BIGwMIGtggwwZTI4ZTg4Mjc2NjCCCWxvY2FsaG9zdIIDbG5kghRob3N0LmRvY2tl
11+
ci5pbnRlcm5hbII+NzUyeGV5b2xmcHBjMnRnZ2l6ZHFhamJoeWdscG5xemtlamVj
12+
YmhxbHBzM254enZ0c2g3d2FtcWQub25pb26CBHVuaXiCCnVuaXhwYWNrZXSCB2J1
13+
ZmNvbm6HBH8AAAGHEAAAAAAAAAAAAAAAAAAAAAGHBKwSAAcwCgYIKoZIzj0EAwID
14+
SAAwRQIgcjYgj9aXiB9N9PfAJtqfQm+haWinftE5WvBwV+8783MCIQCrhLvC+7G4
15+
7sgxCrbyf//VvlI7pdjDeTS4Xg8xpvReDA==
16+
-----END CERTIFICATE-----

docker/lnd/stacker/tls.key

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
-----BEGIN EC PRIVATE KEY-----
2+
MHcCAQEEINsmkDkccjFM+Yzi2LgZsaIHc6LBFZihEnBLnte6h2f9oAoGCCqGSM49
3+
AwEHoUQDQgAEPMeodXa1vyuqaqZ6IWmx+45Ev0dRfBF9Ivm1NqASGPiFORnpKqeP
4+
Unm1ZfeMCDO+pphP0zFaXxePTSppic+ayA==
5+
-----END EC PRIVATE KEY-----

wallets/lnbits/server.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ export async function createInvoice (
3838

3939
if (process.env.NODE_ENV !== 'production' && hostname.startsWith('localhost:')) {
4040
// to make it possible to attach LNbits for receives during local dev
41-
hostname = 'lnbits:5000'
41+
hostname = hostname === `localhost:${process.env.LNBITS_WEB_PORT}` ? 'lnbits:5000' : 'lnbits-v1:5000'
4242
}
4343

4444
let res

0 commit comments

Comments
 (0)