Documentation
¶
Overview ¶
Package guardenrollment reads the Techstack Guard enrollment of this node: the server and worker the Guard was enrolled for. StackKits never imports Techstack; it reads the enrollment file the Guard keeps on the host, so a credential or a link can be bound to this node's own Guard identity and never to one a request names.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrAbsent = errors.New("guardenrollment: this node has no Techstack Guard enrollment")
ErrAbsent means this node has no readable Guard enrollment.
View Source
var Paths = []string{
"/etc/techstack/agent-enrollment.json",
"/var/lib/techstack/guard/agent-enrollment.json",
}
Paths are where a Guard keeps its enrollment; the first readable one wins.
Functions ¶
This section is empty.
Types ¶
type Enrollment ¶
Enrollment is the Guard identity of this node.
func Read ¶
func Read() (Enrollment, error)
Read returns the Guard enrollment of this node, or ErrAbsent.
func (Enrollment) Identity ¶
func (e Enrollment) Identity() string
Identity is the Guard identity as one string: "guard:<server>/<worker>".
Click to show internal directories.
Click to hide internal directories.