summaryrefslogtreecommitdiff
path: root/src/conf_mode/http-api.py
diff options
context:
space:
mode:
Diffstat (limited to 'src/conf_mode/http-api.py')
-rwxr-xr-xsrc/conf_mode/http-api.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/conf_mode/http-api.py b/src/conf_mode/http-api.py
index cd0191599..ea0743cd5 100755
--- a/src/conf_mode/http-api.py
+++ b/src/conf_mode/http-api.py
@@ -67,6 +67,12 @@ def get_config(config=None):
port = conf.return_value('port')
http_api['port'] = port
+ if conf.exists('cors'):
+ http_api['cors'] = {}
+ if conf.exists('cors allow-origin'):
+ origins = conf.return_values('cors allow-origin')
+ http_api['cors']['origins'] = origins[:]
+
if conf.exists('keys'):
for name in conf.list_nodes('keys id'):
if conf.exists('keys id {0} key'.format(name)):