[Bug]: Node error.The js application does not want to run completely. #586

Closed
opened 2026-02-04 20:26:54 +03:00 by OVERLORD · 11 comments
Owner

Originally created by @saher228 on GitHub (Oct 18, 2024).

Where is the problem occurring?

I encountered the problem while interacting with the server (Backend)

What browsers are you seeing the problem on?

Other

Current behaviour

Node.js v18.20.4
node:internal/process/promises:288
            triggerUncaughtException(err, true /* fromPromise */);
            ^
Error: getaddrinfo ENOTFOUND 7gLz5Wg
    at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:107:26) {
  errno: -3008,
  code: 'ENOTFOUND',
  syscall: 'getaddrinfo',
  hostname: '7gLz5Wg'
}

image

image

Desired behaviour

No response

Steps to reproduce

I've tried everything from reinstalling to configuring, I did it according to the instructions

Other information

No response

Originally created by @saher228 on GitHub (Oct 18, 2024). ### Where is the problem occurring? I encountered the problem while interacting with the server (Backend) ### What browsers are you seeing the problem on? Other ### Current behaviour ``` Node.js v18.20.4 node:internal/process/promises:288 triggerUncaughtException(err, true /* fromPromise */); ^ Error: getaddrinfo ENOTFOUND 7gLz5Wg at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:107:26) { errno: -3008, code: 'ENOTFOUND', syscall: 'getaddrinfo', hostname: '7gLz5Wg' } ``` ![image](https://github.com/user-attachments/assets/4aefee0e-aceb-44ce-a526-a9291644c2e8) ![image](https://github.com/user-attachments/assets/1c2f4819-c0ea-4e76-b650-c31e6b14e197) ### Desired behaviour _No response_ ### Steps to reproduce I've tried everything from reinstalling to configuring, I did it according to the instructions ### Other information _No response_
OVERLORD added the help wanted label 2026-02-04 20:26:54 +03:00
Author
Owner

@meltyshev commented on GitHub (Oct 18, 2024):

Hi! Could you please provide your docker-compose.yml file? It seems there might be a misconfiguration, as the error indicates that the hostname 7gLz5Wg can't be resolved to an IP address.

@meltyshev commented on GitHub (Oct 18, 2024): Hi! Could you please provide your `docker-compose.yml` file? It seems there might be a misconfiguration, as the error indicates that the hostname `7gLz5Wg` can't be resolved to an IP address.
Author
Owner

@saher228 commented on GitHub (Oct 19, 2024):

Hi! Could you please provide your docker-compose.yml file? It seems there might be a misconfiguration, as the error indicates that the hostname 7gLz5Wg can't be resolved to an IP address.

OK, here's the file itself, I was only able to put the instance in a zip

docker-compose.zip

