fix: deflake haproxy bats tests

The byjg/easy-haproxy image polls Docker for label changes every 10
seconds by default, which races with the haproxy bats suite and
intermittently produces curl exit 7. Expose `refresh-conf` as a
global-only haproxy property that maps to `EASYHAPROXY_REFRESH_CONF`,
lower it to 2 seconds in the bats setup, and wrap the localhost HTTP
assertions in a retry loop so checks wait for haproxy to converge
rather than failing on the first attempt.
This commit is contained in:
Jose Diaz-Gonzalez
2026-04-30 15:03:40 -04:00
parent 8f8a23aac3
commit 53ef8c7780
7 changed files with 81 additions and 13 deletions

View File

@@ -72,6 +72,7 @@ cmd-haproxy-report-single() {
"--haproxy-letsencrypt-email: $(fn-haproxy-letsencrypt-email)"
"--haproxy-letsencrypt-server: $(fn-haproxy-letsencrypt-server)"
"--haproxy-log-level: $(fn-haproxy-log-level)"
"--haproxy-refresh-conf: $(fn-haproxy-refresh-conf)"
)
fn-report-validate-format "$FORMAT" "$INFO_FLAG"