Files
mindboost-media-server/nginx/conf.d/default.conf

32 lines
783 B
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

server {
listen 80;
server_name localhost;
# Where your assets live
root /usr/share/nginx/html;
index index.html;
# ---------- Default site (HTML/CSS/JS) ----------
location / {
try_files $uri $uri/ =404;
}
# ---------- Audio (and optional video) ----------
# 30-day cache; adjust max-age as needed.
location ~* \.(opus|flac|ogg|mp3|wav|m4a|aac)$ {
add_header Cache-Control "public, max-age=2592000" always;
# Teach Nginx any MIME types it doesnt already know:
types {
audio/opus opus;
audio/mpeg mp3;
audio/mp4 m4a;
audio/aac aac;
video/mp4 mp4;
video/webm webm;
}
try_files $uri =404;
}
}