fix(haproxy-stats): add stats socket to template + fix safeAt index-0 bug
Two root causes for Dashboard backends not showing: 1. haproxy.cfg.tpl had no stats socket directive → /run/haproxy/admin.sock never created → handler got "connection refused" → empty array returned. Fixed: added stats socket /run/haproxy/admin.sock mode 0660 level admin. 2. safeAt() used i<=0 instead of i<0 → pxname (column 0) always returned "" → all backend names were empty in the API response. After upgrade: HAProxy reload (triggered by any domain/backend save, or edgeguard-ctl render-config) will create the socket. v1.1.113. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -15,6 +15,9 @@ global
|
||||
# Ohne dieses Flag verweigert HAProxy `bind quic4@…` mit "this SSL
|
||||
# library does not support the QUIC protocol".
|
||||
limited-quic
|
||||
# Runtime-API-Socket für edgeguard-api (show stat, show info, …).
|
||||
# mode 0660 + group haproxy → edgeguard-user (in haproxy-group) kann lesen.
|
||||
stats socket /run/haproxy/admin.sock mode 0660 level admin expose-fd listeners
|
||||
|
||||
defaults
|
||||
log global
|
||||
|
||||
Reference in New Issue
Block a user