You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/caddy-configuration.md
+33Lines changed: 33 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,6 +14,39 @@ Ember connects to the Caddy admin API (default: `localhost:2019`). Make sure it'
14
14
15
15
> **Caution:** The admin API is unauthenticated by default. Do not expose it on a public interface. See [Caddy's admin API documentation](https://caddyserver.com/docs/caddyfile/options#admin) for authentication options.
16
16
17
+
## Unix Socket
18
+
19
+
For improved security, Caddy can listen on a Unix socket instead of a TCP port. This avoids network exposure entirely and restricts access through filesystem permissions:
20
+
21
+
```
22
+
{
23
+
admin unix//run/caddy/admin.sock
24
+
}
25
+
```
26
+
27
+
You can also set file permissions on the socket:
28
+
29
+
```
30
+
{
31
+
admin unix//run/caddy/admin.sock|0660
32
+
}
33
+
```
34
+
35
+
To connect Ember to a Unix socket:
36
+
37
+
```bash
38
+
ember --addr unix//run/caddy/admin.sock
39
+
```
40
+
41
+
Or via environment variable:
42
+
43
+
```bash
44
+
export EMBER_ADDR=unix//run/caddy/admin.sock
45
+
ember
46
+
```
47
+
48
+
> **Note:** TLS options (`--ca-cert`, `--client-cert`, `--client-key`, `--insecure`) cannot be used with Unix socket addresses, as the connection is local and does not traverse the network.
49
+
17
50
## Metrics Directive
18
51
19
52
The `metrics` directive enables Prometheus-format metrics on the admin API. Without it, Ember cannot display HTTP traffic data.
Copy file name to clipboardExpand all lines: docs/docker.md
+34Lines changed: 34 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -70,6 +70,40 @@ With this setup, Ember runs in the same network namespace as Caddy and can reach
70
70
71
71
> **Caution:** The image is built from `scratch`: there is no shell, no `exec`, and no debugging tools inside the container. Use `docker logs` to read Ember's stderr output.
72
72
73
+
## Unix Socket
74
+
75
+
If Caddy's admin API is configured to listen on a Unix socket, mount the socket into the Ember container:
0 commit comments