Documentation
¶
Overview ¶
Package pluginhost launches out-of-process plugin binaries (<pluginsDir>/<name>/plugin), each listening on a private unix socket, and reverse-proxies their HTTP routes.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Host ¶
type Host struct {
// contains filtered or unexported fields
}
func (*Host) Builtin ¶
Builtin registers a plugin shipped inside the agent, launched by running the given command (typically the agent re-execing itself with a subcommand). Call before Start.
func (*Host) ExecTool ¶
ExecTool invokes a tool on a running plugin over its socket and returns the textual result.
func (*Host) Proxy ¶
func (h *Host) Proxy(name string) (*httputil.ReverseProxy, bool)
Proxy returns a running plugin's reverse proxy. The caller must set the request path relative to the plugin (strip the /plugin/<name> prefix) before serving.
Click to show internal directories.
Click to hide internal directories.