feat(cloud): add edge host enrollment
This commit is contained in:
@@ -32,6 +32,15 @@ def test_compose_defines_database_control_plane_and_outbound_host_agent() -> Non
|
||||
assert services["host-agent"]["environment"]["AI_PLANNER_ENABLED"] == (
|
||||
"${AI_PLANNER_ENABLED:-false}"
|
||||
)
|
||||
assert (
|
||||
services["cloud-api"]["environment"]["CLOUD_ENROLLMENT_TOKENS_JSON"]
|
||||
== "${CLOUD_ENROLLMENT_TOKENS_JSON:-[]}"
|
||||
)
|
||||
assert (
|
||||
services["host-agent"]["environment"]["HOST_AGENT_IDENTITY_PATH"]
|
||||
== "${HOST_AGENT_IDENTITY_PATH:-/app/tasks/host_identity.json}"
|
||||
)
|
||||
assert "ports" not in services["host-agent"]
|
||||
|
||||
|
||||
def test_container_uses_locked_workspace_install_and_migrations() -> None:
|
||||
@@ -54,8 +63,11 @@ def test_example_environment_contains_only_placeholder_credentials() -> None:
|
||||
|
||||
public_credentials = json.loads(values["CLOUD_PUBLIC_CREDENTIALS_JSON"])
|
||||
host_credentials = json.loads(values["CLOUD_HOST_CREDENTIALS_JSON"])
|
||||
enrollment_credentials = json.loads(values["CLOUD_ENROLLMENT_TOKENS_JSON"])
|
||||
|
||||
assert public_credentials[0]["token"].startswith("change-me-")
|
||||
assert host_credentials[0]["token"] == values["HOST_AGENT_TOKEN"]
|
||||
assert host_credentials[0]["token"].startswith("change-me-")
|
||||
assert host_credentials[0]["host_id"] == values["HOST_AGENT_HOST_ID"]
|
||||
assert enrollment_credentials[0]["token"].startswith("change-me-")
|
||||
assert values["HOST_AGENT_IDENTITY_PATH"] == "/app/tasks/host_identity.json"
|
||||
|
||||
Reference in New Issue
Block a user