summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohannes Löthberg <johannes@kyriasis.com>2019-03-21 20:10:52 +0100
committerJohannes Löthberg <johannes@kyriasis.com>2019-03-21 20:10:52 +0100
commit7b258b6fc1ae8c5dc68e0195dd499e3dcc55f56e (patch)
tree5bb7e8cb74eb7f794ff03c93322d4920234f7e6f
parent3b46f5df3f283b424075d84c112eb1eac8e39e61 (diff)
downloadpillar-7b258b6fc1ae8c5dc68e0195dd499e3dcc55f56e.tar.xz
Add CORS
Signed-off-by: Johannes Löthberg <johannes@kyriasis.com>
-rw-r--r--nginx/kyriasis_com.sls5
-rw-r--r--nginx/matrix_kyriasis_com.sls3
2 files changed, 7 insertions, 1 deletions
diff --git a/nginx/kyriasis_com.sls b/nginx/kyriasis_com.sls
index 58c5ddc..c04a806 100644
--- a/nginx/kyriasis_com.sls
+++ b/nginx/kyriasis_com.sls
@@ -47,6 +47,9 @@ nginx:
# http://www.gnuterrypratchett.com/
- add_header: 'X-Clacks-Overhead "GNU Terry Pratchett"'
+ - add_header: 'Access-Control-Allow-Origin' '*';
+ - add_header: 'Access-Control-Allow-Methods' 'GET, PUT, POST, DELETE, HEAD, OPTIONS';
+
- client_max_body_size: 128m
- error_log: /var/log/nginx/kyriasis.com.error.log
@@ -59,5 +62,5 @@ nginx:
- proxy_buffering: "off"
- proxy_set_header: X-Forwarded-For $remote_addr
- proxy_set_header: Host $host
-
+ #
# vim: ft=yaml et:
diff --git a/nginx/matrix_kyriasis_com.sls b/nginx/matrix_kyriasis_com.sls
index c6f6cda..d9897de 100644
--- a/nginx/matrix_kyriasis_com.sls
+++ b/nginx/matrix_kyriasis_com.sls
@@ -51,6 +51,9 @@ nginx:
# http://www.gnuterrypratchett.com/
- add_header: 'X-Clacks-Overhead "GNU Terry Pratchett"'
+ - add_header: 'Access-Control-Allow-Origin' '*';
+ - add_header: 'Access-Control-Allow-Methods' 'GET, PUT, POST, DELETE, HEAD, OPTIONS';
+
- client_max_body_size: 128m
- error_log: /var/log/nginx/matrix.error.log