Documentation
¶
Overview ¶
Package swarms resolves an application's destination to something that can apply to it.
This is the seam Phase 3 replaces with multi-swarm through swarmcli-rbac-proxy. Per D2 the OSS default resolves exactly one swarm: the one this controller runs in, reached over the docker.sock it is mounted with.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Registry ¶
type Registry interface {
// Backend returns the backend for the named swarm. The empty name means
// the swarm this controller runs in.
//
// Implementations return the same backend for the same name rather than
// reconnecting per call: the reconcile loop asks on every tick.
Backend(ctx context.Context, swarm string) (charts.Backend, error)
}
Registry resolves a swarm name to a backend.
It hands back a charts.Backend rather than an interface of our own. swarmcli-cd is built on the chart engine — charts.NewEngineWith takes any Backend, which is what makes a controller-supplied applier possible at all — and a fourteen-method pass-through would buy nothing but a second definition to keep in step with CE's.