summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--debian/nginx-example.conf12
1 files changed, 9 insertions, 3 deletions
diff --git a/debian/nginx-example.conf b/debian/nginx-example.conf
index 16a3832..bd8283b 100644
--- a/debian/nginx-example.conf
+++ b/debian/nginx-example.conf
@@ -9,14 +9,20 @@ server {
access_log /var/log/nginx/u-auth.example.org-access.log combined;
error_log /var/log/nginx/u-auth.example.org-error.log;
- location ~ ^(.*)/static/(.+)$ {
+ location ~ ^/([^/]*)/static/(.+)$ {
root /;
try_files /var/lib/u-auth/organizations/$1/static/$2
- /var/lib/u-auth/static/$2
- /var/lib/u-auth/collectstatic/$2
=404;
}
+ location ~ ^/static/(.+) {
+ root /;
+ try_files /var/lib/u-auth/static/$1
+ /var/lib/u-auth/collectstatic/$1
+ =404;
+ }
+
+
location ~ ^/media/(.+)$ {
alias /var/lib/u-auth/media/$1;
}