mirror of
https://framagit.org/framasoft/peertube/search-index/
synced 2024-12-12 09:06:08 +01:00
Add nginx template
This commit is contained in:
parent
f5f63ca5f7
commit
83cec31a6c
35
support/nginx/peertube-search-index
Normal file
35
support/nginx/peertube-search-index
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
server {
|
||||||
|
listen 80;
|
||||||
|
listen [::]:80;
|
||||||
|
listen 443 ssl http2;
|
||||||
|
listen [::]:443 ssl http2;
|
||||||
|
server_name domain.tld;
|
||||||
|
|
||||||
|
access_log /var/log/nginx/peertube_search_index_access.log;
|
||||||
|
error_log /var/log/nginx/peertube_search_index_error.log;
|
||||||
|
|
||||||
|
ssl_certificate /etc/letsencrypt/live/domain.tld/fullchain.pem;
|
||||||
|
ssl_certificate_key /etc/letsencrypt/live/domain.tld/privkey.pem;
|
||||||
|
|
||||||
|
if ($scheme = http) {
|
||||||
|
return 301 https://$server_name$request_uri;
|
||||||
|
}
|
||||||
|
|
||||||
|
root /var/www/peertube-search-index;
|
||||||
|
|
||||||
|
location = / {
|
||||||
|
try_files /index.template.html =404;
|
||||||
|
}
|
||||||
|
|
||||||
|
location ^~ '/.well-known/acme-challenge' {
|
||||||
|
default_type "text/plain";
|
||||||
|
root /var/www/certbot;
|
||||||
|
}
|
||||||
|
|
||||||
|
location / {
|
||||||
|
proxy_pass http://localhost:3234;
|
||||||
|
proxy_set_header X-Real-IP $remote_addr;
|
||||||
|
proxy_set_header Host $host;
|
||||||
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user