Expose a service
rc-tunnel gives an HTTP or WebSocket service running inside your notebook a public URL, so you can share a demo or hit it from outside the platform.
Before you start
Section titled “Before you start”- Only HTTP and WebSocket services bound to
127.0.0.1inside the notebook are supported. - The local port must be between
1024and65535, and must not be reserved by the platform. - One port per notebook pod at a time.
- The domain is assigned by the platform as
rc-<random>.radeon.firstdg.ai. Custom domains aren’t supported. - Only notebooks created after the feature was enabled can use it. Older pods need to be destroyed and recreated.
Install
Section titled “Install”In a notebook terminal:
/var/run/secrets/frp-self-service/installThis installs rc-tunnel to $HOME/.local/bin and adds it to PATH for future terminals. In the terminal you’re already in, call it by full path.
If the install script reports that the identity directory or FRP_BROKER_URL is missing, the notebook predates the feature. Destroy it and create a new one. Don’t try to write platform keys yourself.
New terminals can run rc-tunnel directly. If you’re not using bash:
export PATH="$HOME/.local/bin:$PATH"Start something to expose
Section titled “Start something to expose”A quick test page to confirm the path works end to end:
mkdir -p "$HOME/tunnel-demo"printf '%s\n' '<!doctype html><title>RC Tunnel</title><h1>RC Tunnel is working</h1>' \ > "$HOME/tunnel-demo/index.html"nohup python3 -m http.server 8081 --bind 127.0.0.1 \ --directory "$HOME/tunnel-demo" \ > "$HOME/tunnel-demo/http.log" 2>&1 &curl --fail http://127.0.0.1:8081/Expose the port
Section titled “Expose the port”"$HOME/.local/bin/rc-tunnel" expose --port 8081The command requests an available domain and returns the assigned URL along with the FRPC process ID. It’s usually reachable within a few seconds:
https://rc-0123456789abcdef.radeon.firstdg.aiThe --prefix flag exists for operations compatibility; regular users don’t need it.
Check and diagnose
Section titled “Check and diagnose”"$HOME/.local/bin/rc-tunnel" status"$HOME/.local/bin/rc-tunnel" logs --lines 100curl --fail http://127.0.0.1:8081/Work through it in this order:
- Local
curlfails. Your application isn’t listening on that port. Nothing to do with the tunnel — fix the service first. statusshows FRPC not running. Readrc-tunnel logs.- Status is healthy but the public URL fails. Send operations the full domain, when the notebook was created, and when the failure happened. Don’t send config files or keys.
"$HOME/.local/bin/rc-tunnel" stopThe public URL stops working immediately, and the domain prefix is frozen for 24 hours. If FRPC or the pod is killed instead, the server usually notices the closed connection right away; tunnels that never connected are revoked after 60 seconds without a heartbeat.
Not supported
Section titled “Not supported”TCP, UDP, SSH, and database ports. Custom full domains.
Don’t edit ~/.local/state/rc-tunnel/frpc.toml by hand, and don’t copy that directory to another pod or share it — it holds your tunnel identity. After recreating a notebook, install and expose again.