fix: remove invalid servers { name edge } Caddyfile directive
`name` is not a valid subdirective of the global `servers` block in Caddyfile syntax — Caddy would reject the config on startup. The dynamic server discovery in `_discover_server_name()` already handles routing to the correct server regardless of its auto-generated name. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
987413ab3a
commit
241ce96046
1 changed files with 3 additions and 6 deletions
|
|
@ -225,9 +225,9 @@ EOF
|
||||||
chmod 600 "$GANDI_ENV"
|
chmod 600 "$GANDI_ENV"
|
||||||
|
|
||||||
# Create Caddyfile with admin API and wildcard cert
|
# Create Caddyfile with admin API and wildcard cert
|
||||||
# The "servers" global option names the auto-generated server "edge" so that
|
# Note: Caddy auto-generates server names (srv0, srv1, …). lib/caddy.sh
|
||||||
# lib/caddy.sh (which discovers the server dynamically) finds a predictable
|
# discovers the server name dynamically via _discover_server_name() so we
|
||||||
# name — defense-in-depth alongside the dynamic discovery in add_route.
|
# don't need to name the server here.
|
||||||
CADDYFILE="/etc/caddy/Caddyfile"
|
CADDYFILE="/etc/caddy/Caddyfile"
|
||||||
cat > "$CADDYFILE" <<'CADDYEOF'
|
cat > "$CADDYFILE" <<'CADDYEOF'
|
||||||
# Caddy configuration for edge control plane
|
# Caddy configuration for edge control plane
|
||||||
|
|
@ -235,9 +235,6 @@ cat > "$CADDYFILE" <<'CADDYEOF'
|
||||||
|
|
||||||
{
|
{
|
||||||
admin localhost:2019
|
admin localhost:2019
|
||||||
servers {
|
|
||||||
name edge
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
# Default site (reverse proxy for edge tunnels will be added dynamically)
|
# Default site (reverse proxy for edge tunnels will be added dynamically)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue