Skip to main content
A User Service is an automatically managed process on Zo Computer that has a public endpoint. These registered services will be restarted if they crash, and they will persist across restarts of Zo Computer. They are intended for long-running services that you want to expose via a public URL or TCP address (web/API servers, databases, SSH server, etc). Services should bind to the PORT environment variable.

Parameters

label
string
required
unique label (per host) for the service. lowercase and hyphens allowed. e.g. “my-web-app”
protocol
string
required
“http” or “tcp”.
local_port
number
required
Localhost port to expose (1024-65535, injected as the PORT env var).
entrypoint
string
Optional command to run the service, e.g. “python3 -m http.server $PORT”. If omitted, only the tunnel is managed.
workdir
string
Optional working directory for the service. (defaults to /home/workspace)
env_vars
object
Optional environment variables (PORT will be overridden).