How it works
You bring a domain you own (for examplesandbox.acme.com), and Porter provisions a load balancer and a wildcard HTTPS certificate for it on your sandbox cluster. A cluster supports two kinds of networking, each with its own domain:
Enable public networking, private networking, or both. Each sandbox that opens a port is served at a hostname one label under the configured domain, such as
my-app.sandbox.acme.com, with TLS handled by the wildcard certificate.
What sandboxes can reach
Sandboxes run untrusted code, so their outbound traffic is isolated by default, whether or not networking is configured. A sandbox can resolve DNS and reach the public internet, and nothing else:
Because private address space is blocked, this includes services behind a private load balancer. If a sandbox needs to call a service you run on the same cluster, either expose that service on a public domain and call it over the internet, or give the sandbox an egress allowlist that includes the service’s cluster-internal hostname (see below).
Restrict egress with an allowlist
Beyond the default isolation, a sandbox can be limited to an explicit list of outbound destinations. Passegress when creating a sandbox and it can only reach the destinations it lists; all other outbound traffic is blocked. Enforcement happens transparently at the network layer, so any protocol and client works without proxy configuration.
Egress enforcement is off by default. To turn it on for a cluster, go to the Sandbox tab, open Settings, and enable Enforce egress allowlists under Egress controls. This installs network policy enforcement on the sandbox nodes. Sandboxes created without an egress entry keep unrestricted internet access even when enforcement is on.
allowed_destinations entry is one of:
An empty list denies all egress. DNS resolution keeps working inside the sandbox so hostname entries can be resolved and enforced.
CIDR entries are honored as written, including private address space, so an allowlist can deliberately grant a sandbox access to internal IPs that the default isolation blocks.
A Service entry is how a restricted sandbox reaches another workload on its own cluster: an entry of the form
name.namespace.svc.cluster.local allows traffic to that Service’s backing pods and tracks them as they change, so a rolling deploy of the Service doesn’t interrupt connectivity. Service entries aren’t scoped to a port; any port on the backing pods is allowed.
Configure networking on the cluster
1
Open the sandbox networking settings
In the Porter Dashboard, go to the Sandbox tab for your sandbox-enabled cluster, then open Settings. The Public and Private networking sections each have their own toggle.
2
Set the domain
Enable the kind of networking you want and enter the domain sandbox hostnames should be minted under, for example
sandbox.acme.com for public networking or internal.sandbox.acme.com for private. Each needs its own domain.3
Connect your DNS provider
Porter issues the wildcard certificate through a Let’s Encrypt DNS-01 challenge, which needs access to the DNS zone that contains your domain.Cloudflare: create an API token and paste it into the networking settings.
- In the Cloudflare dashboard, go to your profile icon > My Profile > API Tokens (or directly at dash.cloudflare.com/profile/api-tokens) and click Create Token.
- Use the Edit zone DNS template. It grants the one permission Porter needs: Zone / DNS / Edit.
- Under Zone Resources, scope the token to Include / Specific zone and select the zone that contains your sandbox domain (the zone
acme.comfor a domain likesandbox.acme.com). - Continue to the summary, create the token, and copy it. Cloudflare shows the token value only once.
- Paste it into the section’s API token field in Porter and save.
4
Create the wildcard DNS record
Save the settings, then wait for the load balancer to provision. The settings page shows the record target and type once it’s ready: create a DNS record for
*.<your domain> (for example *.sandbox.acme.com) pointing at that address.For private networking, the load balancer address only resolves to something reachable from inside your VPC. Point your own private DNS at it if your clients resolve through one; certificates are still issued automatically either way.Expose a port from a sandbox
Passnetworking when creating a sandbox. A sandbox with no networking entry exposes nothing. Currently one entry is supported, and its port is required (1024-65535; privileged ports are not allowed):
<name>.<your domain> (falling back to <id>.<your domain> when the sandbox has no name), publicly when public networking is configured on the cluster, otherwise privately.
Choose the hostname and visibility
Add adomains entry to control where the port is served. Currently one entry is supported:
Find the sandbox URL
The sandbox’s status includeshost, the hostname it’s reachable at. It’s empty when the sandbox exposes no port or the cluster has no networking configured:

