Can't upload ISOs to my Proxmox via nginx and Cloudflare tunnel.

gerardgarcia

New Member
Mar 25, 2023
13
0
1
Hi guys.
Some time ago, I decided to have public access to manage my Proxmox server everywhere I go.

So by these I've made a Cloudflare Tunnel, installing it on may Proxmox server and configuring Nginx as a webmanager, because the default port 8006 has no access through the Cloudflare tunnel.

Editing the Proxmox.conf as these ay:
Code:
nano /etc/nginx/conf.d/proxmox.conf

Code:
  GNU nano 7.2                   /etc/nginx/conf.d/proxmox.conf                             
server {
    listen 443;
    server_name _;
    ssl on;
    ssl_certificate /etc/pve/local/pve-ssl.pem;
    ssl_certificate_key /etc/pve/local/pve-ssl.key;
    proxy_redirect off;
    location / {
        proxy_http_version 1.1;
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection "upgrade";
        proxy_pass https://192.168.0.4:8006;
        proxy_buffering off;
        client_max_body_size 0;
        proxy_connect_timeout  3600s;
        proxy_read_timeout  3600s;
        proxy_send_timeout  3600s;
        send_timeout  3600s;
    }
}

server {
    listen       80;
    charset utf-8;
    server_name  pveserver.garciacloud.uk;
    location / {
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection "upgrade";
        include proxy_params;
        proxy_pass https://192.168.0.4:8006;

    }

}

Where:
192.168.0.4 is the local IP of my Proxmox server.


So In the Cloudflare tunnel I added a Public Hostname, pointing to: http://192.168.0.4
and It works I can get access to my Proxmox server and its VM machines.
(I'm not using https://192.168.0.4, because when I use it, server its unreachable)

But I'm noticing that I cannot Upload ISOs on my Proxmox server.
when I choose an ISO and I clicked "Upload" button, the progress bar its stopped and it doesn't work.


What am I doing wrong? :(

Thanks in Advance
 
Hi guys.
Some time ago, I decided to have public access to manage my Proxmox server everywhere I go.

So by these I've made a Cloudflare Tunnel, installing it on may Proxmox server and configuring Nginx as a webmanager, because the default port 8006 has no access through the Cloudflare tunnel.

Editing the Proxmox.conf as these ay:
Code:
nano /etc/nginx/conf.d/proxmox.conf

Code:
  GNU nano 7.2                   /etc/nginx/conf.d/proxmox.conf                            
server {
    listen 443;
    server_name _;
    ssl on;
    ssl_certificate /etc/pve/local/pve-ssl.pem;
    ssl_certificate_key /etc/pve/local/pve-ssl.key;
    proxy_redirect off;
    location / {
        proxy_http_version 1.1;
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection "upgrade";
        proxy_pass https://192.168.0.4:8006;
        proxy_buffering off;
        client_max_body_size 0;
        proxy_connect_timeout  3600s;
        proxy_read_timeout  3600s;
        proxy_send_timeout  3600s;
        send_timeout  3600s;
    }
}

server {
    listen       80;
    charset utf-8;
    server_name  pveserver.garciacloud.uk;
    location / {
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection "upgrade";
        include proxy_params;
        proxy_pass https://192.168.0.4:8006;

    }

}

Where:
192.168.0.4 is the local IP of my Proxmox server.


So In the Cloudflare tunnel I added a Public Hostname, pointing to: http://192.168.0.4
and It works I can get access to my Proxmox server and its VM machines.
(I'm not using https://192.168.0.4, because when I use it, server its unreachable)

But I'm noticing that I cannot Upload ISOs on my Proxmox server.
when I choose an ISO and I clicked "Upload" button, the progress bar its stopped and it doesn't work.


What am I doing wrong? :(

Thanks in Advance
Reading other post I found the solution.


Just by changing the buffer of the nginx server adding these lines on Proxmox.conf:

Code:
client_header_buffer_size 1k;
    large_client_header_buffers 2 1k;
 
I encountered the issue too. Adding this did the trick, even tho the upload is slower than without the reverse proxy

Code:
client_max_body_size 10G;
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!