feat: resource-control view of reef-storage

Project the planned Scaleway backup bucket onto the new storage reef.
This commit is contained in:
tegwick 2026-08-14 15:53:30 +02:00
parent 5b2435cb58
commit 9d11d2a043
2 changed files with 29 additions and 0 deletions

View file

@ -0,0 +1,19 @@
{
"schema_version": "0.1",
"reef_id": "reef-storage",
"repo": "reef-storage",
"declaration_ref": "reef:storage/declarations/reef.yaml",
"procuring_entity_id": "entity:railiance",
"financial_entity_id": "entity:railiance",
"role": "storage_substrate",
"resources": [
{"resource_id": "resource:platform:audit-storage", "role": "object_store"}
],
"consumers_potential": ["rapp-postgres"],
"consumers_actual": [],
"notes": [
"Provider-delegated S3 (Scaleway). No rail.",
"Attribute values: reef:storage/substrate/object-stores/platform-audit-storage.yaml",
"Independent of reef-railiance."
]
}

View file

@ -92,6 +92,16 @@ class ReefViewTest(unittest.TestCase):
self.assertNotIn("resource:platform:audit-storage", {row["resource_id"] for row in view["resources"]})
self.assertTrue(any("reef-storage" in note for note in view["notes"]))
def test_reef_storage_view_is_delegated_object_store(self):
view = json.loads((ROOT / "data/reefs/reef-storage.json").read_text())
self.assertEqual("storage_substrate", view["role"])
self.assertEqual(
["resource:platform:audit-storage"],
[row["resource_id"] for row in view["resources"]],
)
self.assertEqual(["rapp-postgres"], view["consumers_potential"])
self.assertEqual([], view["consumers_actual"])
if __name__ == "__main__":
unittest.main()