Documentation
¶
Index ¶
- Variables
- func Names() (names []string)
- func Register(provider Provider)
- type Config
- func (c Config) DelConfig(f *resource.Fetcher) error
- func (c Config) Fetch(f *resource.Fetcher, state *state.State) (types.Config, report.Report, error)
- func (c Config) Init(f *resource.Fetcher) error
- func (c Config) Name() string
- func (c Config) NewFetcher(l *log.Logger) (resource.Fetcher, error)
- func (c Config) Status(stageName string, f resource.Fetcher, statusErr error) error
- type Name
- type Provider
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrCannotDelete = errors.New("cannot delete config on this platform") ErrNoProvider = errors.New("config provider was not online") )
Functions ¶
Types ¶
type Config ¶
type Config struct {
// contains filtered or unexported fields
}
Config defines the capabilities of a particular platform, for use by the rest of Ignition.
func NewConfig ¶ added in v2.16.0
Helper function for wrapping a Provider, for use by specialized providers that don't want to add themselves to the registry.
func (Config) Init ¶ added in v2.16.0
Init performs additional fetcher configuration post-config fetch. This ensures that networking is already available if a platform needs to reach out to the metadata service to fetch additional options / data.
func (Config) NewFetcher ¶ added in v2.16.0
type Name ¶
type Name string
Name is used to identify an platform. It must be in the set of registered platforms.
type Provider ¶ added in v2.16.0
type Provider struct { Name string NewFetcher func(logger *log.Logger) (resource.Fetcher, error) Fetch func(f *resource.Fetcher) (types.Config, report.Report, error) Init func(f *resource.Fetcher) error Status func(stageName string, f resource.Fetcher, e error) error DelConfig func(f *resource.Fetcher) error // Fetch, and also save output files to be written during files stage. // Avoid, unless you're certain you need it. FetchWithFiles func(f *resource.Fetcher) ([]types.File, types.Config, report.Report, error) }
Provider is the struct that platform implementations use to define their capabilities for use by this package.
Click to show internal directories.
Click to hide internal directories.