Merge branch 'main' into 'main'

add static location for img

See merge request framasoft/mobilizon!1346
This commit is contained in:
Thomas Citharel 2023-08-18 13:54:21 +00:00
commit 64c28ec271
2 changed files with 14 additions and 0 deletions

View file

@ -75,6 +75,13 @@ server {
default_type "text/plain"; default_type "text/plain";
} }
location ~ ^/img {
root /opt/mobilizon/priv/static;
etag off;
access_log off;
add_header Cache-Control "public, max-age=31536000, immutable";
}
location ~ ^/(js|css) { location ~ ^/(js|css) {
root /opt/mobilizon/priv/static; root /opt/mobilizon/priv/static;
etag off; etag off;

View file

@ -75,6 +75,13 @@ server {
default_type "text/plain"; default_type "text/plain";
} }
location ~ ^/img {
root /opt/mobilizon/priv/static;
etag off;
access_log off;
add_header Cache-Control "public, max-age=31536000, immutable";
}
location ~ ^/(js|css) { location ~ ^/(js|css) {
root /home/mobilizon/live/priv/static; root /home/mobilizon/live/priv/static;
etag off; etag off;