From d204666d4807213a5875982adeeda9df1c363b82 Mon Sep 17 00:00:00 2001 From: ThisBirchWood Date: Fri, 28 Feb 2025 20:35:03 +0000 Subject: [PATCH] UPDATE: Reinstated thumbnail, vod routes in NGINX, and added a profile picture route --- nginx/nginx.conf | 33 ++++++++++++++++++++------------- 1 file changed, 20 insertions(+), 13 deletions(-) diff --git a/nginx/nginx.conf b/nginx/nginx.conf index 3e5ddf0..954bb80 100644 --- a/nginx/nginx.conf +++ b/nginx/nginx.conf @@ -93,22 +93,29 @@ http { expires -1d; } - #! Unused right now so the following are inaccurate locations - # The thumbnails location - # location ~ ^/stream/(.+)/thumbnails/(.+\.jpg)$ { - # alias /stream_data/$1/thumbnails/$2; + ## The thumbnails location + location ~ ^/stream/(.+)/thumbnails/(.+\.png)$ { + alias /stream_data/stream/$1/$2; - # # The thumbnails should not be cacheable - # expires -1d; - # } + # The thumbnails should not be cacheable + expires -1d; + } - # # The vods location - # location ~ ^/stream/(.+)/vods/(.+\.mp4)$ { - # alias /stream_data/$1/vods/$2; + ## The vods location + location ~ ^/stream/(.+)/vods/(.+\.mp4)$ { + alias /stream_data/vods/$1/$2; - # # The vods should not be cacheable - # expires -1d; - # } + # The vods should not be cacheable + expires -1d; + } + + ## Profile pictures location + location ~ ^/user/(.+)/profile_picture$ { + alias /stream_data/profile_pictures/$1.png; + + # The profile pictures should not be cacheable + expires -1d; + } # location ~ ^/\?token=.*$ { # proxy_pass http://frontend:5173;