@saher228 commented on GitHub (Oct 19, 2024): > Hi! Could you please provide your `docker-compose.yml` file? It seems there might be a misconfiguration, as the error indicates that the hostname `7gLz5Wg` can't be resolved to an IP address. OK, here's the file itself, I was only able to put the instance in a zip [docker-compose.zip](https://github.com/user-attachments/files/17442505/docker-compose.zip)
Author
Owner

@meltyshev commented on GitHub (Oct 20, 2024):

Everything appears to be configured correctly. I’ve checked our Portainer, and the only difference is that we specify networks for each service:

version: '3'

services:
  planka:
    # ...
    networks:
      - "default"
      - "web"

  postgres:
    # ...
    networks:
      - "default"

# ...

networks:
  default:
  web:
    external: true
@meltyshev commented on GitHub (Oct 20, 2024): Everything appears to be configured correctly. I’ve checked our Portainer, and the only difference is that we specify networks for each service: ``` version: '3' services: planka: # ... networks: - "default" - "web" postgres: # ... networks: - "default" # ... networks: default: web: external: true ```
Author
Owner

@saher228 commented on GitHub (Oct 20, 2024):

Thanks, it almost worked, but not completely . I changed the YAML a bit, since Postgres 15 was already available in Portainer . I just created a planka database, everything is connected, and I don't see any errors . However, for some reason, the page is empty, or maybe I changed the YAML incorrectly.

instance in a zip
docker-compose.zip

image
image
image

Everything appears to be configured correctly. I’ve checked our Portainer, and the only difference is that we specify networks for each service:

version: '3'

services:
  planka:
    # ...
    networks:
      - "default"
      - "web"

  postgres:
    # ...
    networks:
      - "default"

# ...

networks:
  default:
  web:
    external: true
@saher228 commented on GitHub (Oct 20, 2024): Thanks, it almost worked, but not completely . I changed the YAML a bit, since Postgres 15 was already available in Portainer . I just created a planka database, everything is connected, and I don't see any errors . However, for some reason, the page is empty, or maybe I changed the YAML incorrectly. > instance in a zip > [docker-compose.zip](https://github.com/user-attachments/files/17451538/docker-compose.zip) ![image](https://github.com/user-attachments/assets/4a346870-93b8-452b-bbef-b2031b6f8d8c) ![image](https://github.com/user-attachments/assets/cf3e845d-c404-4260-8d67-f3a1ec8a7a61) ![image](https://github.com/user-attachments/assets/1ff716d3-7eb9-46e8-b2c8-2a28be558537) > Everything appears to be configured correctly. I’ve checked our Portainer, and the only difference is that we specify networks for each service: > > ``` > version: '3' > > services: > planka: > # ... > networks: > - "default" > - "web" > > postgres: > # ... > networks: > - "default" > > # ... > > networks: > default: > web: > external: true > ```
Author
Owner

@meltyshev commented on GitHub (Oct 20, 2024):

The white screen issue could be due to an incorrect BASE_URL configuration, it should be set to http://192.168.0.43:3000 in your case, the same as what you'd enter in the browser.

@meltyshev commented on GitHub (Oct 20, 2024): The white screen issue could be due to an incorrect `BASE_URL` configuration, it should be set to `http://192.168.0.43:3000` in your case, the same as what you'd enter in the browser.
Author
Owner

@saher228 commented on GitHub (Oct 21, 2024):

Thank you very much. Everything works almost perfectly, but there is a problem with the proxy server. I specified the subdomain in BASE_URL and proxied HTTP://192.168.0.43:3000 to a subdomain, but when you try to log in, an endless download begins, if you do not proxy and use only IP, then everything is fine.

image
image
image

The white screen issue could be due to an incorrect BASE_URL configuration, it should be set to http://192.168.0.43:3000 in your case, the same as what you'd enter in the browser.

@saher228 commented on GitHub (Oct 21, 2024): Thank you very much. Everything works almost perfectly, but there is a problem with the proxy server. I specified the subdomain in `BASE_URL` and proxied `HTTP://192.168.0.43:3000` to a subdomain, but when you try to log in, an endless download begins, if you do not proxy and use only IP, then everything is fine. ![image](https://github.com/user-attachments/assets/74476c61-ef50-4af4-85c9-a3aa4cdce83e) ![image](https://github.com/user-attachments/assets/b34e4256-3381-4736-bdd9-0128b5e37b08) ![image](https://github.com/user-attachments/assets/a9c5f0d3-21c0-4acf-89aa-9ab1192d7770) > The white screen issue could be due to an incorrect `BASE_URL` configuration, it should be set to `http://192.168.0.43:3000` in your case, the same as what you'd enter in the browser.
Author
Owner

@meltyshev commented on GitHub (Oct 21, 2024):

Please try setting the TRUST_PROXY=1 environment variable and then restart the container.

@meltyshev commented on GitHub (Oct 21, 2024): Please try setting the `TRUST_PROXY=1` environment variable and then restart the container.
Author
Owner

@saher228 commented on GitHub (Oct 21, 2024):

image

image

image

Пожалуйста, попробуйте установить TRUST_PROXY=1 переменную окружения, а затем перезапустите контейнер.

@saher228 commented on GitHub (Oct 21, 2024): ![image](https://github.com/user-attachments/assets/79303bdb-0681-4199-b16c-e2c55f5d8347) ![image](https://github.com/user-attachments/assets/162a3868-03a6-4111-9b81-b63e26c24cba) ![image](https://github.com/user-attachments/assets/3cfb07ab-2a1d-43ef-a230-3cfe88ef7d86) > Пожалуйста, попробуйте установить `TRUST_PROXY=1` переменную окружения, а затем перезапустите контейнер.
Author
Owner

@meltyshev commented on GitHub (Oct 21, 2024):

Based on the first error in the console, the server is returning an HTML page instead of a JSON response for some reason. I'm not entirely sure of the cause, as I'm not very familiar with proxy servers and their configurations. Additionally, I noticed that on your website there's a slash at the end of the BASE_URL which is causing an endless redirect loop.

@meltyshev commented on GitHub (Oct 21, 2024): Based on the first error in the console, the server is returning an HTML page instead of a JSON response for some reason. I'm not entirely sure of the cause, as I'm not very familiar with proxy servers and their configurations. Additionally, I noticed that on your website there's a slash at the end of the `BASE_URL` which is causing an endless redirect loop.
Author
Owner

@saher228 commented on GitHub (Oct 21, 2024):

It's difficult, maybe it's Nginx, so I'll try to deploy Nginx proxy, but I'm not sure, it's strange that an extra slash doesn't come from somewhere.

And so thank you so much for being able to help!

   server 192.168.0.43:1337;
   keepalive 32;
}
server {

    server_name crm.inzeworld.ru;
    access_log /var/log/nginx/planka-access.log;
    error_log  /var/log/nginx/planka-error.log error;

        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://192.168.0.43:3000;
    }

    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://192.168.0.43:3000;
    }```


> Based on the first error in the console, the server is returning an HTML page instead of a JSON response for some reason. I'm not entirely sure of the cause, as I'm not very familiar with proxy servers and their configurations. Additionally, I noticed that on your website there's a slash at the end of the BASE_URL which is causing an endless redirect loop.


@saher228 commented on GitHub (Oct 21, 2024): It's difficult, maybe it's Nginx, so I'll try to deploy Nginx proxy, but I'm not sure, it's strange that an extra slash doesn't come from somewhere. And so thank you so much for being able to help! ```upstream planka { server 192.168.0.43:1337; keepalive 32; } server { server_name crm.inzeworld.ru; access_log /var/log/nginx/planka-access.log; error_log /var/log/nginx/planka-error.log error; 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://192.168.0.43:3000; } 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://192.168.0.43:3000; }``` > Based on the first error in the console, the server is returning an HTML page instead of a JSON response for some reason. I'm not entirely sure of the cause, as I'm not very familiar with proxy servers and their configurations. Additionally, I noticed that on your website there's a slash at the end of the BASE_URL which is causing an endless redirect loop.
Author
Owner

@saher228 commented on GitHub (Oct 28, 2024):

The problem is solved ! The problem was with the server.

Based on the first error in the console, the server is returning an HTML page instead of a JSON response for some reason. I'm not entirely sure of the cause, as I'm not very familiar with proxy servers and their configurations. Additionally, I noticed that on your website there's a slash at the end of the BASE_URL which is causing an endless redirect loop.

@saher228 commented on GitHub (Oct 28, 2024): The problem is solved ! The problem was with the server. > Based on the first error in the console, the server is returning an HTML page instead of a JSON response for some reason. I'm not entirely sure of the cause, as I'm not very familiar with proxy servers and their configurations. Additionally, I noticed that on your website there's a slash at the end of the `BASE_URL` which is causing an endless redirect loop.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/planka#586