After updating to the latest version, Planka needs exactly one minute to load #313

Closed
opened 2026-02-04 18:30:51 +03:00 by OVERLORD · 5 comments
Owner

Originally created by @Forceu on GitHub (May 25, 2023).

Since updating to the latest Docker image, I have the problem that Planka needs extremely long to load every time you open it in a new tab. This happens on desktop and mobile devices. I attached the waterfall below, the issue seems to be the loading of the file main.8ad7c1cf.js

Interestingly enough, if I try to open the file directly, it loads instantly, both with the browser and with curl. Also it appears to be exactly 1 minute, is there maybe a timeout happening?

image

Originally created by @Forceu on GitHub (May 25, 2023). Since updating to the latest Docker image, I have the problem that Planka needs extremely long to load every time you open it in a new tab. This happens on desktop and mobile devices. I attached the waterfall below, the issue seems to be the loading of the file main.8ad7c1cf.js Interestingly enough, if I try to open the file directly, it loads instantly, both with the browser and with curl. Also it appears to be exactly 1 minute, is there maybe a timeout happening? ![image](https://github.com/plankanban/planka/assets/1593467/7821b5c9-b6bf-4a57-a5ef-2fb4f54d2a9d)
Author
Owner

@meltyshev commented on GitHub (May 25, 2023):

Hi! This is very strange, the file itself weighs less than a megabyte and there is no timeout on loading. Is that version deployed on localhost?

@meltyshev commented on GitHub (May 25, 2023): Hi! This is very strange, the file itself weighs less than a megabyte and there is no timeout on loading. Is that version deployed on localhost?
Author
Owner

@Forceu commented on GitHub (May 25, 2023):

It is behind an nginx proxy. I recreated the docker container on my desktop and there it loads immediately. Were there any changes related to any protocols in the last versions?

Attached you find my nginx config. It contains the option client_body_timeout 60 for the socket connection - so I assume this is where the 60 seconds come from.

upstream planka {
   server localhost:63742;
   keepalive 32;
}

server {
        listen 80;
        listen [::]:80;
        listen 443 ssl;
        listen [::]:443 ssl;
        ssl_certificate /home/acme/certs/cert.pem;
        ssl_certificate_key /home/acme/certs/key.pem;

    access_log /var/log/nginx/planka-access.log;
    error_log  /var/log/nginx/planka-error.log error;

   server_name planka.XXXXXX;

ssl_session_cache shared:SSL:10m;
    ssl_protocols TLSv1.2 TLSv1.3;
    ssl_ciphers "ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:DHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES256-GCM-SHA384";
    ssl_prefer_server_ciphers on;

    client_max_body_size 120M;
    add_header Access-Control-Allow-Origin *;
    add_header Access-Control-Max-Age 3600;
    add_header Access-Control-Expose-Headers Content-Length;
    add_header Access-Control-Allow-Headers Range;

    # Make sure to allow socket.io connections
    location ~* \.io {
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection "upgrade";
        client_max_body_size 50M;
        proxy_set_header Host $http_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-Frame-Options SAMEORIGIN;
        proxy_buffers 256 16k;
        proxy_buffer_size 16k;
        client_body_timeout 60;
        send_timeout 300;
        lingering_timeout 5;
        proxy_connect_timeout 1d;
        proxy_send_timeout 1d;
        proxy_read_timeout 1d;
        proxy_pass http://planka;
    }

    location / {
        client_max_body_size 50M;
        proxy_set_header Connection "";
        proxy_set_header Host $http_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-Frame-Options SAMEORIGIN;
        proxy_buffers 256 16k;
        proxy_buffer_size 16k;
        proxy_read_timeout 600s;
        proxy_cache_revalidate on;
        proxy_cache_min_uses 2;
        proxy_cache_use_stale timeout;
        proxy_cache_lock on;
        proxy_http_version 1.1;
        proxy_pass http://planka;
    }
}
@Forceu commented on GitHub (May 25, 2023): It is behind an nginx proxy. I recreated the docker container on my desktop and there it loads immediately. Were there any changes related to any protocols in the last versions? Attached you find my nginx config. It contains the option `client_body_timeout 60` for the socket connection - so I assume this is where the 60 seconds come from. ``` upstream planka { server localhost:63742; keepalive 32; } server { listen 80; listen [::]:80; listen 443 ssl; listen [::]:443 ssl; ssl_certificate /home/acme/certs/cert.pem; ssl_certificate_key /home/acme/certs/key.pem; access_log /var/log/nginx/planka-access.log; error_log /var/log/nginx/planka-error.log error; server_name planka.XXXXXX; ssl_session_cache shared:SSL:10m; ssl_protocols TLSv1.2 TLSv1.3; ssl_ciphers "ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:DHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES256-GCM-SHA384"; ssl_prefer_server_ciphers on; client_max_body_size 120M; add_header Access-Control-Allow-Origin *; add_header Access-Control-Max-Age 3600; add_header Access-Control-Expose-Headers Content-Length; add_header Access-Control-Allow-Headers Range; # Make sure to allow socket.io connections location ~* \.io { proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "upgrade"; client_max_body_size 50M; proxy_set_header Host $http_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-Frame-Options SAMEORIGIN; proxy_buffers 256 16k; proxy_buffer_size 16k; client_body_timeout 60; send_timeout 300; lingering_timeout 5; proxy_connect_timeout 1d; proxy_send_timeout 1d; proxy_read_timeout 1d; proxy_pass http://planka; } location / { client_max_body_size 50M; proxy_set_header Connection ""; proxy_set_header Host $http_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-Frame-Options SAMEORIGIN; proxy_buffers 256 16k; proxy_buffer_size 16k; proxy_read_timeout 600s; proxy_cache_revalidate on; proxy_cache_min_uses 2; proxy_cache_use_stale timeout; proxy_cache_lock on; proxy_http_version 1.1; proxy_pass http://planka; } } ```
Author
Owner

@meltyshev commented on GitHub (May 25, 2023):

I cannot check the nginx config right now 😔 Please try to remove this line and see how it goes. But so far I don't understand why it applies to one file...

I'll try to contact Daniel, he might be able to figure out what the problem is right away.

@meltyshev commented on GitHub (May 25, 2023): I cannot check the nginx config right now 😔 Please try to remove this line and see how it goes. But so far I don't understand why it applies to one file... I'll try to contact Daniel, he might be able to figure out what the problem is right away.
Author
Owner

@daniel-hiller commented on GitHub (May 25, 2023):

Hi, please check the Nginx error log.
/var/log/nginx/planka-error.log

I checked your configuration on my test system.
Planka loads quickly as usual.

The only difference from our example configuration I found is that we enable http2.

listen 443 ssl http2; listen [::]:443 ssl http2;

@daniel-hiller commented on GitHub (May 25, 2023): Hi, please check the Nginx error log. /var/log/nginx/planka-error.log I checked your configuration on my test system. Planka loads quickly as usual. The only difference from our example configuration I found is that we enable http2. ` listen 443 ssl http2; listen [::]:443 ssl http2; `
Author
Owner

@Forceu commented on GitHub (May 26, 2023):

Okay, it might have just been a problem with my nginx config. IPv6 was disabled on my server, but the server was still listening on IPv6 with the nginx config for planka

2023/05/25 16:43:17 [error] 298396#298396: *1368 upstream timed out (110: Connection timed out) while connecting to upstream, client: 192.168.178.39, server: planka.XXXXX, request: "GET /favicon.ico HTTP/2.0", upstream: "http://[::1]:63742/favicon.ico", host: "planka.XXXXXXX", referrer: "https://planka.XXXXXXXX/static/js/main.8ad7c1cf.js"

After removing the listen [::]:80/443 lines it works. I assume this is not a bug with your app, sorry about that. But also thanks a lot for your help!

@Forceu commented on GitHub (May 26, 2023): Okay, it might have just been a problem with my nginx config. IPv6 was disabled on my server, but the server was still listening on IPv6 with the nginx config for planka > 2023/05/25 16:43:17 [error] 298396#298396: *1368 upstream timed out (110: Connection timed out) while connecting to upstream, client: 192.168.178.39, server: planka.XXXXX, request: "GET /favicon.ico HTTP/2.0", upstream: "http://[::1]:63742/favicon.ico", host: "planka.XXXXXXX", referrer: "https://planka.XXXXXXXX/static/js/main.8ad7c1cf.js" After removing the `listen [::]:80/443` lines it works. I assume this is not a bug with your app, sorry about that. But also thanks a lot for your help!
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/planka#313