@@ -6,7 +6,7 @@ class PortPublish:
6
6
def __init__ (self , value ):
7
7
p1 = re .compile (r"^(\d+)$" ) # 8080
8
8
p2 = re .compile (r"^(\d+):(\d+)$" ) # 80:8080
9
- p3 = re .compile (r"^(\d +):(\d+):(\d+)$" ) # 127.0.0.1:80:8080
9
+ p3 = re .compile (r"^(. +):(\d+):(\d+)$" ) # 127.0.0.1:80:8080
10
10
11
11
protocol = "tcp"
12
12
if "/" in value :
@@ -35,6 +35,8 @@ def __init__(self, value):
35
35
host = m .group (1 )
36
36
host_port = int (m .group (2 ))
37
37
port = int (m .group (3 ))
38
+ else :
39
+ raise FatalError ("Invalid port publish: {}" .format (value ))
38
40
39
41
self .protocol = protocol
40
42
self .host = host
@@ -152,12 +154,28 @@ def __str__(self):
152
154
"name" : "proxy" ,
153
155
"image" : "exchangeunion/proxy:latest" ,
154
156
"volumes" : [
157
+ {
158
+ "host" : "/var/run/docker.sock" ,
159
+ "container" : "/var/run/docker.sock" ,
160
+ },
161
+ {
162
+ "host" : "$logs_dir/config.sh" ,
163
+ "container" : "/root/config.sh" ,
164
+ },
155
165
{
156
166
"host" : "$data_dir/xud" ,
157
167
"container" : "/root/.xud" ,
158
- }
168
+ },
169
+ {
170
+ "host" : "$data_dir/lndbtc" ,
171
+ "container" : "/root/.lndbtc" ,
172
+ },
173
+ {
174
+ "host" : "$data_dir/lndltc" ,
175
+ "container" : "/root/.lndltc" ,
176
+ },
159
177
],
160
- "ports" : [PortPublish ("28889:8080" )],
178
+ "ports" : [PortPublish ("127.0.0.1: 28889:8080" )],
161
179
"mode" : "native" ,
162
180
"preserve_config" : False ,
163
181
"use_local_image" : False ,
@@ -354,12 +372,29 @@ def __str__(self):
354
372
"name" : "proxy" ,
355
373
"image" : "exchangeunion/proxy:latest" ,
356
374
"volumes" : [
375
+ {
376
+ "host" : "/var/run/docker.sock" ,
377
+ "container" : "/var/run/docker.sock" ,
378
+ },
379
+ {
380
+ "host" : "$logs_dir/config.sh" ,
381
+ "container" : "/root/config.sh" ,
382
+ },
357
383
{
358
384
"host" : "$data_dir/xud" ,
359
385
"container" : "/root/.xud" ,
360
- }
386
+ },
387
+ {
388
+ "host" : "$data_dir/lndbtc" ,
389
+ "container" : "/root/.lndbtc" ,
390
+ },
391
+ {
392
+ "host" : "$data_dir/lndltc" ,
393
+ "container" : "/root/.lndltc" ,
394
+ },
395
+
361
396
],
362
- "ports" : [PortPublish ("18889:8080" )],
397
+ "ports" : [PortPublish ("127.0.0.1: 18889:8080" )],
363
398
"mode" : "native" ,
364
399
"preserve_config" : False ,
365
400
"use_local_image" : False ,
@@ -555,12 +590,28 @@ def __str__(self):
555
590
"name" : "proxy" ,
556
591
"image" : "exchangeunion/proxy:latest" ,
557
592
"volumes" : [
593
+ {
594
+ "host" : "/var/run/docker.sock" ,
595
+ "container" : "/var/run/docker.sock" ,
596
+ },
597
+ {
598
+ "host" : "$logs_dir/config.sh" ,
599
+ "container" : "/root/config.sh" ,
600
+ },
558
601
{
559
602
"host" : "$data_dir/xud" ,
560
603
"container" : "/root/.xud" ,
561
- }
604
+ },
605
+ {
606
+ "host" : "$data_dir/lndbtc" ,
607
+ "container" : "/root/.lndbtc" ,
608
+ },
609
+ {
610
+ "host" : "$data_dir/lndltc" ,
611
+ "container" : "/root/.lndltc" ,
612
+ },
562
613
],
563
- "ports" : [PortPublish ("8889:8080" )],
614
+ "ports" : [PortPublish ("127.0.0.1: 8889:8080" )],
564
615
"mode" : "native" ,
565
616
"preserve_config" : False ,
566
617
"use_local_image" : False ,
0 commit comments