deploy: Arbiter reads skills from the hub's public address (ATRIUM_BASE_URL)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016uwxqJYwbXKWMeNZfrFuXq
This commit is contained in:
tobayah
2026-11-18 23:48:08 +01:00
co-authored by Claude Opus 5.5
parent f5ebe67d0b
commit b9b718d7e1
3 changed files with 14 additions and 1 deletions
+7
View File
@@ -149,6 +149,13 @@ class TestAFreshInitIsOneAccount:
for app in ("galena", "sygna", "counsel"):
assert "MODEL_PROVIDER_SECRET" not in _values(fresh / "env" / f"{app}.env"), app
def test_arbiter_reads_skills_from_the_hubs_public_address(self, fresh):
"""A skill version is read through Atrium's API (the same hairpin as Galena's): the example's
`<site>` placeholder must never reach a fresh env file."""
arbiter = _values(fresh / "env" / "arbiter.env")
assert arbiter["ATRIUM_BASE_URL"] == arbiter["GALENA_BASE_URL"].removesuffix("/galena") + "/atrium"
assert "<site>" not in arbiter["ATRIUM_BASE_URL"]
def test_one_first_administrator_for_the_platform(self, fresh):
"""The modules' seeds look the hub's account up by this address, so all five must agree."""
emails = {app: _values(fresh / "env" / f"{app}.migrate.env")["BOOTSTRAP_ADMIN_EMAIL"] for app in FAMILY}
+4
View File
@@ -70,6 +70,10 @@ ENGINE_COMMIT=
# another module (compose.yaml), so `galena-backend` does not resolve from here. An order fetches its
# subject's bytes from Galena with the orderer's token. Empty: subjects are plain files only.
GALENA_BASE_URL=http://<site>/galena
# Atrium's PUBLIC address, the same hairpin: a skill version (`sprawdzanie.yaml`) is read through
# Atrium's API with the acting person's token when a skill is synced or ordered by version. Empty:
# skills cannot be read, and syncing one answers 409 atrium_disabled.
ATRIUM_BASE_URL=http://<site>/atrium
# ── secrets at rest ────────────────────────────────────────────────────────────────────────────
# The platform's model-provider secret (dredd-core 0.15.0): the provider API keys live in the hub's
+3 -1
View File
@@ -462,7 +462,9 @@ write_app_files() {
set_key "$runtime" MODEL_PROVIDER_SECRET "$MODEL_PROVIDER_SECRET"
# Galena's PUBLIC address, a hairpin back through the front door (as Sygna's): an order fetches
# its subject's bytes from Galena with the orderer's own token.
set_key "$runtime" GALENA_BASE_URL "$PUBLIC/galena" ;;
set_key "$runtime" GALENA_BASE_URL "$PUBLIC/galena"
# The hub's, the same hairpin: a skill version is read from Atrium with the person's own token.
set_key "$runtime" ATRIUM_BASE_URL "$PUBLIC/atrium" ;;
lexicon)
set_key "$runtime" APP_BASE_URL "$PUBLIC/lexicon"
set_key "$runtime" SECRET_KEY "$LEXICON_SECRET_KEY"