mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2026-11-30 14:56:11 +00:00
fix(swarm-test): keep the svc-swarm-manager marker group manager-only in the test inventory
extend_inventory._host_topology placed the app-under-test on the workers whenever the role had no default_placement: manager. When APP_ID is svc-swarm-manager itself, that leaked the workers into the svc-swarm-manager group, which is the marker group IS_STACK_HOST keys on, so IS_STACK_HOST went truthy on the workers and sys-ca-selfsigned skipped its CA fetch (when: not IS_STACK_HOST). root-ca.crt never landed and 'CA | enforce permissions' failed on both workers. Guard the worker extension so this marker group stays manager-only. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
1 parent
c1ad4f85fa
commit
a08dddfed7
1 file changed
+3
-1
@@ -42,7 +42,9 @@ _NFS_SERVER = f"{_PREFIX}{_NAMES['INFINITO_SWARM_NFS_NAME']}"
|
||||
|
||||
def _host_topology(app_id: str) -> list[tuple[str, str]]:
|
||||
app_hosts: list[tuple[str, str]] = [(app_id, _MANAGER)]
|
||||
if get_role_default_placement(app_id) != "manager":
|
||||
# svc-swarm-manager is the IS_STACK_HOST marker group; leaking workers into it
|
||||
# flips IS_STACK_HOST true on workers and skips the CA fetch. Keep it manager-only.
|
||||
if app_id != "svc-swarm-manager" and get_role_default_placement(app_id) != "manager":
|
||||
app_hosts.extend((app_id, w) for w in _WORKERS)
|
||||
return [
|
||||
("svc-swarm-node", _MANAGER),
|
||||
|
||||
Reference in new issue
Block a user