diff --git a/bot_bottle/backend/macos_container/infra.py b/bot_bottle/backend/macos_container/infra.py index c0eea45..6bca5c9 100644 --- a/bot_bottle/backend/macos_container/infra.py +++ b/bot_bottle/backend/macos_container/infra.py @@ -101,7 +101,7 @@ def _init_script(port: int) -> str: # Gateway data plane, multi-tenant against the local control plane. f"( cd /app && BOT_BOTTLE_GATEWAY_DAEMONS={_GATEWAY_DAEMONS} " f"BOT_BOTTLE_ORCHESTRATOR_URL=http://127.0.0.1:{port} " - f"SUPERVISE_DB_PATH={_DB_PATH_IN_CONTAINER} python3 /app/gateway_init.py ) &\n" + f"SUPERVISE_DB_PATH={_DB_PATH_IN_CONTAINER} python3 -m bot_bottle.gateway_init ) &\n" "while : ; do wait ; done\n" ) diff --git a/tests/unit/test_macos_infra.py b/tests/unit/test_macos_infra.py index 0971131..012f531 100644 --- a/tests/unit/test_macos_infra.py +++ b/tests/unit/test_macos_infra.py @@ -46,7 +46,9 @@ class TestInfraRun(unittest.TestCase): argv = self._run_container(MacosInfraService(repo_root=Path("/r"))) script = argv[-1] self.assertIn("bot_bottle.orchestrator", script) - self.assertIn("gateway_init.py", script) + # Gateway launches via the installed package (there is no + # /app/gateway_init.py file since the daemons moved into bot_bottle). + self.assertIn("bot_bottle.gateway_init", script) self.assertIn("127.0.0.1", script) # they reach each other on loopback def test_db_is_a_container_only_volume(self) -> None: