A connection issue or the server is down

Hi everyone,

I’m currently running n8n 1.81.4 with Docker Compose and Nginx, but I’m facing a connection issue:

You have a connection issue or the server is down. n8n should reconnect automatically once the issue is resolved.

Here’s my docker-compose.yml configuration:

services:
n8n:
image: n8nio/n8n
container_name: n8n
restart: unless-stopped
ports:
- “5678:5678”
environment:
- N8N_HOST=****
- N8N_PORT=5678
- N8N_PROTOCOL=http
- WEBHOOK_TUNNEL_URL=https://****/
- TZ=Asia/Ho_Chi_Minh
- N8N_RUNNERS_ENABLED=true
- N8N_PUSH_BACKEND = sse
volumes:
- /root/n8n_data:/home/node/.n8n
networks:
default:
driver: bridge

Has anyone encountered this issue before or has suggestions on how to fix it? Any help would be greatly appreciated!

Thanks in advance!
VTCN

hello @VTCN

Did you check that the docker container was running and not restarted?

Also, WEBHOOK_TUNNEL_URL is incorrect. Proper name is WEBHOOK_URL

And why you have set the variable N8N_PUSH_BACKEND? Nginx works perfectly with websockets

2 Likes

Thanks @barn4k,

I checked log and findout missing websocket at nginx.
Problem is resloved.

Also, I change Webhook and edit this

N8N_PUSH_BACKEND=websocket

Best regards,

Worked for me, current version 1.81.4, docker, reverse proxy (Nginx), Ubuntu 24.04
N8N_PUSH_BACKEND=websocket

If it still doesn’t work, adjust Nginx to use Websocks.
Edit your n8n’s Nginx configuration.

sudo nano /etc/nginx/sites-available/n8n

Add the following lines to /location

proxy_http_version 1.1; # Required for WebSocket
proxy_set_header Upgrade $http_upgrade; # Required for WebSocket
proxy_set_header Connection "upgrade"; # Required for WebSocket

Save and restart Nginx

sudo nginx -t
sudo systemctl restart nginx

It should work now!

1 Like

Dear someone can help me with this failure ? i have the latest version of n8n and docker 18 activated thanks

this is my configuration code GNU nano 7.2 docker-compose.yml
version: ‘3.8’

services:
n8n:
image: n8nio/n8n:latest
ports:
- “5678:5678”
environment:
- N8N_BASIC_AUTH_ACTIVE=true
- N8N_BASIC_AUTH_USER=usuario
- N8N_BASIC_AUTH_PASSWORD=contraseña
volumes:
- n8n_data:/home/node/.n8n

volumes:
n8n_data:

This information about n8n

Debug info

core

  • n8nVersion: 1.81.4
  • platform: docker (self-hosted)
  • nodeJsVersion: 18.20.6
  • database: sqlite
  • executionMode: regular
  • concurrency: -1
  • license: community
  • consumerId: unknown

storage

  • success: all
  • error: all
  • progress: false
  • manual: true
  • binaryMode: memory

pruning

  • enabled: true
  • maxAge: 336 hours
  • maxCount: 10000 executions

client

  • userAgent: mozilla/5.0 (windows nt 10.0; win64; x64) applewebkit/537.36 (khtml, like gecko) chrome/133.0.0.0 safari/537.36
  • isTouchDevice: false

Generated at: 2025-03-11T09:55:50.581Z

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.