summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--files/common/nginx-snippets/hsts.conf (renamed from roles/elevate/media/files/nginx-snippets/hsts.conf)0
-rw-r--r--files/common/nginx-snippets/proxy-nobuff.conf4
-rw-r--r--files/common/nginx-snippets/security-headers.conf4
-rw-r--r--files/common/nginx-snippets/ssl.conf (renamed from roles/elevate/media/files/nginx-snippets/ssl.conf)0
-rw-r--r--roles/elevate/media/tasks/nginx.yml2
5 files changed, 9 insertions, 1 deletions
diff --git a/roles/elevate/media/files/nginx-snippets/hsts.conf b/files/common/nginx-snippets/hsts.conf
index 4ca8396e..4ca8396e 100644
--- a/roles/elevate/media/files/nginx-snippets/hsts.conf
+++ b/files/common/nginx-snippets/hsts.conf
diff --git a/files/common/nginx-snippets/proxy-nobuff.conf b/files/common/nginx-snippets/proxy-nobuff.conf
new file mode 100644
index 00000000..b08de70c
--- /dev/null
+++ b/files/common/nginx-snippets/proxy-nobuff.conf
@@ -0,0 +1,4 @@
+proxy_buffering off;
+proxy_ignore_headers "X-Accel-Buffering";
+proxy_request_buffering off;
+proxy_http_version 1.1;
diff --git a/files/common/nginx-snippets/security-headers.conf b/files/common/nginx-snippets/security-headers.conf
new file mode 100644
index 00000000..b94d479d
--- /dev/null
+++ b/files/common/nginx-snippets/security-headers.conf
@@ -0,0 +1,4 @@
+add_header X-Frame-Options DENY;
+add_header X-Content-Type-Options nosniff;
+add_header X-XSS-Protection "1; mode=block";
+# add_header Content-Security-Policy "default-src 'none'; connect-src 'self'; img-src 'self'; script-src 'self'; style-src 'self'";
diff --git a/roles/elevate/media/files/nginx-snippets/ssl.conf b/files/common/nginx-snippets/ssl.conf
index d187a7c0..d187a7c0 100644
--- a/roles/elevate/media/files/nginx-snippets/ssl.conf
+++ b/files/common/nginx-snippets/ssl.conf
diff --git a/roles/elevate/media/tasks/nginx.yml b/roles/elevate/media/tasks/nginx.yml
index fd1ed888..2441872a 100644
--- a/roles/elevate/media/tasks/nginx.yml
+++ b/roles/elevate/media/tasks/nginx.yml
@@ -9,7 +9,7 @@
- name: install nginx config snippets
copy:
- src: "nginx-snippets/{{ item }}.conf"
+ src: "{{ global_files_dir }}/common/nginx-snippets/{{ item }}.conf"
dest: /etc/nginx/snippets/
with_items:
- ssl