Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrNoHosts indicates that no hosts have been set up. ErrNoHosts = errors.New("no hosts configured") )
Functions ¶
func Initialize ¶
Initialize ensures that outside dependencies needed on every execution of saturn-bot are set up. Such dependencies can be logging or directories.
Types ¶
type ActionFactories ¶
type FilterFactories ¶
type Opts ¶
type Opts struct { ActionFactories ActionFactories // Clock interfaces to a clock. // Its purpose is to fake time in unit tests. // Defaults to an object that proxies to the [time] package. Clock clock.Clock Config config.Configuration FilterFactories FilterFactories Hosts []host.Host IsCi bool SkipPlugins bool PushGateway *push.Pusher PrometheusGatherer prometheus.Gatherer PrometheusRegisterer prometheus.Registerer // contains filtered or unexported fields }
func ToOptions ¶
func ToOptions(c config.Configuration) (Opts, error)
ToOptions takes a configuration struct, initializes global state and returns an Options struct that can be modified further, if needed.
func (*Opts) RepositoryCacheTtl ¶ added in v0.18.0
func (*Opts) SetPrometheusRegistry ¶ added in v0.16.0
func (o *Opts) SetPrometheusRegistry(reg *prometheus.Registry)
func (Opts) WorkerLoopInterval ¶ added in v0.8.0
Click to show internal directories.
Click to hide internal directories.