diff --git a/MafiAStarLite/MafiAStarLite b/MafiAStarLite/MafiAStarLite index 37bcfeb..4421e6a 160000 --- a/MafiAStarLite/MafiAStarLite +++ b/MafiAStarLite/MafiAStarLite @@ -1 +1 @@ -Subproject commit 37bcfeb64e285bbb3516076f885cc28894321139 +Subproject commit 4421e6aa21cbc5237f706874d76404d075a7cdb3 diff --git a/MafiAStarLite/nginx.conf b/MafiAStarLite/nginx.conf index a092a52..74ded8f 100644 --- a/MafiAStarLite/nginx.conf +++ b/MafiAStarLite/nginx.conf @@ -1,5 +1,7 @@ # vim: set filetype=conf: +proxy_cache_path /tmp/nginx_cache levels=1:2 keys_zone=images:10m inactive=30d max_size=1g; + server { listen 80; server_name default_server; @@ -17,8 +19,22 @@ server { uwsgi_pass 127.0.0.1:3008; } - location /songs_internal { + location /songs_internal/ { internal; - alias /app/songs; + proxy_pass http://127.0.0.1:8888; + proxy_cache images; + proxy_cache_valid 200 30d; + } +} + +server { + listen 8888; + server_name default_server; + + location /songs_internal/ { + alias /app/songs/; + image_filter resize 256 -; + image_filter_jpeg_quality 90; + image_filter_buffer 20M; } }