Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion haproxy_agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,11 @@
from haproxyspoa.spoa_server import SpoaServer
from pydantic import BaseModel, Field, ValidationError, computed_field, model_validator

# Reported by `/info`; AppAPI compares it against its minimum supported HaRP version.
# Keep it in sync with the release tag and use a full `x.y.z` string: a bare float like `0.4`
# is read as "0.4.0", which made every release look older than it is.
HARP_VERSION = "0.4.3"

APPID_PATTERN = re.compile(r"(?:^|/)exapps/([^/]+)")
# Matches `..` path segments in any literal/encoded form: separators can be `/` or %2F,
# the dots themselves can be `.` or %2E (any case combination, e.g. `..`, `%2e.`, `%2E%2e`).
Expand Down Expand Up @@ -835,7 +840,7 @@ async def get_info(request: web.Request):
k8s_status["reachable"] = False

return web.json_response({
"version": 0.4,
"version": HARP_VERSION,
"docker": True,
"kubernetes": k8s_status,
})
Expand Down
Loading