From 7d42bd2b0242da8fca876bfd70de5ce1286a02c8 Mon Sep 17 00:00:00 2001 From: Amir Raminfar Date: Tue, 3 Sep 2024 08:13:42 -0700 Subject: [PATCH] chore: adds comparison chart for agents and removes warning (#3246) --- docs/guide/agent.md | 15 +++++++++++++++ docs/guide/remote-hosts.md | 4 ++-- docs/guide/swarm-mode.md | 2 +- internal/support/cli/clients.go | 2 +- 4 files changed, 19 insertions(+), 4 deletions(-) diff --git a/docs/guide/agent.md b/docs/guide/agent.md index 508be37a..f4eff22b 100644 --- a/docs/guide/agent.md +++ b/docs/guide/agent.md @@ -156,3 +156,18 @@ $ openssl genpkey -algorithm RSA -out key.pem -pkeyopt rsa_keygen_bits:2048 $ openssl req -new -key key.pem -out request.csr -subj "/C=US/ST=California/L=San Francisco/O=My Company" $ openssl x509 -req -in request.csr -signkey key.pem -out cert.pem -days 365 ``` + +## Comparing agents with remote connection + +Agents are similar to remote connections, but they have some advantages. Generally, agents are preferred over remote connections due to performance and security reasons. Here is a comparison: + +| Feature | Agent | Remote Connection | +| ----------- | -------------------------- | ------------------------------- | +| Performance | Better with disturbed load | Worse on the UI | +| Security | Private SSL | Insecure or Docker TLS | +| Ease of use | Easy out of the box | Requires exposing Docker socket | +| Permissions | Full access to Docker | Can be controlled with a proxy | +| Reconnect | Automatically reconnects | Requires UI restart | +| Healthcheck | Built-in healthcheck | No healthcheck | + +If you do plan to use remote connections, make sure to secure the connection using Docker TLS or a reverse proxy. diff --git a/docs/guide/remote-hosts.md b/docs/guide/remote-hosts.md index 18ffc60b..b184dbb3 100644 --- a/docs/guide/remote-hosts.md +++ b/docs/guide/remote-hosts.md @@ -2,14 +2,14 @@ title: Remote Host Setup --- -# Remote Host Setup +# Remote Host Setup Dozzle supports connecting to remote Docker hosts. This is useful when running Dozzle in a container and you want to monitor a different Docker host. However, with Dozzle agents, you can connect to remote hosts without exposing the Docker socket. See the [agent](/guide/agent) page for more information. > [!WARNING] -> Remote hosts will soon be deprecated in favor of agents. Agents provide a more secure way to connect to remote hosts. See the [agent](/guide/agent) page for more information. If you want keep using remote hosts then follow this discussion on [GitHub](https://github.com/amir20/dozzle/issues/3066). +> Remote hosts have been replaced with agents. Agents provide a more secure way to connect to remote hosts. Although remote hosts are still supported, it is recommended to use agents. See the [agent](/guide/agent) page for more information and examples. For comparison, see the [comparing agents with remote connections](/guide/agent#comparing-agents-with-remote-connection) section. ## Connecting to remote hosts with TLS diff --git a/docs/guide/swarm-mode.md b/docs/guide/swarm-mode.md index ef464825..039dbca6 100644 --- a/docs/guide/swarm-mode.md +++ b/docs/guide/swarm-mode.md @@ -2,7 +2,7 @@ title: Swarm Mode --- -# Swarm Mode +# Swarm Mode Dozzle supports Docker Swarm Mode starting from version 8. When using Swarm Mode, Dozzle will automatically discover services and custom groups. Dozzle does not use Swarm API internally as it is [limited](https://github.com/moby/moby/issues/33183). Dozzle implements its own grouping using swarm labels. Additionally, Dozzle merges stats for containers in a group. This means that you can see logs and stats for all containers in a group in one view. But it does mean each host needs to be setup with Dozzle. diff --git a/internal/support/cli/clients.go b/internal/support/cli/clients.go index 55cdb1c0..005d8c5c 100644 --- a/internal/support/cli/clients.go +++ b/internal/support/cli/clients.go @@ -11,7 +11,7 @@ import ( func CreateMultiHostService(embeddedCerts embed.FS, args Args) (docker.Client, *docker_support.MultiHostService) { var clients []docker_support.ClientService if len(args.RemoteHost) > 0 { - log.Warn().Msg(`Remote host flag is deprecated and will be removed in future versions. Agents will replace remote hosts as a safer and performant option. See https://github.com/amir20/dozzle/issues/3066 for discussion.`) + log.Info().Msg(`Consider using Dozzle's remote agent to manage remote hosts. See https://dozzle.dev/guide/agent for more information`) } for _, remoteHost := range args.RemoteHost {