Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- server {
- server_name kiwiirc.hybridirc.com;
- access_log off;
- location / {
- index index.html;
- root /usr/share/kiwiirc/;
- }
- location /webirc/ {
- # Forward incoming requests to local webircgateway socket
- proxy_pass http://localhost:8090/webirc/;
- # Set http version and headers
- proxy_http_version 1.1;
- proxy_set_header X-Forwarded-For $remote_addr;
- # Allow upgrades to websockets
- proxy_set_header Upgrade $http_upgrade;
- proxy_set_header Connection "upgrade";
- }
- location /files/ {
- # Forward incoming requests to local fileupload instance
- proxy_pass http://127.0.0.1:8088/files/;
- # Disable request and response buffering
- proxy_request_buffering off;
- proxy_buffering off;
- proxy_http_version 1.1;
- # Add X-Forwarded-* headers
- proxy_set_header X-Forwarded-Host $host;
- proxy_set_header X-Forwarded-Proto $scheme;
- proxy_set_header X-Forwarded-For $remote_addr;
- # Allow upgrades to websockets
- proxy_set_header Upgrade $http_upgrade;
- proxy_set_header Connection "upgrade";
- client_max_body_size 0;
- }
- listen 443 ssl; # managed by Certbot
- ssl_certificate /etc/letsencrypt/live/kiwiirc.hybridirc.com/fullchain.pem; # managed by Certbot
- ssl_certificate_key /etc/letsencrypt/live/kiwiirc.hybridirc.com/privkey.pem; # managed by Certbot
- include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
- ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
- }
- server {
- if ($host = kiwiirc.hybridirc.com) {
- return 301 https://$host$request_uri;
- } # managed by Certbot
- listen 80;
- server_name kiwiirc.hybridirc.com;
- return 404; # managed by Certbot
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement