1
0
Fork 0
mirror of https://github.com/louislam/dockge.git synced 2026-03-03 02:06:55 -05:00

Agent node should only allow a single connection #212

Open
opened 2026-02-20 13:12:14 -05:00 by deekerman · 0 comments
Owner

Originally created by @jearton on GitHub (Jun 5, 2025).

⚠️ Please verify that this bug has NOT been reported before.

  • I checked and didn't find similar issue

🛡️ Security Policy

Description

Agent node should allow only a single connection, consistent with Portainer Server + Agent behavior.

👟 Reproduction steps

Deploy one agent node and ensure it is running.

Start Server Node A and have it connect to the agent.

While the connection from Server Node A is still active, start Server Node B and attempt to connect it to the same agent node.

Observe that both Server Node A and Server Node B maintain active connections to the same agent node.

👀 Expected behavior

The agent node should accept only the first connection (e.g., from Server Node A).

Any subsequent connection attempts (e.g., from Server Node B) should be rejected with a clear error or ignored.

This behavior should align with how Portainer Server + Agent works—each agent maintains only one active connection to a server node at any time.

😓 Actual Behavior

The agent node accepts multiple simultaneous connections from different server nodes.

Both Server Node A and Server Node B are able to establish and maintain persistent connections to the same agent node.

Dockge Version

1.4.2

💻 Operating System and Arch

Ubuntu 22.04

🌐 Browser

Google Chrome Version 136.0.7103.114

🐋 Docker Version

Docker 27.0.3

🟩 NodeJS Version

No response

📝 Relevant log output


Originally created by @jearton on GitHub (Jun 5, 2025). ### ⚠️ Please verify that this bug has NOT been reported before. - [x] I checked and didn't find similar issue ### 🛡️ Security Policy - [x] I agree to have read this project [Security Policy](https://github.com/louislam/dockge/security/policy) ### Description Agent node should allow only a single connection, consistent with Portainer Server + Agent behavior. ### 👟 Reproduction steps Deploy one agent node and ensure it is running. Start Server Node A and have it connect to the agent. While the connection from Server Node A is still active, start Server Node B and attempt to connect it to the same agent node. Observe that both Server Node A and Server Node B maintain active connections to the same agent node. ### 👀 Expected behavior The agent node should accept only the first connection (e.g., from Server Node A). Any subsequent connection attempts (e.g., from Server Node B) should be rejected with a clear error or ignored. This behavior should align with how Portainer Server + Agent works—each agent maintains only one active connection to a server node at any time. ### 😓 Actual Behavior The agent node accepts multiple simultaneous connections from different server nodes. Both Server Node A and Server Node B are able to establish and maintain persistent connections to the same agent node. ### Dockge Version 1.4.2 ### 💻 Operating System and Arch Ubuntu 22.04 ### 🌐 Browser Google Chrome Version 136.0.7103.114 ### 🐋 Docker Version Docker 27.0.3 ### 🟩 NodeJS Version _No response_ ### 📝 Relevant log output ```shell ```
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/dockge-louislam#212
No description provided.