-
Notifications
You must be signed in to change notification settings - Fork 3
/
patch
35 lines (32 loc) · 1.08 KB
/
patch
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
diff --git a/adama/service.py b/adama/service.py
index 5acf49d..c59cfa5 100644
--- a/adama/service.py
+++ b/adama/service.py
@@ -114,7 +114,8 @@ class AbstractService(object):
('metadata', False, METADATA_DEFAULT),
('timeout', False, 30),
# private fields (not to be displayed)
- ('_icon', False, None)
+ ('_icon', False, None),
+ ('_no_firewall', False, None)
]
def __init__(self, **kwargs):
@@ -322,7 +323,8 @@ class Service(AbstractService):
self.iden,
'--adapter-type',
self.type)
- allow(worker, self.whitelist)
+ if not getattr(self, '_no_firewall', False):
+ allow(worker, self.whitelist)
docker_output('exec', worker, 'touch', '/ready')
return worker
diff --git a/adama/stores.py b/adama/stores.py
index 10224d9..231a71a 100644
--- a/adama/stores.py
+++ b/adama/stores.py
@@ -16,5 +16,6 @@ prov_store = config_store(db=6)
stats_store = config_store(db=7)
debug_store = config_store(db=8)
+
# Reserve gateway ip: 172.17.42.1
ip_pool[(42, 1)] = True