feat(system): manage compute contour network profile

This commit is contained in:
DCCONSTRUCTIONS
2026-07-29 12:32:41 +03:00
parent 1eba7c82ba
commit d8ccc9345a
8 changed files with 1139 additions and 9 deletions
+10
View File
@@ -41,6 +41,7 @@ def test_contour_store_migrates_worker_006_as_first_configuration(
assert contours[0].telemetry_mode == "agent-mqtt"
assert contours[0].telemetry_poll_interval_seconds == 3
assert contours[0].mqtt_publish_interval_seconds == 2
assert contours[0].mqtt_bind_address == "127.0.0.1"
assert not store.path.exists()
@@ -53,6 +54,7 @@ def test_contour_store_creates_and_updates_private_catalog(tmp_path: Path) -> No
platform="linux",
address="192.0.2.25",
mqtt_host="192.0.2.5",
mqtt_bind_address="192.168.10.5",
)
)
updated = store.update(
@@ -67,6 +69,7 @@ def test_contour_store_creates_and_updates_private_catalog(tmp_path: Path) -> No
ssh_port=22,
mqtt_host="192.0.2.5",
mqtt_port=1883,
mqtt_bind_address="192.168.10.5",
telemetry_poll_interval_seconds=1,
mqtt_publish_interval_seconds=4,
),
@@ -91,6 +94,7 @@ def test_contour_store_creates_and_updates_private_catalog(tmp_path: Path) -> No
ssh_port=22,
mqtt_host="127.0.0.1",
mqtt_port=1883,
mqtt_bind_address="127.0.0.1",
telemetry_poll_interval_seconds=3,
mqtt_publish_interval_seconds=2,
),
@@ -119,6 +123,12 @@ def test_contour_router_exposes_catalog_and_safe_install_contract(
assert "password" not in document["agent"]["environment"]
assert document["agent"]["environment"]["MISSIONCORE_TELEMETRY_INTERVAL"] == "2s"
assert document["ready"] is False
network = _endpoint(
router,
"/api/v1/system/contours/{contour_id}/network",
"GET",
)
assert callable(network)
def test_contour_router_returns_404_for_unknown_contour(tmp_path: Path) -> None: