tunnelctl
CLI

env

Inspect the active profile and the environment variables that override it.

tunnelctl env prints the resolved profile — the set of endpoints the CLI talks to — and shows which TUNNELCTL_* environment variable overrides each value.

tunnelctl env

Profile values

The defaults are baked into the binary; any of them can be overridden with an environment variable:

Env varDefaultPurpose
TUNNELCTL_API_URLserver API base URLControl-plane API endpoint
TUNNELCTL_FRPS_ADDRtunnel edge hostFRP server hostname
TUNNELCTL_FRPS_PORT443FRP server port
TUNNELCTL_FRPS_PROTOCOLwssTransport (tcp, websocket, wss, …)
TUNNELCTL_PUBLIC_DOMAINtunnelctl.euPublic DNS suffix for slugs
TUNNELCTL_OIDC_ISSUERIdP realm URLOIDC issuer
TUNNELCTL_OIDC_CLIENTtunnelctl-cliOAuth2 public client ID

Targeting another environment

Override the profile to point the CLI at, say, a test environment:

export TUNNELCTL_API_URL=https://tunnelctl-server.test.svc.piblade.net
export TUNNELCTL_FRPS_ADDR=tun-test.example.com
tunnelctl login          # fresh token from the test issuer
tunnelctl up myapp 8080  # runs against the test control plane

Re-authenticate after switching

Changing TUNNELCTL_OIDC_ISSUER or the API URL points the CLI at a different identity provider — log in again so it mints a token for that environment.

On this page