Documentation
¶
Overview ¶
Package tools provides the tailkitd tool registry. It reads tool registration files from /etc/tailkitd/tools/ on every GET /tools request so that installs and upgrades are reflected immediately without a tailkitd restart.
Index ¶
Constants ¶
View Source
const DefaultToolsDir = "/etc/tailkitd/tools"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Registry ¶
type Registry struct {
// contains filtered or unexported fields
}
Registry reads tool registration files and serves the GET /tools endpoint. It reads from disk on every request so installs and upgrades are live.
func NewRegistry ¶
NewRegistry constructs a Registry that reads from the given directory. Pass defaultToolsDir ("/etc/tailkitd/tools") in production.
func (*Registry) Handler ¶
func (r *Registry) Handler() http.HandlerFunc
Handler returns an http.HandlerFunc for GET /tools. It lists all registered tools and responds with JSON.
Click to show internal directories.
Click to hide internal directories.