-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathspidvid.cloudapp.net.conf
41 lines (34 loc) · 1.36 KB
/
spidvid.cloudapp.net.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
proxy_cache_path /tmp/nginx levels=1:2 keys_zone=spiddal_zone:1024m inactive=60m;
proxy_cache_key "$scheme$request_method$host$request_uri";
server {
## listen on
listen 80;
## host name to list for
server_name spidvid.cloudapp.net;
## Provide some extra information about the
## end user connection
##proxy_set_header Host $http_host;
proxy_set_header Host spiddal.marine.ie;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
## hint whether https is used to the end user
proxy_set_header X-Forwarded-Scheme $scheme;
location / {
proxy_cache spiddal_zone;
add_header X-Proxy-Cache $upstream_cache_status;
proxy_pass http://spiddal.marine.ie;
}
location ~* \.(m3u8|mpd|json)$ {
proxy_cache off; # Do not activate proxy cache (i.e m3u8,f4m,... playlist files)
expires -1; # Cache-Control: no-cache
proxy_pass http://spiddal.marine.ie;
}
location /nginx_status {
# Turn on stats
stub_status on;
access_log off;
# only allow access from marine institute
# allow 192.168.1.5;
# deny all;
}
}