Install the SDK, or the CLI for
ppio commands, and set the PPIO_API_KEY and PPIO_DOMAIN environment variables before running these examples. See Quickstart and Install and authenticate.Toggle internet access
When creating a sandbox, use theallowInternetAccess or allow_internet_access parameter to configure internet connectivity. Internet access is turned on by default, and can be disabled for workloads with stricter security requirements.
Fine-grained network control
Network configuration gives finer-grained control over outbound traffic through allowlists and denylists.
Set these options when creating the sandbox.
Expose a service through the sandbox URL
Services in a sandbox can be reached through the sandbox URL for a port.Connect to a server inside the sandbox
Start a server in the background, read its sandbox URL, then request the URL from outside the sandbox.1
Start a server in the background
2
Read its sandbox URL
3
Request the URL from outside the sandbox
Full example
Mask request Host headers
Use themaskRequestHost or mask_request_host option to customize the Host header sent to services running inside the sandbox.