immich
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
- name: Nginx
|
||||
hosts: pi
|
||||
hosts: beepi
|
||||
become: true
|
||||
tasks:
|
||||
- name: Install nginx
|
||||
@@ -20,7 +20,7 @@
|
||||
group: root
|
||||
mode: '0644'
|
||||
|
||||
- name: Copy upstreamc.onf
|
||||
- name: Copy upstream.conf
|
||||
ansible.builtin.copy:
|
||||
src: upstream.conf
|
||||
dest: /etc/nginx/conf.d/upstream.conf
|
||||
|
||||
@@ -0,0 +1,52 @@
|
||||
server {
|
||||
listen 80;
|
||||
server_name gallery.secretbee.buzz;
|
||||
|
||||
location / {
|
||||
return 301 https://$host$request_uri;
|
||||
}
|
||||
}
|
||||
|
||||
server {
|
||||
listen 443 ssl;
|
||||
server_name gallery.secretbee.buzz;
|
||||
|
||||
ssl_certificate /etc/letsencrypt/live/gallery.secretbee.buzz/fullchain.pem;
|
||||
ssl_certificate_key /etc/letsencrypt/live/gallery.secretbee.buzz/privkey.pem;
|
||||
ssl_protocols TLSv1.2 TLSv1.3;
|
||||
ssl_ciphers HIGH:!aNULL:!MD5;
|
||||
|
||||
# allow large file uploads
|
||||
client_max_body_size 50000M;
|
||||
|
||||
# disable buffering uploads to prevent OOM on reverse proxy server and make uploads twice as fast (no pause)
|
||||
proxy_request_buffering off;
|
||||
|
||||
# increase body buffer to avoid limiting upload speed
|
||||
client_body_buffer_size 1024k;
|
||||
|
||||
# Set headers
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Forwarded-Proto $scheme;
|
||||
|
||||
# enable websockets: http://nginx.org/en/docs/http/websocket.html
|
||||
proxy_http_version 1.1;
|
||||
proxy_redirect off;
|
||||
|
||||
# set timeout
|
||||
proxy_read_timeout 600s;
|
||||
proxy_send_timeout 600s;
|
||||
send_timeout 600s;
|
||||
|
||||
location / {
|
||||
proxy_pass http://localhost:2283;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection "upgrade";
|
||||
}
|
||||
|
||||
location /siri {
|
||||
return 301 https://gallery.secretbee.buzz/s/siri;
|
||||
}
|
||||
}
|
||||
@@ -49,4 +49,8 @@ server {
|
||||
default_type "text/html";
|
||||
try_files $uri $uri.html $uri/index.html index.html;
|
||||
}
|
||||
|
||||
location /siri {
|
||||
return 301 https://gallery.secretbee.buzz/s/siri;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user