Documentation
¶
Overview ¶
Package proposalrpc is the ProposalService (proto/mistgate/proposal/v1): what the owner sees and decides about the panel's proposals, and the modes of automation. It carries nothing out: Accept only moves a proposal from awaiting to applying and wakes the executor (internal/panel/app), which is the one that makes the change. The roles that serve the admin API plug the handler in with app.Config.ProposalAPI; the Workers that do not (link, public) never link it.
Who may call what is the table of internal/panel/auth (policy_proposal.go): the two reads are any admin's and open to API tokens; accepting, rejecting, reverting and setting a mode are the owner's, signed in, and every handler refuses a token, the assistant and a scheduled task again (auth.OwnerSession). Choosing AUTO also needs a fresh step-up. No address of a server is in a value of this API, in an audit row or in a log line: a proposal has none (store.ErrProposalAddress).
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct {
Store *store.Store
StepUp func(context.Context) error // a fresh step-up, asked for to choose AUTO
Kick func() // wakes the executor after an accept or a revert (the VPS loop); nil = nothing waits
Log *slog.Logger
Now func() time.Time
}
Config configures Service. Store and StepUp are required; the rest has defaults.