Multi Docker Nodes Setup
Using godoxy-agent (recommended)
Docker agent
- Create a directory for agent server,
cdinto it - Navigate to Servers tab in Web UI, click Add agent, fill in required information then click Copy docker compose
- Paste the docker compose into a file (e.g.,
compose.yml) on the agent server then start it withdocker compose up -d
System agent
- Navigate to Servers tab in Web UI, click Add agent, select System as agent type, fill in required information then click Copy shell command
- Run the shell command on the agent server
To update the agent, run the following command on the agent server, or make it a cron job:
bash
bash -c "$(curl -fsSL https://raw.githubusercontent.com/yusing/godoxy/refs/heads/main/scripts/install-agent.sh)" -- updateWhy?
godoxy-agentis a light-weight agent that handles docker, metrics and health checks- Secure by default, with HTTPS and mTLS
Using docker-socket-proxy
WARNING
Not recommended
This exposes docker socket and maintain unencrypted connection
run the following docker compose file on the other node:
yaml
docker-proxy:
container_name: docker-proxy
image: lscr.io/linuxserver/socket-proxy:latest
environment:
- ALLOW_START=1
- ALLOW_STOP=1
- ALLOW_RESTARTS=1
- CONTAINERS=1
- EVENTS=1
- INFO=1
- PING=1
- POST=1
- VERSION=1
volumes:
- /var/run/docker.sock:/var/run/docker.sock
restart: always
tmpfs:
- /run
ports:
- <ip>:2375:2375Add this to your config.yml under providers.docker:
yaml
providers:
docker:
local: ${DOCKER_HOST}
server-1: tcp://<ip>:2375 # add it here