Documentation
¶
Overview ¶
Package domainqueue is the bounded certificate-specific host mailbox. It transports approved domain intent and private staged imports, never commands.
Index ¶
- Constants
- Variables
- type Input
- type Queue
- func (q *Queue) Claim() (Request, error)
- func (q *Queue) Enqueue(input Input, actorID string) (Status, error)
- func (q *Queue) File(name string) string
- func (q *Queue) Finish(r Request, err error) error
- func (q *Queue) HasRequest() bool
- func (q *Queue) ImportFiles(id string) (string, string, error)
- func (q *Queue) ReadInventory(value any) error
- func (q *Queue) Ready() bool
- func (q *Queue) Record(r Request, state, stage, failure string) error
- func (q *Queue) RecoverInterrupted() error
- func (q *Queue) RemoveImport(id string) error
- func (q *Queue) Stage(cert, key []byte) (string, error)
- func (q *Queue) Status() (Status, error)
- func (q *Queue) WriteInventory(value any) error
- type Request
- type Status
Constants ¶
View Source
const Schema = 1
Variables ¶
View Source
var ErrBusy = errors.New("domain operation is active")
View Source
var ErrInvalid = errors.New("domain request is invalid")
Functions ¶
This section is empty.
Types ¶
type Input ¶
type Input struct {
Operation string `json:"operation"` // configure, renew, remove, inspect, recover
Role domaintls.Role `json:"role,omitempty"`
Origin string `json:"origin,omitempty"`
Method domaintls.Method `json:"method,omitempty"`
ExpectedRevision string `json:"expected_revision,omitempty"`
StageID string `json:"stage_id,omitempty"`
CertSource string `json:"cert_source,omitempty"`
KeySource string `json:"key_source,omitempty"`
Email string `json:"email,omitempty"`
Challenge string `json:"challenge,omitempty"`
}
type Queue ¶
type Queue struct {
Dir string
// contains filtered or unexported fields
}
func (*Queue) HasRequest ¶
func (*Queue) ReadInventory ¶
Reports are fixed host view models; private staged material never enters them.
func (*Queue) RecoverInterrupted ¶
RecoverInterrupted is called only after the host runner's cross-process lock. An interrupted queue never implies retrying destructive work automatically.
func (*Queue) RemoveImport ¶
func (*Queue) WriteInventory ¶
type Status ¶
type Status struct {
Schema int `json:"schema"`
ID string `json:"id"`
State operation.State `json:"state"`
Stage string `json:"stage"`
Failure string `json:"failure,omitempty"`
UpdatedAt time.Time `json:"updated_at"`
Role domaintls.Role `json:"role,omitempty"`
Origin string `json:"origin,omitempty"`
}
Click to show internal directories.
Click to hide internal directories.