aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMilo Casagrande <milo.casagrande@linaro.org>2015-05-13 09:49:06 +0200
committerMilo Casagrande <milo.casagrande@linaro.org>2015-05-13 09:49:06 +0200
commitb9865561e0a6c6e3108f2905c4091a4bdf22ce4f (patch)
treef35b67ef78e69cb8252cdd1546e2c9ffbaf339f3
parentbb818f250195327320eeadfac63461a4252b4e55 (diff)
ansible: Fix nginx config.2015.5.1
* Move location definitions after the APIs one.
-rw-r--r--ansible/roles/configure-nginx/templates/backend-nginx.conf34
1 files changed, 17 insertions, 17 deletions
diff --git a/ansible/roles/configure-nginx/templates/backend-nginx.conf b/ansible/roles/configure-nginx/templates/backend-nginx.conf
index 9504de4..3c62506 100644
--- a/ansible/roles/configure-nginx/templates/backend-nginx.conf
+++ b/ansible/roles/configure-nginx/templates/backend-nginx.conf
@@ -27,28 +27,11 @@ server {
index index.html;
}
- location /json-schema {
- alias {{ web_root }}/{{ hostname }}/schema/;
-
- fancyindex on;
- fancyindex_exact_size off;
-
- expires 15d;
- add_header Pragma public;
- add_header Cache-Control "public";
- }
-
error_page 503 @maintenance;
location @maintenance {
rewrite ^(.*)$ /maintenance.html break;
}
- location ~* \.(?:ico|css|js|gif|jpe?g|png|svg)$ {
- expires 150d;
- add_header Pragma public;
- add_header Cache-Control "public";
- }
-
location ~* /(?:(count|jobs?|defconfigs?|boots?|tokens?|batch|bisect|labs?|version|reports?|send|upload|tests?|trigger)(.*)(?!(\.(html?|json|css|js|png|jpe?g|ico|svg))))$ {
if (-f $document_root/maintenance.html) {
@@ -80,4 +63,21 @@ server {
proxy_read_timeout 9s;
proxy_pass http://backends;
}
+
+ location /json-schema {
+ alias {{ web_root }}/{{ hostname }}/schema/;
+
+ fancyindex on;
+ fancyindex_exact_size off;
+
+ expires 15d;
+ add_header Pragma public;
+ add_header Cache-Control "public";
+ }
+
+ location ~* \.(?:ico|css|js|gif|jpe?g|png|svg)$ {
+ expires 150d;
+ add_header Pragma public;
+ add_header Cache-Control "public";
+ }
}