localhost:3000 or an internal
staging host. A tunnel exposes one or more hostname:port addresses from your
machine to a single Mo session through a Momentic Connector. Start the tunnel,
pass its ID to mo start --tunnel, and stop
it when the session is done.
tunnel start
Start a tunnel to one or more addresses.string
required
One or more
hostname:port addresses reachable from this machine.flag
Keep the tunnel attached to the terminal and run until you press
Ctrl+C. By
default the tunnel detaches and keeps running in the background.tunnel stop
Stop a tunnel and revoke Mo’s access to it.{ "tunnelId": "..." }.
tunnel list
List tunnels started from this machine.status is starting, running, unreachable (the state file exists but the
process does not respond), or cleanup_failed (the process exited without
revoking the tunnel; run mo tunnel stop to finish cleanup).
Example: test a local dev server
Notes
- Tunnel state lives in
~/.momentic/mo-tunnels.mo tunnel listonly shows tunnels started from this machine. - One tunnel can serve several addresses; start it with every host Mo needs before you create the session.
- A background tunnel outlives your shell. Stop it explicitly, or it stays open until you do.