User Tools

Site Tools


nginx

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
nginx [2021/04/29 08:25] – created utedassnginx [2022/09/12 00:30] (current) – external edit 127.0.0.1
Line 3: Line 3:
 [[https://www.digitalocean.com/community/tutorials/understanding-nginx-server-and-location-block-selection-algorithms|Nginx server and location block]] -- Explains matching against server and location blocks [[https://www.digitalocean.com/community/tutorials/understanding-nginx-server-and-location-block-selection-algorithms|Nginx server and location block]] -- Explains matching against server and location blocks
  
 +[[https://docs.nginx.com/nginx/admin-guide/web-server/reverse-proxy/|Reverse proxy]] -- Explanations and examples
  
  
 +====== Site configuration ======
 +
 +===== Proxy =====
 +==== Owncloud/Nextcloud ====
 +
 +<code nginx>
 +    location / {
 +        # Nextcloud spesific proxy
 +        proxy_pass_header Server;
 +        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;
 +        proxy_set_header X-Forwarded-host $host;
 +        
 +        proxy_pass_header Authorization;
 +        
 +        proxy_pass http://192.168.1.218:80;
 +    }
 +</code>
 +
 +==== Other ====
 +
 +<code nginx>
 +    location / {
 +        proxy_pass http://localhost:1338;
 +        proxy_http_version 1.1;
 +        proxy_set_header Upgrade $http_upgrade;
 +        proxy_set_header Connection 'upgrade';
 +        proxy_set_header Host $host;
 +        proxy_cache_bypass $http_upgrade;
 +    }
 +</code>
nginx.1619684703.txt.gz · Last modified: 2022/09/12 00:30 (external edit)

Except where otherwise noted, content on this wiki is licensed under the following license: CC0 1.0 Universal
CC0 1.0 Universal Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki