Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ECONNREFUSED stops any attempted reconnections on initial connect #4842

Open
delize opened this issue Feb 29, 2024 · 0 comments
Open

ECONNREFUSED stops any attempted reconnections on initial connect #4842

delize opened this issue Feb 29, 2024 · 0 comments
Labels
Type: Bug Issues that report and PRs that solve any defects that cause unexpected behaviors.

Comments

@delize
Copy link

delize commented Feb 29, 2024

  • Node version: Unknown
  • Browser version: Version 122.0.6261.69
  • Device, operating system: Docker Image
  • The Lounge version: v4.4.1

I am running:

  • ZNC
  • TL

In a docker compose file:

---
version: '3.8'
services:
  thelounge:
    image: thelounge/thelounge:latest
    container_name: thelounge
    user: 1001:1001
    networks:
      - irc
      - backend
    # ports:
    #   - '9001:9000'
    restart: unless-stopped
    volumes:
      - ${BASE_PATH}/thelounge:/var/opt/thelounge
    depends_on:
      - znc
    environment:
      - TZ=${TIME_ZONE:-Europe/Stockholm}
  znc:
    image: znc:latest
    container_name: znc
    user: ${PUID}
    networks:
      - irc
      - backend
    environment:
      - TZ=${TIME_ZONE:-Europe/Stockholm}
      - uid=${PGID}
      - gid=${PGID}
    # ports:
      # - '7000:7000'
      # - '65500:65500'
    volumes:
      - ${BASE_PATH}/znc:/znc-data
      - ${BASE_PATH}/swag/etc/letsencrypt/live/${DOMAIN}/:/le-ssl:ro
    restart: unless-stopped
networks:
  irc:
    driver: bridge
    name: irc
  backend:
    external: true

When I have TL connect to the ZNC server, the first network in TL always fails to connect with:

21:55:02 Network created, connecting to znc:6667...
21:55:02 *** Connection closed unexpectedly: Error: connect ECONNREFUSED 172.19.0.11:6667
21:55:02 Disconnected from the network, and will not reconnect. Use /connect to reconnect again.

After this point, the network never attempts to reconnect.

Where as the second Network connects within <1 second:

21:55:02 Network created, connecting to znc:6667...
21:55:03 Connected to the network.
21:55:03 Enabled capabilities: batch, cap-notify, echo-message, multi-prefix, server-time, userhost-in-names, [znc.in/self-message](http://znc.in/self-message), [znc.in/server-time-iso](http://znc.in/server-time-iso)

Now I can / and need to - write a healthcheck into znc / thelounge based on this: https://docs.docker.com/compose/compose-file/05-services/#long-syntax-1

But, I do think that TL should attempt to reconnect after a period of time on an initial connection attempt, similar to what is occurring here: #4159

@delize delize added the Type: Bug Issues that report and PRs that solve any defects that cause unexpected behaviors. label Feb 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Bug Issues that report and PRs that solve any defects that cause unexpected behaviors.
Projects
None yet
Development

No branches or pull requests

1 participant