Directories
¶
| Path | Synopsis |
|---|---|
|
cmd
|
|
|
porthole
command
Command porthole exposes local services through a porthole server.
|
Command porthole exposes local services through a porthole server. |
|
portholed
command
Command portholed is the porthole server.
|
Command portholed is the porthole server. |
|
internal
|
|
|
adminapi
Package adminapi is the server's management API (ADR 0005): HTTP+JSON over a local unix socket (access is the file permission, full admin) and over the public listener under Prefix (bearer token with admin:* scopes).
|
Package adminapi is the server's management API (ADR 0005): HTTP+JSON over a local unix socket (access is the file permission, full admin) and over the public listener under Prefix (bearer token with admin:* scopes). |
|
auth
Package auth implements porthole client tokens: `ph_<id>_<secret>`.
|
Package auth implements porthole client tokens: `ph_<id>_<secret>`. |
|
cli/clientcmd
Package clientcmd implements the command line of the porthole client binary.
|
Package clientcmd implements the command line of the porthole client binary. |
|
cli/exitcode
Package exitcode defines the process exit statuses of porthole and portholed, and runs a cobra command tree so that every failure ends in one of them (and, with --json, in an error document on stdout).
|
Package exitcode defines the process exit statuses of porthole and portholed, and runs a cobra command tree so that every failure ends in one of them (and, with --json, in an error document on stdout). |
|
cli/jsonout
Package jsonout implements the --json mode shared by the porthole and portholed command lines.
|
Package jsonout implements the --json mode shared by the porthole and portholed command lines. |
|
cli/servercmd
Package servercmd provides the `portholed serve` command.
|
Package servercmd provides the `portholed serve` command. |
|
cli/tokencmd
Package tokencmd implements "portholed token create|list|revoke".
|
Package tokencmd implements "portholed token create|list|revoke". |
|
client
Package client implements the porthole client: one outbound session to the server, tunnel registration, forwarding of data streams to local targets, and reconnection with exponential backoff.
|
Package client implements the porthole client: one outbound session to the server, tunnel registration, forwarding of data streams to local targets, and reconnection with exponential backoff. |
|
clientconfig
Package clientconfig loads and validates the client tunnels file (tunnels.yaml): a list of named tunnels that the porthole client daemon (or `porthole start`) keeps up.
|
Package clientconfig loads and validates the client tunnels file (tunnels.yaml): a list of named tunnels that the porthole client daemon (or `porthole start`) keeps up. |
|
config
Package config loads and validates the portholed server configuration (DESIGN.md §3.9).
|
Package config loads and validates the portholed server configuration (DESIGN.md §3.9). |
|
daemon
Package daemon is the porthole client daemon: one long-lived session to the server carrying a mutable set of tunnels, controlled over the local API (internal/localapi) and by the tunnels file (internal/clientconfig).
|
Package daemon is the porthole client daemon: one long-lived session to the server carrying a mutable set of tunnels, controlled over the local API (internal/localapi) and by the tunnels file (internal/clientconfig). |
|
localapi
Package localapi is the local control API of the porthole client daemon: HTTP/1.1 + JSON over a unix domain socket (see docs/adr/0002-client-daemon-and-tunnels-file.md).
|
Package localapi is the local control API of the porthole client daemon: HTTP/1.1 + JSON over a unix domain socket (see docs/adr/0002-client-daemon-and-tunnels-file.md). |
|
mcp/client
Package client is the MCP server of an agent on a client machine (ADR 0005, surface B): `porthole mcp` serves tools that open and close tunnels through the local daemon.
|
Package client is the MCP server of an agent on a client machine (ADR 0005, surface B): `porthole mcp` serves tools that open and close tunnels through the local daemon. |
|
mcp/server
Package server is the operator MCP server (ADR 0005, surface A): the tools an agent uses to look after a porthole server.
|
Package server is the operator MCP server (ADR 0005, surface A): the tools an agent uses to look after a porthole server. |
|
metrics
Package metrics holds the Prometheus instrumentation of portholed and the HTTP handler that serves it together with the Go profiler.
|
Package metrics holds the Prometheus instrumentation of portholed and the HTTP handler that serves it together with the Go profiler. |
|
proto
Package proto implements the porthole control protocol described in docs/protocol.md: length-prefixed JSON frames exchanged on the control stream and at the start of data streams.
|
Package proto implements the porthole control protocol described in docs/protocol.md: length-prefixed JSON frames exchanged on the control stream and at the start of data streams. |
|
server
Package server implements portholed: it accepts client sessions over WebSocket+yamux (docs/protocol.md), keeps the registry of tunnels and routes public HTTP and TCP traffic into them (DESIGN.md §3.5).
|
Package server implements portholed: it accepts client sessions over WebSocket+yamux (docs/protocol.md), keeps the registry of tunnels and routes public HTTP and TCP traffic into them (DESIGN.md §3.5). |
|
store
Package store persists server state: client tokens (v0.1) and port reservations (v0.2).
|
Package store persists server state: client tokens (v0.1) and port reservations (v0.2). |
|
traffic
Package traffic keeps the in-memory journal of proxied HTTP requests and tunnel connections (ADR 0005).
|
Package traffic keeps the in-memory journal of proxied HTTP requests and tunnel connections (ADR 0005). |
|
transport
Package transport provides the multiplexed session between a porthole client and server.
|
Package transport provides the multiplexed session between a porthole client and server. |
Click to show internal directories.
Click to hide internal directories.