manifest: use container SourceSpec instead of Spec
When creating a Manifest object, collect container SourceSpecs instead of resolved Specs. This is the same way we handle packages: The blueprint option is converted to source specs and attached to the Manifest object during creation. Later, the SourceSpecs will be resolved to full container Specs and used during serialization.
This commit is contained in:
parent
955e343122
commit
b1f185959b
9 changed files with 72 additions and 50 deletions
|
|
@ -23,7 +23,7 @@ import (
|
|||
func osCustomizations(
|
||||
t *imageType,
|
||||
osPackageSet rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
c *blueprint.Customizations) manifest.OSCustomizations {
|
||||
|
||||
imageConfig := t.getDefaultImageConfig()
|
||||
|
|
@ -199,7 +199,7 @@ func liveImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
img := image.NewLiveImage()
|
||||
|
|
@ -224,7 +224,7 @@ func containerImage(workload workload.Workload,
|
|||
c *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
img := image.NewBaseContainer()
|
||||
|
||||
|
|
@ -243,7 +243,7 @@ func imageInstallerImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
img := image.NewImageInstaller()
|
||||
|
|
@ -287,7 +287,7 @@ func iotCommitImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
img := image.NewOSTreeArchive(options.OSTree.ImageRef)
|
||||
|
|
@ -317,7 +317,7 @@ func iotContainerImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
img := image.NewOSTreeContainer(options.OSTree.ImageRef)
|
||||
|
|
@ -350,7 +350,7 @@ func iotInstallerImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
d := t.arch.distro
|
||||
|
|
@ -392,7 +392,7 @@ func iotRawImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
commit := ostree.CommitSpec{
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ import (
|
|||
"golang.org/x/exp/slices"
|
||||
)
|
||||
|
||||
type imageFunc func(workload workload.Workload, t *imageType, customizations *blueprint.Customizations, options distro.ImageOptions, packageSets map[string]rpmmd.PackageSet, containers []container.Spec, rng *rand.Rand) (image.ImageKind, error)
|
||||
type imageFunc func(workload workload.Workload, t *imageType, customizations *blueprint.Customizations, options distro.ImageOptions, packageSets map[string]rpmmd.PackageSet, containers []container.SourceSpec, rng *rand.Rand) (image.ImageKind, error)
|
||||
|
||||
type packageSetFunc func(t *imageType) rpmmd.PackageSet
|
||||
|
||||
|
|
@ -174,7 +174,7 @@ func (t *imageType) PackageSets(bp blueprint.Blueprint, options distro.ImageOpti
|
|||
/* #nosec G404 */
|
||||
rng := rand.New(source)
|
||||
|
||||
img, err := t.image(w, t, bp.Customizations, options, packageSets, containers, rng)
|
||||
img, err := t.image(w, t, bp.Customizations, options, packageSets, nil, rng)
|
||||
if err != nil {
|
||||
logrus.Errorf("Initializing the manifest failed for %s (%s/%s): %v", t.Name(), t.arch.distro.Name(), t.arch.Name(), err)
|
||||
return nil
|
||||
|
|
@ -309,12 +309,17 @@ func (t *imageType) Manifest(bp *blueprint.Blueprint,
|
|||
w = cw
|
||||
}
|
||||
|
||||
containerSources := make([]container.SourceSpec, len(bp.Containers))
|
||||
for idx := range bp.Containers {
|
||||
containerSources[idx] = container.SourceSpec(bp.Containers[idx])
|
||||
}
|
||||
|
||||
source := rand.NewSource(seed)
|
||||
// math/rand is good enough in this case
|
||||
/* #nosec G404 */
|
||||
rng := rand.New(source)
|
||||
|
||||
img, err := t.image(w, t, bp.Customizations, options, staticPackageSets, containers, rng)
|
||||
img, err := t.image(w, t, bp.Customizations, options, staticPackageSets, containerSources, rng)
|
||||
if err != nil {
|
||||
return nil, nil, err
|
||||
}
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ func osCustomizations(
|
|||
t *imageType,
|
||||
osPackageSet rpmmd.PackageSet,
|
||||
options distro.ImageOptions,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
c *blueprint.Customizations,
|
||||
) manifest.OSCustomizations {
|
||||
|
||||
|
|
@ -221,7 +221,7 @@ func liveImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
img := image.NewLiveImage()
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ import (
|
|||
|
||||
type packageSetFunc func(t *imageType) rpmmd.PackageSet
|
||||
|
||||
type imageFunc func(workload workload.Workload, t *imageType, customizations *blueprint.Customizations, options distro.ImageOptions, packageSets map[string]rpmmd.PackageSet, containers []container.Spec, rng *rand.Rand) (image.ImageKind, error)
|
||||
type imageFunc func(workload workload.Workload, t *imageType, customizations *blueprint.Customizations, options distro.ImageOptions, packageSets map[string]rpmmd.PackageSet, containers []container.SourceSpec, rng *rand.Rand) (image.ImageKind, error)
|
||||
|
||||
type imageType struct {
|
||||
arch *architecture
|
||||
|
|
@ -200,6 +200,11 @@ func (t *imageType) Manifest(bp *blueprint.Blueprint,
|
|||
w = cw
|
||||
}
|
||||
|
||||
containerSources := make([]container.SourceSpec, len(bp.Containers))
|
||||
for idx := range bp.Containers {
|
||||
containerSources[idx] = container.SourceSpec(bp.Containers[idx])
|
||||
}
|
||||
|
||||
source := rand.NewSource(seed)
|
||||
// math/rand is good enough in this case
|
||||
/* #nosec G404 */
|
||||
|
|
@ -208,7 +213,7 @@ func (t *imageType) Manifest(bp *blueprint.Blueprint,
|
|||
if t.image == nil {
|
||||
return nil, nil, nil
|
||||
}
|
||||
img, err := t.image(w, t, bp.Customizations, options, staticPackageSets, containers, rng)
|
||||
img, err := t.image(w, t, bp.Customizations, options, staticPackageSets, containerSources, rng)
|
||||
if err != nil {
|
||||
return nil, nil, err
|
||||
}
|
||||
|
|
@ -292,7 +297,7 @@ func (t *imageType) PackageSets(bp blueprint.Blueprint, options distro.ImageOpti
|
|||
logrus.Errorf("Initializing the manifest failed for %s (%s/%s): %v", t.Name(), t.arch.distro.Name(), t.arch.Name(), err)
|
||||
return nil
|
||||
}
|
||||
img, err := t.image(w, t, bp.Customizations, options, packageSets, containers, rng)
|
||||
img, err := t.image(w, t, bp.Customizations, options, packageSets, nil, rng)
|
||||
if err != nil {
|
||||
logrus.Errorf("Initializing the manifest failed for %s (%s/%s): %v", t.Name(), t.arch.distro.Name(), t.arch.Name(), err)
|
||||
return nil
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ func osCustomizations(
|
|||
t *imageType,
|
||||
osPackageSet rpmmd.PackageSet,
|
||||
options distro.ImageOptions,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
c *blueprint.Customizations,
|
||||
) manifest.OSCustomizations {
|
||||
|
||||
|
|
@ -226,7 +226,7 @@ func liveImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
img := image.NewLiveImage()
|
||||
|
|
@ -252,7 +252,7 @@ func imageInstallerImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
img := image.NewImageInstaller()
|
||||
|
|
@ -290,7 +290,7 @@ func tarImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
img := image.NewArchive()
|
||||
|
|
@ -310,7 +310,7 @@ func edgeCommitImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
img := image.NewOSTreeArchive(options.OSTree.ImageRef)
|
||||
|
|
@ -343,7 +343,7 @@ func edgeContainerImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
img := image.NewOSTreeContainer(options.OSTree.ImageRef)
|
||||
|
|
@ -379,7 +379,7 @@ func edgeInstallerImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
d := t.arch.distro
|
||||
|
|
@ -425,7 +425,7 @@ func edgeRawImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
commit := ostree.CommitSpec{
|
||||
|
|
@ -470,7 +470,7 @@ func edgeSimplifiedInstallerImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
commit := ostree.CommitSpec{
|
||||
|
|
|
|||
|
|
@ -41,7 +41,7 @@ const (
|
|||
blueprintPkgsKey = "blueprint"
|
||||
)
|
||||
|
||||
type imageFunc func(workload workload.Workload, t *imageType, customizations *blueprint.Customizations, options distro.ImageOptions, packageSets map[string]rpmmd.PackageSet, containers []container.Spec, rng *rand.Rand) (image.ImageKind, error)
|
||||
type imageFunc func(workload workload.Workload, t *imageType, customizations *blueprint.Customizations, options distro.ImageOptions, packageSets map[string]rpmmd.PackageSet, containers []container.SourceSpec, rng *rand.Rand) (image.ImageKind, error)
|
||||
|
||||
type packageSetFunc func(t *imageType) rpmmd.PackageSet
|
||||
|
||||
|
|
@ -234,6 +234,11 @@ func (t *imageType) Manifest(bp *blueprint.Blueprint,
|
|||
w = cw
|
||||
}
|
||||
|
||||
containerSources := make([]container.SourceSpec, len(bp.Containers))
|
||||
for idx := range bp.Containers {
|
||||
containerSources[idx] = container.SourceSpec(bp.Containers[idx])
|
||||
}
|
||||
|
||||
source := rand.NewSource(seed)
|
||||
// math/rand is good enough in this case
|
||||
/* #nosec G404 */
|
||||
|
|
@ -242,7 +247,7 @@ func (t *imageType) Manifest(bp *blueprint.Blueprint,
|
|||
if t.image == nil {
|
||||
return nil, nil, nil
|
||||
}
|
||||
img, err := t.image(w, t, bp.Customizations, options, staticPackageSets, containers, rng)
|
||||
img, err := t.image(w, t, bp.Customizations, options, staticPackageSets, containerSources, rng)
|
||||
if err != nil {
|
||||
return nil, nil, err
|
||||
}
|
||||
|
|
@ -344,7 +349,7 @@ func (t *imageType) PackageSets(bp blueprint.Blueprint, options distro.ImageOpti
|
|||
/* #nosec G404 */
|
||||
rng := rand.New(source)
|
||||
|
||||
img, err := t.image(w, t, bp.Customizations, options, packageSets, containers, rng)
|
||||
img, err := t.image(w, t, bp.Customizations, options, packageSets, nil, rng)
|
||||
if err != nil {
|
||||
logrus.Errorf("Initializing the manifest failed for %s (%s/%s): %v", t.Name(), t.arch.distro.Name(), t.arch.Name(), err)
|
||||
return nil
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ func osCustomizations(
|
|||
t *imageType,
|
||||
osPackageSet rpmmd.PackageSet,
|
||||
options distro.ImageOptions,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
c *blueprint.Customizations,
|
||||
) manifest.OSCustomizations {
|
||||
|
||||
|
|
@ -223,7 +223,7 @@ func liveImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
img := image.NewLiveImage()
|
||||
|
|
@ -249,7 +249,7 @@ func edgeCommitImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
img := image.NewOSTreeArchive(options.OSTree.ImageRef)
|
||||
|
|
@ -285,7 +285,7 @@ func edgeContainerImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
img := image.NewOSTreeContainer(options.OSTree.ImageRef)
|
||||
|
|
@ -324,7 +324,7 @@ func edgeInstallerImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
d := t.arch.distro
|
||||
|
|
@ -375,7 +375,7 @@ func edgeRawImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
commit := ostree.CommitSpec{
|
||||
|
|
@ -437,7 +437,7 @@ func edgeSimplifiedInstallerImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
commit := ostree.CommitSpec{
|
||||
|
|
@ -526,7 +526,7 @@ func imageInstallerImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
img := image.NewImageInstaller()
|
||||
|
|
@ -569,7 +569,7 @@ func tarImage(workload workload.Workload,
|
|||
customizations *blueprint.Customizations,
|
||||
options distro.ImageOptions,
|
||||
packageSets map[string]rpmmd.PackageSet,
|
||||
containers []container.Spec,
|
||||
containers []container.SourceSpec,
|
||||
rng *rand.Rand) (image.ImageKind, error) {
|
||||
|
||||
img := image.NewArchive()
|
||||
|
|
|
|||
|
|
@ -44,7 +44,7 @@ const (
|
|||
blueprintPkgsKey = "blueprint"
|
||||
)
|
||||
|
||||
type imageFunc func(workload workload.Workload, t *imageType, customizations *blueprint.Customizations, options distro.ImageOptions, packageSets map[string]rpmmd.PackageSet, containers []container.Spec, rng *rand.Rand) (image.ImageKind, error)
|
||||
type imageFunc func(workload workload.Workload, t *imageType, customizations *blueprint.Customizations, options distro.ImageOptions, packageSets map[string]rpmmd.PackageSet, containers []container.SourceSpec, rng *rand.Rand) (image.ImageKind, error)
|
||||
|
||||
type packageSetFunc func(t *imageType) rpmmd.PackageSet
|
||||
|
||||
|
|
@ -237,12 +237,17 @@ func (t *imageType) Manifest(bp *blueprint.Blueprint,
|
|||
w = cw
|
||||
}
|
||||
|
||||
containerSources := make([]container.SourceSpec, len(bp.Containers))
|
||||
for idx := range bp.Containers {
|
||||
containerSources[idx] = container.SourceSpec(bp.Containers[idx])
|
||||
}
|
||||
|
||||
source := rand.NewSource(seed)
|
||||
// math/rand is good enough in this case
|
||||
/* #nosec G404 */
|
||||
rng := rand.New(source)
|
||||
|
||||
img, err := t.image(w, t, bp.Customizations, options, staticPackageSets, containers, rng)
|
||||
img, err := t.image(w, t, bp.Customizations, options, staticPackageSets, containerSources, rng)
|
||||
if err != nil {
|
||||
return nil, nil, err
|
||||
}
|
||||
|
|
@ -344,7 +349,7 @@ func (t *imageType) PackageSets(bp blueprint.Blueprint, options distro.ImageOpti
|
|||
/* #nosec G404 */
|
||||
rng := rand.New(source)
|
||||
|
||||
img, err := t.image(w, t, bp.Customizations, options, packageSets, containers, rng)
|
||||
img, err := t.image(w, t, bp.Customizations, options, packageSets, nil, rng)
|
||||
if err != nil {
|
||||
logrus.Errorf("Initializing the manifest failed for %s (%s/%s): %v", t.Name(), t.arch.distro.Name(), t.arch.Name(), err)
|
||||
return nil
|
||||
|
|
|
|||
|
|
@ -43,8 +43,9 @@ type OSCustomizations struct {
|
|||
// Additional repos to install the base packages from.
|
||||
ExtraBaseRepos []rpmmd.RepoConfig
|
||||
|
||||
// Containers to embed in the image
|
||||
Containers []container.Spec
|
||||
// Containers to embed in the image (source specification)
|
||||
// TODO: move to workload
|
||||
Containers []container.SourceSpec
|
||||
|
||||
// KernelName indicates that a kernel is installed, and names the kernel
|
||||
// package.
|
||||
|
|
@ -146,10 +147,11 @@ type OS struct {
|
|||
// Partition table, if nil the tree cannot be put on a partitioned disk
|
||||
PartitionTable *disk.PartitionTable
|
||||
|
||||
repos []rpmmd.RepoConfig
|
||||
packageSpecs []rpmmd.PackageSpec
|
||||
platform platform.Platform
|
||||
kernelVer string
|
||||
repos []rpmmd.RepoConfig
|
||||
packageSpecs []rpmmd.PackageSpec
|
||||
containerSpecs []container.Spec
|
||||
platform platform.Platform
|
||||
kernelVer string
|
||||
|
||||
// NoBLS configures the image bootloader with traditional menu entries
|
||||
// instead of BLS. Required for legacy systems like RHEL 7.
|
||||
|
|
@ -286,7 +288,7 @@ func (p *OS) getPackageSpecs() []rpmmd.PackageSpec {
|
|||
}
|
||||
|
||||
func (p *OS) getContainerSpecs() []container.Spec {
|
||||
return p.Containers
|
||||
return p.containerSpecs
|
||||
}
|
||||
|
||||
func (p *OS) serializeStart(packages []rpmmd.PackageSpec) {
|
||||
|
|
@ -347,8 +349,8 @@ func (p *OS) serialize() osbuild.Pipeline {
|
|||
}
|
||||
}
|
||||
|
||||
if len(p.Containers) > 0 {
|
||||
images := osbuild.NewContainersInputForSources(p.Containers)
|
||||
if len(p.containerSpecs) > 0 {
|
||||
images := osbuild.NewContainersInputForSources(p.containerSpecs)
|
||||
|
||||
var storagePath string
|
||||
|
||||
|
|
@ -364,7 +366,7 @@ func (p *OS) serialize() osbuild.Pipeline {
|
|||
pipeline.AddStage(osbuild.NewContainersStorageConfStage(containerStoreOpts))
|
||||
}
|
||||
|
||||
manifests := osbuild.NewFilesInputForManifestLists(p.Containers)
|
||||
manifests := osbuild.NewFilesInputForManifestLists(p.containerSpecs)
|
||||
skopeo := osbuild.NewSkopeoStage(storagePath, images, manifests)
|
||||
pipeline.AddStage(skopeo)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue