debian-forge-composer/internal/target/container_target.go
Tomáš Hozza 5b414a4516 Target: expose osbuild artifact information in target result
Add the information about osbuid artifact to the target result.
Specifically the name of the osbuild pipeline which was exported for the
specific target, and the filename of the exported file.

This will later enable embedding this information in Koji build metadata
to make it easy to reproduce the image build using the attached
manifest.
2023-09-27 12:39:28 +02:00

29 lines
813 B
Go

package target
const TargetNameContainer TargetName = "org.osbuild.container"
type ContainerTargetOptions struct {
Reference string `json:"reference"`
Username string `json:"username,omitempty"`
Password string `json:"password,omitempty"`
TlsVerify *bool `json:"tls_verify,omitempty"`
}
func (ContainerTargetOptions) isTargetOptions() {}
func NewContainerTarget(options *ContainerTargetOptions) *Target {
return newTarget(TargetNameContainer, options)
}
type ContainerTargetResultOptions struct {
URL string `json:"url"`
Digest string `json:"digest"`
}
func (ContainerTargetResultOptions) isTargetResultOptions() {}
func NewContainerTargetResult(options *ContainerTargetResultOptions, artifact *OsbuildArtifact) *TargetResult {
return newTargetResult(TargetNameContainer, options, artifact)
}