feat(emitters): render the sandbox into the generated packages - #398
Open
ItamarZand88 wants to merge 1 commit into
Open
feat(emitters): render the sandbox into the generated packages#398ItamarZand88 wants to merge 1 commit into
ItamarZand88 wants to merge 1 commit into
Conversation
Greptile SummaryThe PR adds sandbox infrastructure generation across AWS CloudFormation, AWS Terraform, and Kubernetes Helm.
Confidence Score: 5/5The PR appears safe to merge because no blocking failure remains within the eligible follow-up review scope. No blocking failure remains.
|
| Filename | Overview |
|---|---|
| crates/alien-terraform/src/emitters/aws/sandbox.rs | Adds AWS sandbox MicroVM, IAM, propagation barrier, deny-egress connector, and import/binding output generation. |
| crates/alien-cloudformation/src/emitters/aws/sandbox.rs | Adds the CloudFormation equivalent of the AWS sandbox resources and exported registration data. |
| crates/alien-helm/src/emitters/sandbox.rs | Adds sandbox NetworkPolicy generation and cluster-scoped TokenReview RBAC for Kubernetes. |
| crates/alien-terraform/src/generator.rs | Excludes Kubernetes sandboxes from cloud-specific Terraform emission and adds required provider handling. |
| crates/alien-cloudformation/src/built_ins.rs | Registers the AWS sandbox emitter in the built-in CloudFormation registry. |
| crates/alien-helm/src/emitters/mod.rs | Registers the Kubernetes sandbox emitter in the Helm registry. |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart LR
Stack["Sandbox declaration"] --> Target{"Package target"}
Target -->|Terraform| TF["AWS Terraform module"]
Target -->|CloudFormation| CFN["AWS CloudFormation template"]
Target -->|Helm| Helm["Kubernetes Helm chart"]
TF --> AWS["MicroVM image, IAM roles, deny connector"]
CFN --> AWS
Helm --> K8s["NetworkPolicy and broker RBAC"]
AWS --> Import["Sandbox registration and binding data"]
K8s --> Import
Reviews (29): Last reviewed commit: "feat(emitters): render the sandbox into ..." | Re-trigger Greptile
ItamarZand88
force-pushed
the
itamar/alien-75-sandbox-4-emitters
branch
from
August 11, 2026 13:19
a1603b0 to
c208bb8
Compare
ItamarZand88
force-pushed
the
itamar/alien-75-sandbox-4-emitters
branch
2 times, most recently
from
August 11, 2026 16:53
da9d8fc to
7df2f8c
Compare
ItamarZand88
force-pushed
the
itamar/alien-75-sandbox-4-emitters
branch
from
August 11, 2026 17:11
7df2f8c to
57a8e1b
Compare
ItamarZand88
force-pushed
the
itamar/alien-75-sandbox-4-emitters
branch
from
August 11, 2026 17:28
57a8e1b to
07f5db1
Compare
ItamarZand88
force-pushed
the
itamar/alien-75-sandbox-4-emitters
branch
from
August 11, 2026 18:40
07f5db1 to
26ebf34
Compare
ItamarZand88
force-pushed
the
itamar/alien-75-sandbox-4-emitters
branch
from
August 11, 2026 18:49
26ebf34 to
897288c
Compare
ItamarZand88
force-pushed
the
itamar/alien-75-sandbox-4-emitters
branch
2 times, most recently
from
August 11, 2026 19:24
47f9964 to
96b985f
Compare
ItamarZand88
force-pushed
the
itamar/alien-75-sandbox-4-emitters
branch
from
August 11, 2026 19:49
96b985f to
1768f9a
Compare
ItamarZand88
force-pushed
the
itamar/alien-75-sandbox-4-emitters
branch
2 times, most recently
from
August 11, 2026 21:22
9f7d79b to
b55c83c
Compare
ItamarZand88
force-pushed
the
itamar/alien-75-sandbox-4-emitters
branch
from
August 11, 2026 21:26
b55c83c to
9669ebd
Compare
ItamarZand88
force-pushed
the
itamar/alien-75-sandbox-4-emitters
branch
2 times, most recently
from
August 11, 2026 22:24
c20d836 to
e80b966
Compare
ItamarZand88
force-pushed
the
itamar/alien-75-sandbox-4-emitters
branch
2 times, most recently
from
August 12, 2026 06:55
a42b21f to
9f36bd9
Compare
ItamarZand88
force-pushed
the
itamar/alien-75-sandbox-4-emitters
branch
from
August 12, 2026 07:05
9f36bd9 to
4bfcab4
Compare
ItamarZand88
force-pushed
the
itamar/alien-75-sandbox-4-emitters
branch
from
August 12, 2026 07:22
4bfcab4 to
80fbb66
Compare
ItamarZand88
force-pushed
the
itamar/alien-75-sandbox-4-emitters
branch
2 times, most recently
from
August 12, 2026 08:11
795dd3d to
d4c9b27
Compare
ItamarZand88
force-pushed
the
itamar/alien-75-sandbox-4-emitters
branch
2 times, most recently
from
August 12, 2026 09:15
3aa18ff to
94d2b6a
Compare
ItamarZand88
force-pushed
the
itamar/alien-75-sandbox-4-emitters
branch
from
August 12, 2026 11:01
94d2b6a to
2497a20
Compare
ItamarZand88
force-pushed
the
itamar/alien-75-sandbox-4-emitters
branch
from
August 12, 2026 11:18
2497a20 to
cc07594
Compare
ItamarZand88
force-pushed
the
itamar/alien-75-sandbox-4-emitters
branch
from
August 12, 2026 12:14
cc07594 to
1d0e8cd
Compare
ItamarZand88
force-pushed
the
itamar/alien-75-sandbox-4-emitters
branch
from
August 12, 2026 13:25
1d0e8cd to
9c1c4a2
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Renders the sandbox into the three packages a deployment installs from: the Terraform module, the CloudFormation template, and the Helm chart. Layer 3 declared what a sandbox may do; this builds the infrastructure it does it with.
On AWS, installing a sandbox creates the image its sessions launch from and the network path they are allowed:
On Kubernetes the same boundary is a NetworkPolicy; on GCP a sandbox is a subprocess of the workload's own instance and creates nothing.
What I did
Three things are worth pointing at, each of which was a deployment failure before it was a decision:
awsccprovider. The schema makesAdditionalOsCapabilitiesrequired and a sandbox asks for none of them;awsccdrops an empty list before sending, so creation returnedModel validation failed (#: required key [AdditionalOsCapabilities] not found)and no image was ever built. Cloud Control sends the body as written, so the property names here are the schema's own. The connector still goes throughawscc, which is what the provider requirement keys off.INTERNET_EGRESSconnector. Naming the deny connector there leaves the build with nowhere to reach a registry and the image never becomes active. A session's egress is the connector passed when it starts, which is still the deny one.Files touched
crates/alien-terraform/src/emitters/aws/sandbox.rsandgenerator.rs— the module.crates/alien-cloudformation/src/emitters/aws/sandbox.rs— the template.crates/alien-helm/src/emitters/sandbox.rs— the NetworkPolicy and the broker's cluster-scoped RBAC.How I tested
cargo test -p alien-terraform -p alien-cloudformation -p alien-helm— 315 tests, includingterraform validateon the rendered module andhelm lint/helm template/kubeconformon the chart.Security review of this diff, since it renders the IAM and the network path a customer installs:
Nothing turned up.