Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- proxy_cache_path /home4/cache keys_zone=disk_cache:5m levels=1:2 inactive=24h max_size=80G;
- server {
- server_name videos.demo.com;
- root /home/nginx/domains/videos.demo.com/public;
- location / {
- proxy_cache disk_cache;
- }
- location ~ .mp4$ {
- proxy_cache disk_cache;
- proxy_cache_key "$host$request_uri";
- proxy_cache_min_uses 1;
- proxy_cache_methods GET HEAD;
- expires 365d;
- add_header Cache-Control "public, no-transform";
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement