Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Manifold ¶
func Manifold(config ManifoldConfig) dependency.Manifold
Manifold returns a dependency.Manifold to run a worker to hold the http server mux and authenticator. This means that we can ensure that all workers that need to register with them can be finished starting up before the httpserver responds to connections.
func NewStateAuthenticator ¶
func NewStateAuthenticator( statePool *state.StatePool, mux *apiserverhttp.Mux, clock clock.Clock, abort <-chan struct{}, ) (macaroon.LocalMacaroonAuthenticator, error)
NewStateAuthenticator returns a new LocalMacaroonAuthenticator that authenticates users and agents using the given state pool. The authenticator will register handlers into the mux for dealing with local macaroon logins.
Types ¶
type ManifoldConfig ¶
type ManifoldConfig struct { ClockName string ControllerPortName string StateName string NewStateAuthenticator NewStateAuthenticatorFunc }
ManifoldConfig holds the resources needed to run an httpserverargs worker.
func (ManifoldConfig) Validate ¶
func (config ManifoldConfig) Validate() error
Validate checks that we have all of the things we need.
type NewStateAuthenticatorFunc ¶
type NewStateAuthenticatorFunc func( statePool *state.StatePool, mux *apiserverhttp.Mux, clock clock.Clock, abort <-chan struct{}, ) (macaroon.LocalMacaroonAuthenticator, error)
NewStateAuthenticatorFunc is a function type satisfied by NewStateAuthenticator.