Skip to content

Add the environment authorization type - #35

Merged
vitramir merged 1 commit into
mainfrom
feat/environment-authorization-type
Aug 7, 2026
Merged

vitramir merged 1 commit into
mainfrom
feat/environment-authorization-type

Conversation

@vitramir

@vitramir vitramir commented Aug 7, 2026

Copy link
Copy Markdown
Contributor

Environments had no OpenFGA type at all, so the only thing that could be said
about one was which organization it belonged to.

The type mirrors agent, with the one relation agents have no need for.
can_use separates running in an environment from editing one: an environment
carries secret-backed ENVs, egress rules that inject credentials, and the
contents of its volumes, and anyone who can start a sandbox in it gets a shell
sitting on all three. A team can hand user out widely while keeping authorship
to itself.

can_create_environment follows member — an environment is authored by
whoever needs one, and its creator becomes the owner.

Additive and inert until the Agents service writes these tuples, so it deploys
on its own.

fga model test goes from 24/25 to 28/29 — four new tests, 28 new checks, all
passing. The one remaining failure predates this branch
(can_list_sandboxes for a cluster admin: the model allows it, the assertion
says it should not) and is left alone rather than silently resolved either way.

Spec: architecture/architecture/authz.md#environment

Environments had no OpenFGA type at all, so the only thing that could be said
about one was which organization it belonged to. The type mirrors agent, with
the one relation agents have no need for.

can_use separates running in an environment from editing one. An environment
carries secret-backed ENVs, egress rules that inject credentials, and the
contents of its volumes, and anyone who can start a sandbox in it gets a shell
sitting on all three -- so using one is a grant of its own, not a consequence of
being able to see it. A team can hand out user widely while keeping authorship
to itself.

can_create_environment follows member: an environment is authored by whoever
needs one, and its creator becomes the owner.

Additive and inert until the Agents service writes these tuples.
@vitramir
vitramir merged commit a4e0f2e into main Aug 7, 2026
1 of 2 checks passed
@vitramir
vitramir deleted the feat/environment-authorization-type branch August 7, 2026 23:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant