Skip to content

Nginx

KumoYami behind Nginx, with a Let's Encrypt certificate from certbot.

If you already use Nginx on the server, add a server block for KumoYami and get the certificate with certbot.

Without the installer's Caddy

If you installed with install.sh and gave it a domain, Caddy is already using ports 80 and 443. Run the installer again with --no-caddy before switching to Nginx.

Create the site

/etc/nginx/sites-available/kumoyami
server {
    listen 80;
    server_name nube.example.com;

    location / {
        proxy_pass http://127.0.0.1:4890;
        proxy_set_header Host $host;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header X-Forwarded-Proto $scheme;
    }
}

Enable it and check the configuration:

sudo ln -s /etc/nginx/sites-available/kumoyami /etc/nginx/sites-enabled/
sudo nginx -t && sudo systemctl reload nginx

On distributions without sites-available (Rocky, Alma, Fedora), save the block as /etc/nginx/conf.d/kumoyami.conf.

Get the certificate

sudo certbot --nginx -d nube.example.com

Certbot adds the listen 443 ssl, the certificates and the HTTP-to-HTTPS redirect, and schedules the renewal.

Network drive (WebDAV) and large files

If you turn on the WebDAV network drive in the panel (it's served at /webdav/), add a block inside the same server that accepts files of any size and passes them on to KumoYami as they arrive:

    location /webdav/ {
        proxy_pass http://127.0.0.1:4890;
        proxy_set_header Host $host;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header X-Forwarded-Proto $scheme;
        client_max_body_size 0;
        proxy_request_buffering off;
    }

By default Nginx caps each request at 1 MB. If uploading files from the site gives you a 413 Request Entity Too Large error, raise client_max_body_size in location / as well.