Documentation ¶
Index ¶
- type BuilderProvisioner
- type KubeVirtBuildProvisioner
- func (p *KubeVirtBuildProvisioner) GeneratePackerConfig() (*packer.GlobalBuildConfig, error)
- func (p *KubeVirtBuildProvisioner) Init() error
- func (p *KubeVirtBuildProvisioner) PostBuildAction() error
- func (p *KubeVirtBuildProvisioner) UpdatePackerBuilders(metadata map[string]string, data []byte) []byte
- type KubeVirtScanProvisioner
- type KubeVirtSignProvisioner
- type OpenStackBuildProvisioner
- func (p *OpenStackBuildProvisioner) GeneratePackerConfig() (*packer.GlobalBuildConfig, error)
- func (p *OpenStackBuildProvisioner) Init() error
- func (p *OpenStackBuildProvisioner) PostBuildAction() error
- func (p *OpenStackBuildProvisioner) UpdatePackerBuilders(metadata map[string]string, data []byte) []byte
- type OpenStackScanProvisioner
- type OpenStackSignProvisioner
- type ScannerProvisioner
- type SignerProvisioner
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BuilderProvisioner ¶
type BuilderProvisioner interface { Init() error GeneratePackerConfig() (*packer.GlobalBuildConfig, error) UpdatePackerBuilders(metadata map[string]string, data []byte) []byte PostBuildAction() error }
func NewBuilder ¶
func NewBuilder(o *flags.BuildOptions) BuilderProvisioner
NewBuilder returns a new provisioner based on the infra type that is used for building images.
type KubeVirtBuildProvisioner ¶
type KubeVirtBuildProvisioner struct {
Opts *flags.BuildOptions
}
KubeVirtBuildProvisioner contains the options for the build.
func (*KubeVirtBuildProvisioner) GeneratePackerConfig ¶
func (p *KubeVirtBuildProvisioner) GeneratePackerConfig() (*packer.GlobalBuildConfig, error)
GeneratePackerConfig generates a packer vars file for KubeVirt builds.
func (*KubeVirtBuildProvisioner) Init ¶
func (p *KubeVirtBuildProvisioner) Init() error
Init currently has no action
func (*KubeVirtBuildProvisioner) PostBuildAction ¶
func (p *KubeVirtBuildProvisioner) PostBuildAction() error
PostBuildAction will upload the image to S3 if the option is enabled. It will then deploy a DataVolume to the cluster referencing the S3 endpoint.
If the S3 endpoint is not enabled then it will just print out the location of the file.
func (*KubeVirtBuildProvisioner) UpdatePackerBuilders ¶
func (p *KubeVirtBuildProvisioner) UpdatePackerBuilders(metadata map[string]string, data []byte) []byte
UpdatePackerBuilders currently has no action
type KubeVirtScanProvisioner ¶
type KubeVirtScanProvisioner struct {
Opts *flags.ScanOptions
}
KubeVirtScanProvisioner
func (*KubeVirtScanProvisioner) ScanImages ¶
func (s *KubeVirtScanProvisioner) ScanImages() error
ScanImages
type KubeVirtSignProvisioner ¶
type KubeVirtSignProvisioner struct {
Opts *flags.SignOptions
}
KubeVirtSignProvisioner
func (*KubeVirtSignProvisioner) SignImage ¶
func (s *KubeVirtSignProvisioner) SignImage(digest string) error
SignImage
func (*KubeVirtSignProvisioner) ValidateImage ¶
func (s *KubeVirtSignProvisioner) ValidateImage(key []byte) error
ValidateImage
type OpenStackBuildProvisioner ¶
type OpenStackBuildProvisioner struct {
Opts *flags.BuildOptions
}
OpenStackBuildProvisioner contains the options for the build.
func (*OpenStackBuildProvisioner) GeneratePackerConfig ¶
func (p *OpenStackBuildProvisioner) GeneratePackerConfig() (*packer.GlobalBuildConfig, error)
GeneratePackerConfig generates a packer vars file for OpenStack builds.
func (*OpenStackBuildProvisioner) Init ¶
func (p *OpenStackBuildProvisioner) Init() error
Init will set an ENV VAR so that the OpenStack builder knows which cloud to use.
func (*OpenStackBuildProvisioner) PostBuildAction ¶
func (p *OpenStackBuildProvisioner) PostBuildAction() error
PostBuildAction retrieves the image ID from the output and stores it into a file.
func (*OpenStackBuildProvisioner) UpdatePackerBuilders ¶
func (p *OpenStackBuildProvisioner) UpdatePackerBuilders(metadata map[string]string, data []byte) []byte
UpdatePackerBuilders will update the builders field with the metadata values as required. This is done this way as passing it in via Packer vars is prone to error or just complete failures.
type OpenStackScanProvisioner ¶
type OpenStackScanProvisioner struct { Opts *flags.ScanOptions // contains filtered or unexported fields }
OpenStackScanProvisioner contains the parameters required for scanning images.
func (*OpenStackScanProvisioner) Prepare ¶
func (s *OpenStackScanProvisioner) Prepare() error
Prepare the requirements for scanning images. this includes setting up the OpenStack clients so that communication with OpenStack is successful.
func (*OpenStackScanProvisioner) ScanImages ¶
func (s *OpenStackScanProvisioner) ScanImages() error
ScanImages will parse the input of imageID or wildcard to determine whether a single or multiple scan needs to occur. The image is then scanned and the results uploaded to S3.
type OpenStackSignProvisioner ¶
type OpenStackSignProvisioner struct {
Opts *flags.SignOptions
}
OpenStackSignProvisioner contains the parameters required for signing images.
func (*OpenStackSignProvisioner) SignImage ¶
func (s *OpenStackSignProvisioner) SignImage(digest string) error
SignImage will take the digest of the signing process and tag the image with the appropriate metadata field.
func (*OpenStackSignProvisioner) ValidateImage ¶
func (s *OpenStackSignProvisioner) ValidateImage(key []byte) error
ValidateImage can validate the signing of an image using the supplied key. It will search for the digest metadata/property on the image and attempt to validate it.
type ScannerProvisioner ¶
func NewScanner ¶
func NewScanner(o *flags.ScanOptions) ScannerProvisioner
type SignerProvisioner ¶
func NewSigner ¶
func NewSigner(o *flags.SignOptions) SignerProvisioner