go.mod: bump images to v0.178.0
Changes with 0.178.0 ---------------- - Update osbuild dependency commit ID to latest (osbuild/images#1763) - Author: SchutzBot, Reviewers: Achilleas Koutsou, Simon de Vlieger - many: drop `ISORootKickstart` (osbuild/images#1769) - Author: Simon de Vlieger, Reviewers: Brian C. Lane, Tomáš Hozza - many: drop the workload.Workload type entirely (osbuild/images#1770) - Author: Michael Vogt, Reviewers: Simon de Vlieger, Tomáš Hozza - platform: drop hardcoded platforms and rename PlatformConf (osbuild/images#1739) - Author: Michael Vogt, Reviewers: Brian C. Lane, Simon de Vlieger - rhel: fix openscap profile allowlists (HMS-9095) (osbuild/images#1778) - Author: Sanne Raymaekers, Reviewers: Michael Vogt, Simon de Vlieger — Somewhere on the Internet, 2025-08-21
This commit is contained in:
parent
9ba7f1a8b0
commit
d578c87ee0
31 changed files with 187 additions and 569 deletions
2
go.mod
2
go.mod
|
|
@ -34,7 +34,7 @@ require (
|
|||
github.com/oapi-codegen/runtime v1.1.2
|
||||
github.com/openshift-online/ocm-sdk-go v0.1.473
|
||||
github.com/osbuild/blueprint v1.13.0
|
||||
github.com/osbuild/images v0.177.0
|
||||
github.com/osbuild/images v0.178.0
|
||||
github.com/osbuild/osbuild-composer/pkg/splunk_logger v0.0.0-20240814102216-0239db53236d
|
||||
github.com/prometheus/client_golang v1.23.0
|
||||
github.com/segmentio/ksuid v1.0.4
|
||||
|
|
|
|||
4
go.sum
4
go.sum
|
|
@ -517,8 +517,8 @@ github.com/oracle/oci-go-sdk/v54 v54.0.0 h1:CDLjeSejv2aDpElAJrhKpi6zvT/zhZCZuXch
|
|||
github.com/oracle/oci-go-sdk/v54 v54.0.0/go.mod h1:+t+yvcFGVp+3ZnztnyxqXfQDsMlq8U25faBLa+mqCMc=
|
||||
github.com/osbuild/blueprint v1.13.0 h1:blo22+S2ZX5bBmjGcRveoTUrV4Ms7kLfKyb32WyuymA=
|
||||
github.com/osbuild/blueprint v1.13.0/go.mod h1:HPlJzkEl7q5g8hzaGksUk7ifFAy9QFw9LmzhuFOAVm4=
|
||||
github.com/osbuild/images v0.177.0 h1:oubjOaYmrI0STPnJmtxuDPNRQmV2nR9JI0g42u+yShw=
|
||||
github.com/osbuild/images v0.177.0/go.mod h1:7CfDwGb8YA4erIzvMnqJysVpSu52i6l/f3h82usGPTg=
|
||||
github.com/osbuild/images v0.178.0 h1:ojCD1rRtO+khFHpRHUxd6ydXBarEu+6pwt0w8oqilaY=
|
||||
github.com/osbuild/images v0.178.0/go.mod h1:7CfDwGb8YA4erIzvMnqJysVpSu52i6l/f3h82usGPTg=
|
||||
github.com/osbuild/osbuild-composer/pkg/splunk_logger v0.0.0-20240814102216-0239db53236d h1:r9BFPDv0uuA9k1947Jybcxs36c/pTywWS1gjeizvtcQ=
|
||||
github.com/osbuild/osbuild-composer/pkg/splunk_logger v0.0.0-20240814102216-0239db53236d/go.mod h1:zR1iu/hOuf+OQNJlk70tju9IqzzM4ycq0ectkFBm94U=
|
||||
github.com/perimeterx/marshmallow v1.1.5 h1:a2LALqQ1BlHM8PZblsDdidgv1mWi1DgC2UmX50IvK2s=
|
||||
|
|
|
|||
48
vendor/github.com/osbuild/images/data/distrodefs/distros.yaml
generated
vendored
48
vendor/github.com/osbuild/images/data/distrodefs/distros.yaml
generated
vendored
|
|
@ -103,7 +103,7 @@ distros:
|
|||
- azure
|
||||
# rhel & centos share the same list of allowed profiles so a
|
||||
# single allow list can be used
|
||||
oscap_profiles_allowlist: &oscap_profile_allowlist_rhel
|
||||
oscap_profiles_allowlist: &oscap_profile_allowlist_rhel_10
|
||||
- "xccdf_org.ssgproject.content_profile_anssi_bp28_enhanced"
|
||||
- "xccdf_org.ssgproject.content_profile_anssi_bp28_high"
|
||||
- "xccdf_org.ssgproject.content_profile_anssi_bp28_intermediary"
|
||||
|
|
@ -112,7 +112,6 @@ distros:
|
|||
- "xccdf_org.ssgproject.content_profile_cis_server_l1"
|
||||
- "xccdf_org.ssgproject.content_profile_cis_workstation_l1"
|
||||
- "xccdf_org.ssgproject.content_profile_cis_workstation_l2"
|
||||
- "xccdf_org.ssgproject.content_profile_cui"
|
||||
- "xccdf_org.ssgproject.content_profile_e8"
|
||||
- "xccdf_org.ssgproject.content_profile_hipaa"
|
||||
- "xccdf_org.ssgproject.content_profile_ism_o"
|
||||
|
|
@ -150,7 +149,7 @@ distros:
|
|||
runner:
|
||||
name: org.osbuild.centos10
|
||||
build_packages: *rhel10_runner_build_packages
|
||||
oscap_profiles_allowlist: *oscap_profile_allowlist_rhel
|
||||
oscap_profiles_allowlist: *oscap_profile_allowlist_rhel_10
|
||||
bootstrap_containers:
|
||||
# we need the toolbox container because stock centos has e.g. no
|
||||
# mount util
|
||||
|
|
@ -210,7 +209,27 @@ distros:
|
|||
- "platform-python" # osbuild
|
||||
- "python3"
|
||||
# rhel9 allow all
|
||||
oscap_profiles_allowlist: *oscap_profile_allowlist_rhel
|
||||
oscap_profiles_allowlist: &oscap_profile_allowlist_rhel_9
|
||||
- "xccdf_org.ssgproject.content_profile_anssi_bp28_enhanced"
|
||||
- "xccdf_org.ssgproject.content_profile_anssi_bp28_high"
|
||||
- "xccdf_org.ssgproject.content_profile_anssi_bp28_intermediary"
|
||||
- "xccdf_org.ssgproject.content_profile_anssi_bp28_minimal"
|
||||
- "xccdf_org.ssgproject.content_profile_ccn_advanced"
|
||||
- "xccdf_org.ssgproject.content_profile_ccn_basic"
|
||||
- "xccdf_org.ssgproject.content_profile_ccn_intermediate"
|
||||
- "xccdf_org.ssgproject.content_profile_cis"
|
||||
- "xccdf_org.ssgproject.content_profile_cis_server_l1"
|
||||
- "xccdf_org.ssgproject.content_profile_cis_workstation_l1"
|
||||
- "xccdf_org.ssgproject.content_profile_cis_workstation_l2"
|
||||
- "xccdf_org.ssgproject.content_profile_cui"
|
||||
- "xccdf_org.ssgproject.content_profile_e8"
|
||||
- "xccdf_org.ssgproject.content_profile_hipaa"
|
||||
- "xccdf_org.ssgproject.content_profile_ism_o"
|
||||
- "xccdf_org.ssgproject.content_profile_ospp"
|
||||
- "xccdf_org.ssgproject.content_profile_pci-dss"
|
||||
- "xccdf_org.ssgproject.content_profile_stig"
|
||||
- "xccdf_org.ssgproject.content_profile_stig_gui"
|
||||
|
||||
bootstrap_containers:
|
||||
x86_64: "registry.access.redhat.com/ubi{{.MajorVersion}}/ubi:latest"
|
||||
aarch64: "registry.access.redhat.com/ubi{{.MajorVersion}}/ubi:latest"
|
||||
|
|
@ -231,6 +250,7 @@ distros:
|
|||
runner:
|
||||
name: org.osbuild.centos9
|
||||
build_packages: *rhel9_runner_build_packages
|
||||
oscap_profiles_allowlist: *oscap_profile_allowlist_rhel_9
|
||||
bootstrap_containers:
|
||||
# we need the toolbox container because stock centos has e.g. no
|
||||
# mount util
|
||||
|
|
@ -282,7 +302,23 @@ distros:
|
|||
# https://github.com/osbuild/osbuild/blob/ea8261cad6c5c606c00c0f2824c3f483c01a0cc9/runners/org.osbuild.rhel82#L61
|
||||
# Install python36 explicitly for RHEL 8.
|
||||
- "python36"
|
||||
oscap_profiles_allowlist: *oscap_profile_allowlist_rhel
|
||||
oscap_profiles_allowlist: &oscap_profile_allowlist_rhel_8
|
||||
- "xccdf_org.ssgproject.content_profile_anssi_bp28_enhanced"
|
||||
- "xccdf_org.ssgproject.content_profile_anssi_bp28_high"
|
||||
- "xccdf_org.ssgproject.content_profile_anssi_bp28_intermediary"
|
||||
- "xccdf_org.ssgproject.content_profile_anssi_bp28_minimal"
|
||||
- "xccdf_org.ssgproject.content_profile_cis"
|
||||
- "xccdf_org.ssgproject.content_profile_cis_server_l1"
|
||||
- "xccdf_org.ssgproject.content_profile_cis_workstation_l1"
|
||||
- "xccdf_org.ssgproject.content_profile_cis_workstation_l2"
|
||||
- "xccdf_org.ssgproject.content_profile_cui"
|
||||
- "xccdf_org.ssgproject.content_profile_e8"
|
||||
- "xccdf_org.ssgproject.content_profile_hipaa"
|
||||
- "xccdf_org.ssgproject.content_profile_ism_o"
|
||||
- "xccdf_org.ssgproject.content_profile_ospp"
|
||||
- "xccdf_org.ssgproject.content_profile_pci-dss"
|
||||
- "xccdf_org.ssgproject.content_profile_stig"
|
||||
- "xccdf_org.ssgproject.content_profile_stig_gui"
|
||||
bootstrap_containers:
|
||||
x86_64: "registry.access.redhat.com/ubi{{.MajorVersion}}/ubi:latest"
|
||||
aarch64: "registry.access.redhat.com/ubi{{.MajorVersion}}/ubi:latest"
|
||||
|
|
@ -301,7 +337,7 @@ distros:
|
|||
runner:
|
||||
name: org.osbuild.centos8
|
||||
build_packages: *rhel8_runner_build_packages
|
||||
oscap_profiles_allowlist: *oscap_profile_allowlist_rhel
|
||||
oscap_profiles_allowlist: *oscap_profile_allowlist_rhel_8
|
||||
bootstrap_containers:
|
||||
# we need the toolbox container because stock centos has e.g. no
|
||||
# mount util
|
||||
|
|
|
|||
2
vendor/github.com/osbuild/images/data/distrodefs/rhel-10/imagetypes.yaml
generated
vendored
2
vendor/github.com/osbuild/images/data/distrodefs/rhel-10/imagetypes.yaml
generated
vendored
|
|
@ -135,8 +135,6 @@
|
|||
additional_drivers:
|
||||
- "ipmi_devintf"
|
||||
- "ipmi_msghandler"
|
||||
# see commit c6bfb22f54, controls the kickstart location
|
||||
iso_root_kickstart: true
|
||||
default_menu: 1
|
||||
iso_rootfs_type: "squashfs"
|
||||
conditions:
|
||||
|
|
|
|||
1
vendor/github.com/osbuild/images/data/distrodefs/rhel-8/imagetypes.yaml
generated
vendored
1
vendor/github.com/osbuild/images/data/distrodefs/rhel-8/imagetypes.yaml
generated
vendored
|
|
@ -868,7 +868,6 @@
|
|||
- "org.fedoraproject.Anaconda.Modules.Network"
|
||||
- "org.fedoraproject.Anaconda.Modules.Payloads"
|
||||
- "org.fedoraproject.Anaconda.Modules.Storage"
|
||||
iso_root_kickstart: true
|
||||
additional_dracut_modules:
|
||||
- "ifcfg"
|
||||
default_menu: 1
|
||||
|
|
|
|||
2
vendor/github.com/osbuild/images/data/distrodefs/rhel-9/imagetypes.yaml
generated
vendored
2
vendor/github.com/osbuild/images/data/distrodefs/rhel-9/imagetypes.yaml
generated
vendored
|
|
@ -1157,8 +1157,6 @@
|
|||
- "org.fedoraproject.Anaconda.Modules.Payloads"
|
||||
- "org.fedoraproject.Anaconda.Modules.Runtime"
|
||||
- "org.fedoraproject.Anaconda.Modules.Storage"
|
||||
# see commit c6bfb22f54, controls the kickstart location
|
||||
iso_root_kickstart: true
|
||||
additional_dracut_modules:
|
||||
- "nvdimm" # non-volatile DIMM firmware (provides nfit, cuse, and nd_e820)
|
||||
- "ifcfg"
|
||||
|
|
|
|||
32
vendor/github.com/osbuild/images/internal/workload/custom.go
generated
vendored
32
vendor/github.com/osbuild/images/internal/workload/custom.go
generated
vendored
|
|
@ -1,32 +0,0 @@
|
|||
package workload
|
||||
|
||||
type Custom struct {
|
||||
BaseWorkload
|
||||
Packages []string
|
||||
EnabledModules []string
|
||||
Services []string
|
||||
DisabledServices []string
|
||||
MaskedServices []string
|
||||
}
|
||||
|
||||
func (p *Custom) GetPackages() []string {
|
||||
return p.Packages
|
||||
}
|
||||
|
||||
func (p *Custom) GetEnabledModules() []string {
|
||||
return p.EnabledModules
|
||||
}
|
||||
|
||||
func (p *Custom) GetServices() []string {
|
||||
return p.Services
|
||||
}
|
||||
|
||||
// TODO: Do these belong here? What kind of workload requires
|
||||
// services to be disabled or masked?
|
||||
func (p *Custom) GetDisabledServices() []string {
|
||||
return p.DisabledServices
|
||||
}
|
||||
|
||||
func (p *Custom) GetMaskedServices() []string {
|
||||
return p.MaskedServices
|
||||
}
|
||||
40
vendor/github.com/osbuild/images/internal/workload/workload.go
generated
vendored
40
vendor/github.com/osbuild/images/internal/workload/workload.go
generated
vendored
|
|
@ -1,40 +0,0 @@
|
|||
package workload
|
||||
|
||||
import "github.com/osbuild/images/pkg/rpmmd"
|
||||
|
||||
type Workload interface {
|
||||
GetPackages() []string
|
||||
GetEnabledModules() []string
|
||||
GetRepos() []rpmmd.RepoConfig
|
||||
GetServices() []string
|
||||
GetDisabledServices() []string
|
||||
GetMaskedServices() []string
|
||||
}
|
||||
|
||||
type BaseWorkload struct {
|
||||
Repos []rpmmd.RepoConfig
|
||||
}
|
||||
|
||||
func (p BaseWorkload) GetPackages() []string {
|
||||
return []string{}
|
||||
}
|
||||
|
||||
func (p BaseWorkload) GetEnabledModules() []string {
|
||||
return []string{}
|
||||
}
|
||||
|
||||
func (p BaseWorkload) GetRepos() []rpmmd.RepoConfig {
|
||||
return p.Repos
|
||||
}
|
||||
|
||||
func (p BaseWorkload) GetServices() []string {
|
||||
return []string{}
|
||||
}
|
||||
|
||||
func (p BaseWorkload) GetDisabledServices() []string {
|
||||
return []string{}
|
||||
}
|
||||
|
||||
func (p BaseWorkload) GetMaskedServices() []string {
|
||||
return []string{}
|
||||
}
|
||||
6
vendor/github.com/osbuild/images/pkg/distro/defs/loader.go
generated
vendored
6
vendor/github.com/osbuild/images/pkg/distro/defs/loader.go
generated
vendored
|
|
@ -374,7 +374,7 @@ type ImageTypeYAML struct {
|
|||
Exports []string `yaml:"exports"`
|
||||
RequiredPartitionSizes map[string]uint64 `yaml:"required_partition_sizes"`
|
||||
|
||||
InternalPlatforms []platform.PlatformConf `yaml:"platforms"`
|
||||
InternalPlatforms []platform.Data `yaml:"platforms"`
|
||||
PlatformsOverride *platformsOverride `yaml:"platforms_override"`
|
||||
|
||||
NameAliases []string `yaml:"name_aliases"`
|
||||
|
|
@ -396,7 +396,7 @@ func (it *ImageTypeYAML) Name() string {
|
|||
return it.name
|
||||
}
|
||||
|
||||
func (it *ImageTypeYAML) PlatformsFor(id distro.ID) ([]platform.PlatformConf, error) {
|
||||
func (it *ImageTypeYAML) PlatformsFor(id distro.ID) ([]platform.Data, error) {
|
||||
pl := it.InternalPlatforms
|
||||
if it.PlatformsOverride != nil {
|
||||
var nMatches int
|
||||
|
|
@ -466,7 +466,7 @@ type platformsOverride struct {
|
|||
|
||||
type conditionsPlatforms struct {
|
||||
When whenCondition `yaml:"when,omitempty"`
|
||||
Override []platform.PlatformConf `yaml:"override"`
|
||||
Override []platform.Data `yaml:"override"`
|
||||
}
|
||||
|
||||
type imageConfig struct {
|
||||
|
|
|
|||
58
vendor/github.com/osbuild/images/pkg/distro/generic/images.go
generated
vendored
58
vendor/github.com/osbuild/images/pkg/distro/generic/images.go
generated
vendored
|
|
@ -6,7 +6,6 @@ import (
|
|||
"strings"
|
||||
|
||||
"github.com/osbuild/blueprint/pkg/blueprint"
|
||||
"github.com/osbuild/images/internal/workload"
|
||||
"github.com/osbuild/images/pkg/container"
|
||||
"github.com/osbuild/images/pkg/customizations/anaconda"
|
||||
"github.com/osbuild/images/pkg/customizations/bootc"
|
||||
|
|
@ -344,15 +343,6 @@ func installerCustomizations(t *imageType, c *blueprint.Customizations) (manifes
|
|||
if isoboot := installerConfig.ISOBootType; isoboot != nil {
|
||||
isc.ISOBoot = *isoboot
|
||||
}
|
||||
|
||||
// Put the kickstart file in the root of the iso, some image
|
||||
// types (like rhel10/image-installer) put them there, some
|
||||
// others (like fedora/image-installer) do not and because
|
||||
// its not uniform we need to make it configurable.
|
||||
// XXX: unify with rhel-11 ? or rhel-10.x?
|
||||
if rootkickstart := installerConfig.ISORootKickstart; rootkickstart != nil {
|
||||
isc.ISORootKickstart = *rootkickstart
|
||||
}
|
||||
}
|
||||
|
||||
installerCust, err := c.GetInstaller()
|
||||
|
|
@ -439,7 +429,7 @@ func ostreeDeploymentCustomizations(
|
|||
|
||||
// IMAGES
|
||||
|
||||
func diskImage(workload workload.Workload,
|
||||
func diskImage(imgTypeCustomizations manifest.OSCustomizations,
|
||||
t *imageType,
|
||||
bp *blueprint.Blueprint,
|
||||
options distro.ImageOptions,
|
||||
|
|
@ -457,7 +447,7 @@ func diskImage(workload workload.Workload,
|
|||
}
|
||||
|
||||
img.Environment = &t.ImageTypeYAML.Environment
|
||||
img.Workload = workload
|
||||
img.ImgTypeCustomizations = imgTypeCustomizations
|
||||
img.Compression = t.ImageTypeYAML.Compression
|
||||
if bp.Minimal {
|
||||
// Disable weak dependencies if the 'minimal' option is enabled
|
||||
|
|
@ -487,7 +477,7 @@ func diskImage(workload workload.Workload,
|
|||
return img, nil
|
||||
}
|
||||
|
||||
func tarImage(workload workload.Workload,
|
||||
func tarImage(imgTypeCustomizations manifest.OSCustomizations,
|
||||
t *imageType,
|
||||
bp *blueprint.Blueprint,
|
||||
options distro.ImageOptions,
|
||||
|
|
@ -507,7 +497,7 @@ func tarImage(workload workload.Workload,
|
|||
d := t.arch.distro
|
||||
|
||||
img.Environment = &t.ImageTypeYAML.Environment
|
||||
img.Workload = workload
|
||||
img.ImgTypeCustomizations = imgTypeCustomizations
|
||||
img.Compression = t.ImageTypeYAML.Compression
|
||||
img.OSVersion = d.OsVersion()
|
||||
|
||||
|
|
@ -516,7 +506,7 @@ func tarImage(workload workload.Workload,
|
|||
return img, nil
|
||||
}
|
||||
|
||||
func containerImage(workload workload.Workload,
|
||||
func containerImage(imgTypeCustomizations manifest.OSCustomizations,
|
||||
t *imageType,
|
||||
bp *blueprint.Blueprint,
|
||||
options distro.ImageOptions,
|
||||
|
|
@ -534,14 +524,14 @@ func containerImage(workload workload.Workload,
|
|||
}
|
||||
|
||||
img.Environment = &t.ImageTypeYAML.Environment
|
||||
img.Workload = workload
|
||||
img.ImgTypeCustomizations = imgTypeCustomizations
|
||||
|
||||
img.Filename = t.Filename()
|
||||
|
||||
return img, nil
|
||||
}
|
||||
|
||||
func liveInstallerImage(workload workload.Workload,
|
||||
func liveInstallerImage(imgTypeCustomizations manifest.OSCustomizations,
|
||||
t *imageType,
|
||||
bp *blueprint.Blueprint,
|
||||
options distro.ImageOptions,
|
||||
|
|
@ -552,7 +542,7 @@ func liveInstallerImage(workload workload.Workload,
|
|||
img := image.NewAnacondaLiveInstaller()
|
||||
|
||||
img.Platform = t.platform
|
||||
img.Workload = workload
|
||||
img.ImgTypeCustomizations = imgTypeCustomizations
|
||||
img.ExtraBasePackages = packageSets[installerPkgsKey]
|
||||
|
||||
d := t.arch.distro
|
||||
|
|
@ -585,7 +575,7 @@ func liveInstallerImage(workload workload.Workload,
|
|||
return img, nil
|
||||
}
|
||||
|
||||
func imageInstallerImage(workload workload.Workload,
|
||||
func imageInstallerImage(imgTypeCustomizations manifest.OSCustomizations,
|
||||
t *imageType,
|
||||
bp *blueprint.Blueprint,
|
||||
options distro.ImageOptions,
|
||||
|
|
@ -612,7 +602,7 @@ func imageInstallerImage(workload workload.Workload,
|
|||
img.Kickstart.Timezone = &img.OSCustomizations.Timezone
|
||||
|
||||
img.Platform = t.platform
|
||||
img.Workload = workload
|
||||
img.ImgTypeCustomizations = imgTypeCustomizations
|
||||
|
||||
img.ExtraBasePackages = packageSets[installerPkgsKey]
|
||||
|
||||
|
|
@ -655,7 +645,7 @@ func imageInstallerImage(workload workload.Workload,
|
|||
return img, nil
|
||||
}
|
||||
|
||||
func iotCommitImage(workload workload.Workload,
|
||||
func iotCommitImage(imgTypeCustomizations manifest.OSCustomizations,
|
||||
t *imageType,
|
||||
bp *blueprint.Blueprint,
|
||||
options distro.ImageOptions,
|
||||
|
|
@ -683,7 +673,7 @@ func iotCommitImage(workload workload.Workload,
|
|||
}
|
||||
|
||||
img.Environment = &t.ImageTypeYAML.Environment
|
||||
img.Workload = workload
|
||||
img.ImgTypeCustomizations = imgTypeCustomizations
|
||||
img.OSTreeParent = parentCommit
|
||||
img.OSVersion = d.OsVersion()
|
||||
img.Filename = t.Filename()
|
||||
|
|
@ -691,7 +681,7 @@ func iotCommitImage(workload workload.Workload,
|
|||
return img, nil
|
||||
}
|
||||
|
||||
func bootableContainerImage(workload workload.Workload,
|
||||
func bootableContainerImage(imgTypeCustomizations manifest.OSCustomizations,
|
||||
t *imageType,
|
||||
bp *blueprint.Blueprint,
|
||||
options distro.ImageOptions,
|
||||
|
|
@ -713,7 +703,7 @@ func bootableContainerImage(workload workload.Workload,
|
|||
}
|
||||
|
||||
img.Environment = &t.ImageTypeYAML.Environment
|
||||
img.Workload = workload
|
||||
img.ImgTypeCustomizations = imgTypeCustomizations
|
||||
img.OSTreeParent = parentCommit
|
||||
img.OSVersion = d.OsVersion()
|
||||
img.Filename = t.Filename()
|
||||
|
|
@ -731,7 +721,7 @@ func bootableContainerImage(workload workload.Workload,
|
|||
return img, nil
|
||||
}
|
||||
|
||||
func iotContainerImage(workload workload.Workload,
|
||||
func iotContainerImage(imgTypeCustomizations manifest.OSCustomizations,
|
||||
t *imageType,
|
||||
bp *blueprint.Blueprint,
|
||||
options distro.ImageOptions,
|
||||
|
|
@ -758,7 +748,7 @@ func iotContainerImage(workload workload.Workload,
|
|||
|
||||
img.ContainerLanguage = img.OSCustomizations.Language
|
||||
img.Environment = &t.ImageTypeYAML.Environment
|
||||
img.Workload = workload
|
||||
img.ImgTypeCustomizations = imgTypeCustomizations
|
||||
img.OSTreeParent = parentCommit
|
||||
img.OSVersion = d.OsVersion()
|
||||
img.ExtraContainerPackages = packageSets[containerPkgsKey]
|
||||
|
|
@ -767,7 +757,7 @@ func iotContainerImage(workload workload.Workload,
|
|||
return img, nil
|
||||
}
|
||||
|
||||
func iotInstallerImage(workload workload.Workload,
|
||||
func iotInstallerImage(imgTypeCustomizations manifest.OSCustomizations,
|
||||
t *imageType,
|
||||
bp *blueprint.Blueprint,
|
||||
options distro.ImageOptions,
|
||||
|
|
@ -837,7 +827,7 @@ func iotInstallerImage(workload workload.Workload,
|
|||
return img, nil
|
||||
}
|
||||
|
||||
func iotImage(workload workload.Workload,
|
||||
func iotImage(imgTypeCustomizations manifest.OSCustomizations,
|
||||
t *imageType,
|
||||
bp *blueprint.Blueprint,
|
||||
options distro.ImageOptions,
|
||||
|
|
@ -859,7 +849,7 @@ func iotImage(workload workload.Workload,
|
|||
img.OSTreeDeploymentCustomizations = deploymentConfig
|
||||
|
||||
img.Platform = t.platform
|
||||
img.Workload = workload
|
||||
img.ImgTypeCustomizations = imgTypeCustomizations
|
||||
|
||||
img.Remote = ostree.Remote{
|
||||
Name: t.ImageTypeYAML.OSTree.RemoteName,
|
||||
|
|
@ -885,7 +875,7 @@ func iotImage(workload workload.Workload,
|
|||
return img, nil
|
||||
}
|
||||
|
||||
func iotSimplifiedInstallerImage(workload workload.Workload,
|
||||
func iotSimplifiedInstallerImage(imgTypeCustomizations manifest.OSCustomizations,
|
||||
t *imageType,
|
||||
bp *blueprint.Blueprint,
|
||||
options distro.ImageOptions,
|
||||
|
|
@ -907,7 +897,7 @@ func iotSimplifiedInstallerImage(workload workload.Workload,
|
|||
rawImg.OSTreeDeploymentCustomizations = deploymentConfig
|
||||
|
||||
rawImg.Platform = t.platform
|
||||
rawImg.Workload = workload
|
||||
rawImg.ImgTypeCustomizations = imgTypeCustomizations
|
||||
rawImg.Remote = ostree.Remote{
|
||||
Name: t.OSTree.RemoteName,
|
||||
}
|
||||
|
|
@ -928,7 +918,7 @@ func iotSimplifiedInstallerImage(workload workload.Workload,
|
|||
|
||||
img := image.NewOSTreeSimplifiedInstaller(rawImg, customizations.InstallationDevice)
|
||||
img.ExtraBasePackages = packageSets[installerPkgsKey]
|
||||
// img.Workload = workload
|
||||
// img.ImgTypeCustomizations = imgTypeCustomizations
|
||||
img.Platform = t.platform
|
||||
img.Filename = t.Filename()
|
||||
if bpFDO := customizations.GetFDO(); bpFDO != nil {
|
||||
|
|
@ -970,7 +960,7 @@ func iotSimplifiedInstallerImage(workload workload.Workload,
|
|||
}
|
||||
|
||||
// Make an Anaconda installer boot.iso
|
||||
func netinstImage(workload workload.Workload,
|
||||
func netinstImage(imgTypeCustomizations manifest.OSCustomizations,
|
||||
t *imageType,
|
||||
bp *blueprint.Blueprint,
|
||||
options distro.ImageOptions,
|
||||
|
|
@ -987,7 +977,7 @@ func netinstImage(workload workload.Workload,
|
|||
}
|
||||
|
||||
img.Platform = t.platform
|
||||
img.Workload = workload
|
||||
img.ImgTypeCustomizations = imgTypeCustomizations
|
||||
img.ExtraBasePackages = packageSets[installerPkgsKey]
|
||||
|
||||
var err error
|
||||
|
|
|
|||
15
vendor/github.com/osbuild/images/pkg/distro/generic/imagetype.go
generated
vendored
15
vendor/github.com/osbuild/images/pkg/distro/generic/imagetype.go
generated
vendored
|
|
@ -8,7 +8,6 @@ import (
|
|||
|
||||
"github.com/osbuild/blueprint/pkg/blueprint"
|
||||
"github.com/osbuild/images/internal/common"
|
||||
"github.com/osbuild/images/internal/workload"
|
||||
"github.com/osbuild/images/pkg/container"
|
||||
"github.com/osbuild/images/pkg/datasizes"
|
||||
"github.com/osbuild/images/pkg/disk"
|
||||
|
|
@ -21,7 +20,7 @@ import (
|
|||
"github.com/osbuild/images/pkg/rpmmd"
|
||||
)
|
||||
|
||||
type imageFunc func(workload workload.Workload, t *imageType, bp *blueprint.Blueprint, options distro.ImageOptions, packageSets map[string]rpmmd.PackageSet, containers []container.SourceSpec, rng *rand.Rand) (image.ImageKind, error)
|
||||
type imageFunc func(imgTypeCustomizations manifest.OSCustomizations, t *imageType, bp *blueprint.Blueprint, options distro.ImageOptions, packageSets map[string]rpmmd.PackageSet, containers []container.SourceSpec, rng *rand.Rand) (image.ImageKind, error)
|
||||
|
||||
type isoLabelFunc func(t *imageType) string
|
||||
|
||||
|
|
@ -258,15 +257,13 @@ func (t *imageType) Manifest(bp *blueprint.Blueprint,
|
|||
installFromRepos := blueprint.RepoCustomizationsInstallFromOnly(customRepos)
|
||||
payloadRepos = append(payloadRepos, installFromRepos...)
|
||||
|
||||
cw := &workload.Custom{
|
||||
BaseWorkload: workload.BaseWorkload{
|
||||
Repos: payloadRepos,
|
||||
},
|
||||
Packages: bp.GetPackagesEx(false),
|
||||
EnabledModules: bp.GetEnabledModules(),
|
||||
cw := manifest.OSCustomizations{
|
||||
ExtraBaseRepos: payloadRepos,
|
||||
BasePackages: bp.GetPackagesEx(false),
|
||||
BaseModules: bp.GetEnabledModules(),
|
||||
}
|
||||
if services := bp.Customizations.GetServices(); services != nil {
|
||||
cw.Services = services.Enabled
|
||||
cw.EnabledServices = services.Enabled
|
||||
cw.DisabledServices = services.Disabled
|
||||
cw.MaskedServices = services.Masked
|
||||
}
|
||||
|
|
|
|||
1
vendor/github.com/osbuild/images/pkg/distro/installer_config.go
generated
vendored
1
vendor/github.com/osbuild/images/pkg/distro/installer_config.go
generated
vendored
|
|
@ -16,7 +16,6 @@ type InstallerConfig struct {
|
|||
// XXX: this is really here only for compatibility/because of drift in the "imageInstallerImage"
|
||||
// between fedora/rhel
|
||||
KickstartUnattendedExtraKernelOpts []string `yaml:"kickstart_unattended_extra_kernel_opts"`
|
||||
ISORootKickstart *bool `yaml:"iso_root_kickstart"`
|
||||
|
||||
// DefaultMenu will set the grub2 iso menu's default setting
|
||||
DefaultMenu *int `yaml:"default_menu"`
|
||||
|
|
|
|||
3
vendor/github.com/osbuild/images/pkg/image/anaconda_live_installer.go
generated
vendored
3
vendor/github.com/osbuild/images/pkg/image/anaconda_live_installer.go
generated
vendored
|
|
@ -5,7 +5,6 @@ import (
|
|||
"math/rand"
|
||||
|
||||
"github.com/osbuild/images/internal/environment"
|
||||
"github.com/osbuild/images/internal/workload"
|
||||
"github.com/osbuild/images/pkg/arch"
|
||||
"github.com/osbuild/images/pkg/artifact"
|
||||
"github.com/osbuild/images/pkg/datasizes"
|
||||
|
|
@ -20,7 +19,7 @@ type AnacondaLiveInstaller struct {
|
|||
Platform platform.Platform
|
||||
InstallerCustomizations manifest.InstallerCustomizations
|
||||
Environment environment.Environment
|
||||
Workload workload.Workload
|
||||
ImgTypeCustomizations manifest.OSCustomizations
|
||||
|
||||
ExtraBasePackages rpmmd.PackageSet
|
||||
|
||||
|
|
|
|||
3
vendor/github.com/osbuild/images/pkg/image/anaconda_net_installer.go
generated
vendored
3
vendor/github.com/osbuild/images/pkg/image/anaconda_net_installer.go
generated
vendored
|
|
@ -5,7 +5,6 @@ import (
|
|||
"math/rand"
|
||||
|
||||
"github.com/osbuild/images/internal/environment"
|
||||
"github.com/osbuild/images/internal/workload"
|
||||
"github.com/osbuild/images/pkg/arch"
|
||||
"github.com/osbuild/images/pkg/artifact"
|
||||
"github.com/osbuild/images/pkg/customizations/anaconda"
|
||||
|
|
@ -21,7 +20,7 @@ type AnacondaNetInstaller struct {
|
|||
Platform platform.Platform
|
||||
InstallerCustomizations manifest.InstallerCustomizations
|
||||
Environment environment.Environment
|
||||
Workload workload.Workload
|
||||
ImgTypeCustomizations manifest.OSCustomizations
|
||||
|
||||
ExtraBasePackages rpmmd.PackageSet
|
||||
|
||||
|
|
|
|||
30
vendor/github.com/osbuild/images/pkg/image/anaconda_tar_installer.go
generated
vendored
30
vendor/github.com/osbuild/images/pkg/image/anaconda_tar_installer.go
generated
vendored
|
|
@ -3,10 +3,8 @@ package image
|
|||
import (
|
||||
"fmt"
|
||||
"math/rand"
|
||||
"path/filepath"
|
||||
|
||||
"github.com/osbuild/images/internal/environment"
|
||||
"github.com/osbuild/images/internal/workload"
|
||||
"github.com/osbuild/images/pkg/arch"
|
||||
"github.com/osbuild/images/pkg/artifact"
|
||||
"github.com/osbuild/images/pkg/customizations/anaconda"
|
||||
|
|
@ -44,7 +42,7 @@ type AnacondaTarInstaller struct {
|
|||
OSCustomizations manifest.OSCustomizations
|
||||
InstallerCustomizations manifest.InstallerCustomizations
|
||||
Environment environment.Environment
|
||||
Workload workload.Workload
|
||||
ImgTypeCustomizations manifest.OSCustomizations
|
||||
|
||||
ExtraBasePackages rpmmd.PackageSet
|
||||
|
||||
|
|
@ -79,19 +77,9 @@ func (img *AnacondaTarInstaller) InstantiateManifest(m *manifest.Manifest,
|
|||
img.Kickstart = &kickstart.Options{}
|
||||
}
|
||||
|
||||
if img.Kickstart.Unattended {
|
||||
// if we're building an unattended installer, override the
|
||||
// ISORootKickstart option
|
||||
img.InstallerCustomizations.ISORootKickstart = true
|
||||
}
|
||||
|
||||
if img.InstallerCustomizations.ISORootKickstart {
|
||||
// kickstart file will be in the iso root and not interactive-defaults,
|
||||
// so let's make sure the kickstart path option is set
|
||||
if img.Kickstart.Path == "" {
|
||||
img.Kickstart.Path = osbuild.KickstartPathOSBuild
|
||||
}
|
||||
}
|
||||
|
||||
anacondaPipeline := manifest.NewAnacondaInstaller(
|
||||
manifest.AnacondaInstallerTypePayload,
|
||||
|
|
@ -129,11 +117,6 @@ func (img *AnacondaTarInstaller) InstantiateManifest(m *manifest.Manifest,
|
|||
|
||||
tarPath := "/liveimg.tar.gz"
|
||||
|
||||
if !img.InstallerCustomizations.ISORootKickstart {
|
||||
payloadPath := filepath.Join("/run/install/repo/", tarPath)
|
||||
anacondaPipeline.InteractiveDefaults = manifest.NewAnacondaInteractiveDefaults(fmt.Sprintf("file://%s", payloadPath))
|
||||
}
|
||||
|
||||
anacondaPipeline.Checkpoint()
|
||||
|
||||
var rootfsImagePipeline *manifest.ISORootfsImg
|
||||
|
|
@ -150,10 +133,11 @@ func (img *AnacondaTarInstaller) InstantiateManifest(m *manifest.Manifest,
|
|||
bootTreePipeline.ISOLabel = img.ISOLabel
|
||||
bootTreePipeline.DefaultMenu = img.InstallerCustomizations.DefaultMenu
|
||||
|
||||
kernelOpts := []string{fmt.Sprintf("inst.stage2=hd:LABEL=%s", img.ISOLabel)}
|
||||
if img.InstallerCustomizations.ISORootKickstart {
|
||||
kernelOpts = append(kernelOpts, fmt.Sprintf("inst.ks=hd:LABEL=%s:%s", img.ISOLabel, img.Kickstart.Path))
|
||||
kernelOpts := []string{
|
||||
fmt.Sprintf("inst.stage2=hd:LABEL=%s", img.ISOLabel),
|
||||
fmt.Sprintf("inst.ks=hd:LABEL=%s:%s", img.ISOLabel, img.Kickstart.Path),
|
||||
}
|
||||
|
||||
if img.OSCustomizations.FIPS {
|
||||
kernelOpts = append(kernelOpts, "fips=1")
|
||||
}
|
||||
|
|
@ -164,7 +148,7 @@ func (img *AnacondaTarInstaller) InstantiateManifest(m *manifest.Manifest,
|
|||
osPipeline := manifest.NewOS(buildPipeline, img.Platform, repos)
|
||||
osPipeline.OSCustomizations = img.OSCustomizations
|
||||
osPipeline.Environment = img.Environment
|
||||
osPipeline.Workload = img.Workload
|
||||
osPipeline.ImgTypeCustomizations = img.ImgTypeCustomizations
|
||||
|
||||
isoTreePipeline := manifest.NewAnacondaInstallerISOTree(buildPipeline, anacondaPipeline, rootfsImagePipeline, bootTreePipeline)
|
||||
// TODO: the partition table is required - make it a ctor arg or set a default one in the pipeline
|
||||
|
|
@ -172,9 +156,7 @@ func (img *AnacondaTarInstaller) InstantiateManifest(m *manifest.Manifest,
|
|||
isoTreePipeline.Release = img.Release
|
||||
isoTreePipeline.Kickstart = img.Kickstart
|
||||
isoTreePipeline.PayloadPath = tarPath
|
||||
if img.InstallerCustomizations.ISORootKickstart {
|
||||
isoTreePipeline.Kickstart.Path = img.Kickstart.Path
|
||||
}
|
||||
|
||||
isoTreePipeline.RootfsCompression = img.RootfsCompression
|
||||
isoTreePipeline.RootfsType = img.InstallerCustomizations.ISORootfsType
|
||||
|
|
|
|||
5
vendor/github.com/osbuild/images/pkg/image/archive.go
generated
vendored
5
vendor/github.com/osbuild/images/pkg/image/archive.go
generated
vendored
|
|
@ -4,7 +4,6 @@ import (
|
|||
"math/rand"
|
||||
|
||||
"github.com/osbuild/images/internal/environment"
|
||||
"github.com/osbuild/images/internal/workload"
|
||||
"github.com/osbuild/images/pkg/artifact"
|
||||
"github.com/osbuild/images/pkg/manifest"
|
||||
"github.com/osbuild/images/pkg/platform"
|
||||
|
|
@ -17,7 +16,7 @@ type Archive struct {
|
|||
Platform platform.Platform
|
||||
OSCustomizations manifest.OSCustomizations
|
||||
Environment environment.Environment
|
||||
Workload workload.Workload
|
||||
ImgTypeCustomizations manifest.OSCustomizations
|
||||
Filename string
|
||||
Compression string
|
||||
|
||||
|
|
@ -40,7 +39,7 @@ func (img *Archive) InstantiateManifest(m *manifest.Manifest,
|
|||
osPipeline := manifest.NewOS(buildPipeline, img.Platform, repos)
|
||||
osPipeline.OSCustomizations = img.OSCustomizations
|
||||
osPipeline.Environment = img.Environment
|
||||
osPipeline.Workload = img.Workload
|
||||
osPipeline.ImgTypeCustomizations = img.ImgTypeCustomizations
|
||||
osPipeline.OSVersion = img.OSVersion
|
||||
|
||||
tarPipeline := manifest.NewTar(buildPipeline, osPipeline, "archive")
|
||||
|
|
|
|||
5
vendor/github.com/osbuild/images/pkg/image/container.go
generated
vendored
5
vendor/github.com/osbuild/images/pkg/image/container.go
generated
vendored
|
|
@ -4,7 +4,6 @@ import (
|
|||
"math/rand"
|
||||
|
||||
"github.com/osbuild/images/internal/environment"
|
||||
"github.com/osbuild/images/internal/workload"
|
||||
"github.com/osbuild/images/pkg/artifact"
|
||||
"github.com/osbuild/images/pkg/manifest"
|
||||
"github.com/osbuild/images/pkg/platform"
|
||||
|
|
@ -17,7 +16,7 @@ type BaseContainer struct {
|
|||
Platform platform.Platform
|
||||
OSCustomizations manifest.OSCustomizations
|
||||
Environment environment.Environment
|
||||
Workload workload.Workload
|
||||
ImgTypeCustomizations manifest.OSCustomizations
|
||||
Filename string
|
||||
}
|
||||
|
||||
|
|
@ -37,7 +36,7 @@ func (img *BaseContainer) InstantiateManifest(m *manifest.Manifest,
|
|||
osPipeline := manifest.NewOS(buildPipeline, img.Platform, repos)
|
||||
osPipeline.OSCustomizations = img.OSCustomizations
|
||||
osPipeline.Environment = img.Environment
|
||||
osPipeline.Workload = img.Workload
|
||||
osPipeline.ImgTypeCustomizations = img.ImgTypeCustomizations
|
||||
|
||||
ociPipeline := manifest.NewOCIContainer(buildPipeline, osPipeline)
|
||||
ociPipeline.SetFilename(img.Filename)
|
||||
|
|
|
|||
5
vendor/github.com/osbuild/images/pkg/image/disk.go
generated
vendored
5
vendor/github.com/osbuild/images/pkg/image/disk.go
generated
vendored
|
|
@ -7,7 +7,6 @@ import (
|
|||
"strings"
|
||||
|
||||
"github.com/osbuild/images/internal/environment"
|
||||
"github.com/osbuild/images/internal/workload"
|
||||
"github.com/osbuild/images/pkg/artifact"
|
||||
"github.com/osbuild/images/pkg/disk"
|
||||
"github.com/osbuild/images/pkg/manifest"
|
||||
|
|
@ -23,7 +22,7 @@ type DiskImage struct {
|
|||
PartitionTable *disk.PartitionTable
|
||||
OSCustomizations manifest.OSCustomizations
|
||||
Environment environment.Environment
|
||||
Workload workload.Workload
|
||||
ImgTypeCustomizations manifest.OSCustomizations
|
||||
Filename string
|
||||
Compression string
|
||||
|
||||
|
|
@ -56,7 +55,7 @@ func (img *DiskImage) InstantiateManifest(m *manifest.Manifest,
|
|||
osPipeline.PartitionTable = img.PartitionTable
|
||||
osPipeline.OSCustomizations = img.OSCustomizations
|
||||
osPipeline.Environment = img.Environment
|
||||
osPipeline.Workload = img.Workload
|
||||
osPipeline.ImgTypeCustomizations = img.ImgTypeCustomizations
|
||||
osPipeline.OSProduct = img.OSProduct
|
||||
osPipeline.OSVersion = img.OSVersion
|
||||
osPipeline.OSNick = img.OSNick
|
||||
|
|
|
|||
5
vendor/github.com/osbuild/images/pkg/image/ostree_archive.go
generated
vendored
5
vendor/github.com/osbuild/images/pkg/image/ostree_archive.go
generated
vendored
|
|
@ -4,7 +4,6 @@ import (
|
|||
"math/rand"
|
||||
|
||||
"github.com/osbuild/images/internal/environment"
|
||||
"github.com/osbuild/images/internal/workload"
|
||||
"github.com/osbuild/images/pkg/artifact"
|
||||
"github.com/osbuild/images/pkg/customizations/bootc"
|
||||
"github.com/osbuild/images/pkg/manifest"
|
||||
|
|
@ -19,7 +18,7 @@ type OSTreeArchive struct {
|
|||
Platform platform.Platform
|
||||
OSCustomizations manifest.OSCustomizations
|
||||
Environment environment.Environment
|
||||
Workload workload.Workload
|
||||
ImgTypeCustomizations manifest.OSCustomizations
|
||||
|
||||
// OSTreeParent specifies the source for an optional parent commit for the
|
||||
// new commit being built.
|
||||
|
|
@ -59,7 +58,7 @@ func (img *OSTreeArchive) InstantiateManifest(m *manifest.Manifest,
|
|||
osPipeline := manifest.NewOS(buildPipeline, img.Platform, repos)
|
||||
osPipeline.OSCustomizations = img.OSCustomizations
|
||||
osPipeline.Environment = img.Environment
|
||||
osPipeline.Workload = img.Workload
|
||||
osPipeline.ImgTypeCustomizations = img.ImgTypeCustomizations
|
||||
osPipeline.OSTreeParent = img.OSTreeParent
|
||||
osPipeline.OSTreeRef = img.OSTreeRef
|
||||
osPipeline.OSCustomizations.InstallWeakDeps = img.InstallWeakDeps
|
||||
|
|
|
|||
5
vendor/github.com/osbuild/images/pkg/image/ostree_container.go
generated
vendored
5
vendor/github.com/osbuild/images/pkg/image/ostree_container.go
generated
vendored
|
|
@ -4,7 +4,6 @@ import (
|
|||
"math/rand"
|
||||
|
||||
"github.com/osbuild/images/internal/environment"
|
||||
"github.com/osbuild/images/internal/workload"
|
||||
"github.com/osbuild/images/pkg/artifact"
|
||||
"github.com/osbuild/images/pkg/manifest"
|
||||
"github.com/osbuild/images/pkg/ostree"
|
||||
|
|
@ -18,7 +17,7 @@ type OSTreeContainer struct {
|
|||
Platform platform.Platform
|
||||
OSCustomizations manifest.OSCustomizations
|
||||
Environment environment.Environment
|
||||
Workload workload.Workload
|
||||
ImgTypeCustomizations manifest.OSCustomizations
|
||||
|
||||
// OSTreeParent specifies the source for an optional parent commit for the
|
||||
// new commit being built.
|
||||
|
|
@ -50,7 +49,7 @@ func (img *OSTreeContainer) InstantiateManifest(m *manifest.Manifest,
|
|||
osPipeline := manifest.NewOS(buildPipeline, img.Platform, repos)
|
||||
osPipeline.OSCustomizations = img.OSCustomizations
|
||||
osPipeline.Environment = img.Environment
|
||||
osPipeline.Workload = img.Workload
|
||||
osPipeline.ImgTypeCustomizations = img.ImgTypeCustomizations
|
||||
osPipeline.OSTreeRef = img.OSTreeRef
|
||||
osPipeline.OSTreeParent = img.OSTreeParent
|
||||
|
||||
|
|
|
|||
10
vendor/github.com/osbuild/images/pkg/image/ostree_disk.go
generated
vendored
10
vendor/github.com/osbuild/images/pkg/image/ostree_disk.go
generated
vendored
|
|
@ -4,7 +4,6 @@ import (
|
|||
"fmt"
|
||||
"math/rand"
|
||||
|
||||
"github.com/osbuild/images/internal/workload"
|
||||
"github.com/osbuild/images/pkg/artifact"
|
||||
"github.com/osbuild/images/pkg/container"
|
||||
"github.com/osbuild/images/pkg/disk"
|
||||
|
|
@ -19,7 +18,7 @@ type OSTreeDiskImage struct {
|
|||
Base
|
||||
|
||||
Platform platform.Platform
|
||||
Workload workload.Workload
|
||||
ImgTypeCustomizations manifest.OSCustomizations
|
||||
PartitionTable *disk.PartitionTable
|
||||
|
||||
OSTreeDeploymentCustomizations manifest.OSTreeDeploymentCustomizations
|
||||
|
|
@ -80,10 +79,9 @@ func baseRawOstreeImage(img *OSTreeDiskImage, buildPipeline manifest.Build, opts
|
|||
osPipeline.UseBootupd = opts.useBootupd
|
||||
|
||||
// other image types (e.g. live) pass the workload to the pipeline.
|
||||
if img.Workload != nil {
|
||||
osPipeline.EnabledServices = img.Workload.GetServices()
|
||||
osPipeline.DisabledServices = img.Workload.GetDisabledServices()
|
||||
}
|
||||
osPipeline.EnabledServices = img.ImgTypeCustomizations.EnabledServices
|
||||
osPipeline.DisabledServices = img.ImgTypeCustomizations.DisabledServices
|
||||
|
||||
return manifest.NewRawOStreeImage(buildPipeline, osPipeline, img.Platform)
|
||||
}
|
||||
|
||||
|
|
|
|||
3
vendor/github.com/osbuild/images/pkg/image/ostree_simplified_installer.go
generated
vendored
3
vendor/github.com/osbuild/images/pkg/image/ostree_simplified_installer.go
generated
vendored
|
|
@ -5,7 +5,6 @@ import (
|
|||
"math/rand"
|
||||
|
||||
"github.com/osbuild/images/internal/environment"
|
||||
"github.com/osbuild/images/internal/workload"
|
||||
"github.com/osbuild/images/pkg/arch"
|
||||
"github.com/osbuild/images/pkg/artifact"
|
||||
"github.com/osbuild/images/pkg/customizations/fdo"
|
||||
|
|
@ -25,7 +24,7 @@ type OSTreeSimplifiedInstaller struct {
|
|||
Platform platform.Platform
|
||||
OSCustomizations manifest.OSCustomizations
|
||||
Environment environment.Environment
|
||||
Workload workload.Workload
|
||||
ImgTypeCustomizations manifest.OSCustomizations
|
||||
|
||||
ExtraBasePackages rpmmd.PackageSet
|
||||
|
||||
|
|
|
|||
8
vendor/github.com/osbuild/images/pkg/manifest/installer.go
generated
vendored
8
vendor/github.com/osbuild/images/pkg/manifest/installer.go
generated
vendored
|
|
@ -24,12 +24,4 @@ type InstallerCustomizations struct {
|
|||
ISOBoot ISOBootType
|
||||
|
||||
DefaultMenu int
|
||||
|
||||
// If set, the kickstart file will be added to the bootiso-tree at the
|
||||
// default path for osbuild, otherwise any kickstart options will be
|
||||
// configured in the default location for interactive defaults in the
|
||||
// rootfs. Enabling UnattendedKickstart automatically enables this option
|
||||
// because automatic installations cannot be configured using interactive
|
||||
// defaults.
|
||||
ISORootKickstart bool
|
||||
}
|
||||
|
|
|
|||
41
vendor/github.com/osbuild/images/pkg/manifest/os.go
generated
vendored
41
vendor/github.com/osbuild/images/pkg/manifest/os.go
generated
vendored
|
|
@ -10,7 +10,6 @@ import (
|
|||
|
||||
"github.com/osbuild/images/internal/common"
|
||||
"github.com/osbuild/images/internal/environment"
|
||||
"github.com/osbuild/images/internal/workload"
|
||||
"github.com/osbuild/images/pkg/arch"
|
||||
"github.com/osbuild/images/pkg/container"
|
||||
"github.com/osbuild/images/pkg/customizations/bootc"
|
||||
|
|
@ -40,6 +39,10 @@ type OSCustomizations struct {
|
|||
// These are the statically defined packages for the image type.
|
||||
BasePackages []string
|
||||
|
||||
// Modules to install in addition to the ones required by the pipeline.
|
||||
// These are the statically defined packages for the image type.
|
||||
BaseModules []string
|
||||
|
||||
// Packages to exclude from the base package set. This is useful in
|
||||
// case of weak dependencies, comps groups, or where multiple packages
|
||||
// can satisfy a dependency. Must not conflict with the included base
|
||||
|
|
@ -193,8 +196,10 @@ type OS struct {
|
|||
|
||||
// Environment the system will run in
|
||||
Environment environment.Environment
|
||||
// Workload to install on top of the base system
|
||||
Workload workload.Workload
|
||||
|
||||
// ImageTypeCustomizations come from the image type
|
||||
ImgTypeCustomizations OSCustomizations
|
||||
|
||||
// Ref of ostree commit (optional). If empty the tree cannot be in an ostree commit
|
||||
OSTreeRef string
|
||||
// OSTreeParent source spec (optional). If nil the new commit (if
|
||||
|
|
@ -335,24 +340,22 @@ func (p *OS) getPackageSetChain(Distro) []rpmmd.PackageSet {
|
|||
},
|
||||
}
|
||||
|
||||
if p.Workload != nil {
|
||||
workloadPackages := p.Workload.GetPackages()
|
||||
if len(workloadPackages) > 0 {
|
||||
imgTypePackages := p.ImgTypeCustomizations.BasePackages
|
||||
if len(imgTypePackages) > 0 {
|
||||
ps := rpmmd.PackageSet{
|
||||
Include: workloadPackages,
|
||||
Repositories: append(osRepos, p.Workload.GetRepos()...),
|
||||
Include: imgTypePackages,
|
||||
Repositories: append(osRepos, p.ImgTypeCustomizations.ExtraBaseRepos...),
|
||||
// Although 'false' is the default value, set it explicitly to make
|
||||
// it visible that we are not adding weak dependencies.
|
||||
InstallWeakDeps: false,
|
||||
}
|
||||
|
||||
workloadModules := p.Workload.GetEnabledModules()
|
||||
if len(workloadModules) > 0 {
|
||||
ps.EnabledModules = workloadModules
|
||||
imgTypeModules := p.ImgTypeCustomizations.BaseModules
|
||||
if len(imgTypeModules) > 0 {
|
||||
ps.EnabledModules = imgTypeModules
|
||||
}
|
||||
chain = append(chain, ps)
|
||||
}
|
||||
}
|
||||
|
||||
return chain
|
||||
}
|
||||
|
|
@ -503,9 +506,8 @@ func (p *OS) serialize() osbuild.Pipeline {
|
|||
|
||||
// collect all repos for this pipeline to create the repository options
|
||||
allRepos := append(p.repos, p.OSCustomizations.ExtraBaseRepos...)
|
||||
if p.Workload != nil {
|
||||
allRepos = append(allRepos, p.Workload.GetRepos()...)
|
||||
}
|
||||
allRepos = append(allRepos, p.ImgTypeCustomizations.ExtraBaseRepos...)
|
||||
|
||||
rpmOptions := osbuild.NewRPMStageOptions(allRepos)
|
||||
if p.OSCustomizations.ExcludeDocs {
|
||||
if rpmOptions.Exclude == nil {
|
||||
|
|
@ -858,11 +860,10 @@ func (p *OS) serialize() osbuild.Pipeline {
|
|||
if p.Environment != nil {
|
||||
enabledServices = append(enabledServices, p.Environment.GetServices()...)
|
||||
}
|
||||
if p.Workload != nil {
|
||||
enabledServices = append(enabledServices, p.Workload.GetServices()...)
|
||||
disabledServices = append(disabledServices, p.Workload.GetDisabledServices()...)
|
||||
maskedServices = append(maskedServices, p.Workload.GetMaskedServices()...)
|
||||
}
|
||||
enabledServices = append(enabledServices, p.ImgTypeCustomizations.EnabledServices...)
|
||||
disabledServices = append(disabledServices, p.ImgTypeCustomizations.DisabledServices...)
|
||||
maskedServices = append(maskedServices, p.ImgTypeCustomizations.MaskedServices...)
|
||||
|
||||
if len(enabledServices) != 0 ||
|
||||
len(disabledServices) != 0 ||
|
||||
len(maskedServices) != 0 || p.OSCustomizations.DefaultTarget != "" {
|
||||
|
|
|
|||
74
vendor/github.com/osbuild/images/pkg/platform/aarch64.go
generated
vendored
74
vendor/github.com/osbuild/images/pkg/platform/aarch64.go
generated
vendored
|
|
@ -1,74 +0,0 @@
|
|||
package platform
|
||||
|
||||
import (
|
||||
"github.com/osbuild/images/pkg/arch"
|
||||
)
|
||||
|
||||
type Aarch64 struct {
|
||||
BasePlatform
|
||||
UEFIVendor string
|
||||
}
|
||||
|
||||
func (p *Aarch64) GetArch() arch.Arch {
|
||||
return arch.ARCH_AARCH64
|
||||
}
|
||||
|
||||
func (p *Aarch64) GetUEFIVendor() string {
|
||||
return p.UEFIVendor
|
||||
}
|
||||
|
||||
func (p *Aarch64) GetPackages() []string {
|
||||
packages := p.BasePlatform.FirmwarePackages
|
||||
|
||||
if p.UEFIVendor != "" {
|
||||
packages = append(packages,
|
||||
"dracut-config-generic",
|
||||
"efibootmgr",
|
||||
"grub2-efi-aa64",
|
||||
"grub2-tools",
|
||||
"shim-aa64")
|
||||
}
|
||||
|
||||
return packages
|
||||
}
|
||||
|
||||
func (p *Aarch64) GetBootloader() Bootloader {
|
||||
return BOOTLOADER_GRUB2
|
||||
}
|
||||
|
||||
type Aarch64_Fedora struct {
|
||||
BasePlatform
|
||||
UEFIVendor string
|
||||
BootFiles [][2]string
|
||||
}
|
||||
|
||||
func (p *Aarch64_Fedora) GetArch() arch.Arch {
|
||||
return arch.ARCH_AARCH64
|
||||
}
|
||||
|
||||
func (p *Aarch64_Fedora) GetUEFIVendor() string {
|
||||
return p.UEFIVendor
|
||||
}
|
||||
|
||||
func (p *Aarch64_Fedora) GetPackages() []string {
|
||||
packages := p.BasePlatform.FirmwarePackages
|
||||
|
||||
if p.UEFIVendor != "" {
|
||||
packages = append(packages,
|
||||
"dracut-config-generic",
|
||||
"efibootmgr",
|
||||
"grub2-efi-aa64",
|
||||
"grub2-tools",
|
||||
"shim-aa64")
|
||||
}
|
||||
|
||||
return packages
|
||||
}
|
||||
|
||||
func (p *Aarch64_Fedora) GetBootFiles() [][2]string {
|
||||
return p.BootFiles
|
||||
}
|
||||
|
||||
func (p *Aarch64_Fedora) GetBootloader() Bootloader {
|
||||
return BOOTLOADER_GRUB2
|
||||
}
|
||||
53
vendor/github.com/osbuild/images/pkg/platform/ppc64le.go
generated
vendored
53
vendor/github.com/osbuild/images/pkg/platform/ppc64le.go
generated
vendored
|
|
@ -1,53 +0,0 @@
|
|||
package platform
|
||||
|
||||
import (
|
||||
"github.com/osbuild/images/pkg/arch"
|
||||
)
|
||||
|
||||
type PPC64LE struct {
|
||||
BasePlatform
|
||||
BIOS bool
|
||||
}
|
||||
|
||||
func (p *PPC64LE) GetArch() arch.Arch {
|
||||
return arch.ARCH_PPC64LE
|
||||
}
|
||||
|
||||
func (p *PPC64LE) GetBIOSPlatform() string {
|
||||
if p.BIOS {
|
||||
return "powerpc-ieee1275"
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (p *PPC64LE) GetPackages() []string {
|
||||
packages := p.BasePlatform.FirmwarePackages
|
||||
|
||||
if p.BIOS {
|
||||
packages = append(packages,
|
||||
"dracut-config-generic",
|
||||
"powerpc-utils",
|
||||
"grub2-ppc64le",
|
||||
"grub2-ppc64le-modules",
|
||||
)
|
||||
}
|
||||
|
||||
return packages
|
||||
}
|
||||
|
||||
func (p *PPC64LE) GetBuildPackages() []string {
|
||||
packages := []string{}
|
||||
|
||||
if p.BIOS {
|
||||
packages = append(packages,
|
||||
"grub2-ppc64le",
|
||||
"grub2-ppc64le-modules",
|
||||
)
|
||||
}
|
||||
|
||||
return packages
|
||||
}
|
||||
|
||||
func (p *PPC64LE) GetBootloader() Bootloader {
|
||||
return BOOTLOADER_GRUB2
|
||||
}
|
||||
46
vendor/github.com/osbuild/images/pkg/platform/riscv64.go
generated
vendored
46
vendor/github.com/osbuild/images/pkg/platform/riscv64.go
generated
vendored
|
|
@ -1,46 +0,0 @@
|
|||
package platform
|
||||
|
||||
import (
|
||||
"github.com/osbuild/images/pkg/arch"
|
||||
)
|
||||
|
||||
type RISCV64 struct {
|
||||
BasePlatform
|
||||
UEFIVendor string
|
||||
}
|
||||
|
||||
func (p *RISCV64) GetArch() arch.Arch {
|
||||
return arch.ARCH_RISCV64
|
||||
}
|
||||
|
||||
func (p *RISCV64) GetPackages() []string {
|
||||
packages := p.BasePlatform.FirmwarePackages
|
||||
|
||||
if p.UEFIVendor != "" {
|
||||
packages = append(packages,
|
||||
// XXX: this is needed to get a generic bootkernel,
|
||||
// this should probably be part of any bootable img
|
||||
// packagelist
|
||||
"dracut-config-generic",
|
||||
"grub2-efi-riscv64",
|
||||
"grub2-efi-riscv64-modules",
|
||||
"shim-unsigned-riscv64",
|
||||
)
|
||||
}
|
||||
|
||||
return packages
|
||||
}
|
||||
|
||||
func (p *RISCV64) GetBuildPackages() []string {
|
||||
var packages []string
|
||||
|
||||
return packages
|
||||
}
|
||||
|
||||
func (p *RISCV64) GetUEFIVendor() string {
|
||||
return p.UEFIVendor
|
||||
}
|
||||
|
||||
func (p *RISCV64) GetBootloader() Bootloader {
|
||||
return BOOTLOADER_GRUB2
|
||||
}
|
||||
46
vendor/github.com/osbuild/images/pkg/platform/s390x.go
generated
vendored
46
vendor/github.com/osbuild/images/pkg/platform/s390x.go
generated
vendored
|
|
@ -1,46 +0,0 @@
|
|||
package platform
|
||||
|
||||
import (
|
||||
"github.com/osbuild/images/pkg/arch"
|
||||
)
|
||||
|
||||
type S390X struct {
|
||||
BasePlatform
|
||||
Zipl bool
|
||||
}
|
||||
|
||||
func (p *S390X) GetArch() arch.Arch {
|
||||
return arch.ARCH_S390X
|
||||
}
|
||||
|
||||
func (p *S390X) GetZiplSupport() bool {
|
||||
return p.Zipl
|
||||
}
|
||||
|
||||
func (p *S390X) GetPackages() []string {
|
||||
packages := p.BasePlatform.FirmwarePackages
|
||||
|
||||
if p.Zipl {
|
||||
packages = append(packages,
|
||||
"dracut-config-generic",
|
||||
"s390utils-base",
|
||||
"s390utils-core",
|
||||
)
|
||||
}
|
||||
|
||||
return packages
|
||||
}
|
||||
|
||||
func (p *S390X) GetBuildPackages() []string {
|
||||
packages := []string{}
|
||||
|
||||
if p.Zipl {
|
||||
packages = append(packages, "s390utils-base")
|
||||
}
|
||||
|
||||
return packages
|
||||
}
|
||||
|
||||
func (p *S390X) GetBootloader() Bootloader {
|
||||
return BOOTLOADER_ZIPL
|
||||
}
|
||||
72
vendor/github.com/osbuild/images/pkg/platform/x86_64.go
generated
vendored
72
vendor/github.com/osbuild/images/pkg/platform/x86_64.go
generated
vendored
|
|
@ -1,72 +0,0 @@
|
|||
package platform
|
||||
|
||||
import (
|
||||
"github.com/osbuild/images/pkg/arch"
|
||||
)
|
||||
|
||||
type X86 struct {
|
||||
BasePlatform
|
||||
BIOS bool
|
||||
UEFIVendor string
|
||||
Bootloader Bootloader
|
||||
}
|
||||
|
||||
func (p *X86) GetArch() arch.Arch {
|
||||
return arch.ARCH_X86_64
|
||||
}
|
||||
|
||||
func (p *X86) GetBIOSPlatform() string {
|
||||
if p.BIOS {
|
||||
return "i386-pc"
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (p *X86) GetUEFIVendor() string {
|
||||
return p.UEFIVendor
|
||||
}
|
||||
|
||||
func (p *X86) GetPackages() []string {
|
||||
packages := p.BasePlatform.FirmwarePackages
|
||||
|
||||
switch p.GetBootloader() {
|
||||
case BOOTLOADER_GRUB2:
|
||||
if p.BIOS {
|
||||
packages = append(packages,
|
||||
"dracut-config-generic",
|
||||
"grub2-pc")
|
||||
}
|
||||
|
||||
if p.UEFIVendor != "" {
|
||||
packages = append(packages,
|
||||
"dracut-config-generic",
|
||||
"efibootmgr",
|
||||
"grub2-efi-x64",
|
||||
"shim-x64")
|
||||
}
|
||||
case BOOTLOADER_UKI:
|
||||
packages = append(packages,
|
||||
"efibootmgr",
|
||||
"kernel-uki-virt-addons", // provides useful cmdline utilities for the UKI
|
||||
"shim-x64",
|
||||
"uki-direct",
|
||||
)
|
||||
}
|
||||
|
||||
return packages
|
||||
}
|
||||
|
||||
func (p *X86) GetBuildPackages() []string {
|
||||
packages := []string{}
|
||||
if p.BIOS {
|
||||
packages = append(packages, "grub2-pc")
|
||||
}
|
||||
return packages
|
||||
}
|
||||
|
||||
func (p *X86) GetBootloader() Bootloader {
|
||||
if p.Bootloader == BOOTLOADER_NONE {
|
||||
return BOOTLOADER_GRUB2
|
||||
}
|
||||
return p.Bootloader
|
||||
}
|
||||
52
vendor/github.com/osbuild/images/pkg/platform/yaml.go
generated
vendored
52
vendor/github.com/osbuild/images/pkg/platform/yaml.go
generated
vendored
|
|
@ -4,9 +4,9 @@ import (
|
|||
"github.com/osbuild/images/pkg/arch"
|
||||
)
|
||||
|
||||
// PlatformConf is a platform configured from YAML inputs
|
||||
// Data is a platform configured from YAML inputs
|
||||
// that implements the "Platform" interface
|
||||
type PlatformConf struct {
|
||||
type Data struct {
|
||||
Arch arch.Arch `yaml:"arch"`
|
||||
ImageFormat ImageFormat `yaml:"image_format"`
|
||||
QCOW2Compat string `yaml:"qcow2_compat"`
|
||||
|
|
@ -25,50 +25,50 @@ type PlatformConf struct {
|
|||
FIPSMenu bool `yaml:"fips_menu"` // Add FIPS entry to iso bootloader menu
|
||||
}
|
||||
|
||||
// ensure PlatformConf implements the Platform interface
|
||||
var _ = Platform(&PlatformConf{})
|
||||
// ensure platform.Data implements the Platform interface
|
||||
var _ = Platform(&Data{})
|
||||
|
||||
func (pc *PlatformConf) GetArch() arch.Arch {
|
||||
return pc.Arch
|
||||
func (d *Data) GetArch() arch.Arch {
|
||||
return d.Arch
|
||||
}
|
||||
func (pc *PlatformConf) GetImageFormat() ImageFormat {
|
||||
return pc.ImageFormat
|
||||
func (d *Data) GetImageFormat() ImageFormat {
|
||||
return d.ImageFormat
|
||||
}
|
||||
func (pc *PlatformConf) GetQCOW2Compat() string {
|
||||
return pc.QCOW2Compat
|
||||
func (d *Data) GetQCOW2Compat() string {
|
||||
return d.QCOW2Compat
|
||||
}
|
||||
func (pc *PlatformConf) GetBIOSPlatform() string {
|
||||
return pc.BIOSPlatform
|
||||
func (d *Data) GetBIOSPlatform() string {
|
||||
return d.BIOSPlatform
|
||||
}
|
||||
func (pc *PlatformConf) GetUEFIVendor() string {
|
||||
return pc.UEFIVendor
|
||||
func (d *Data) GetUEFIVendor() string {
|
||||
return d.UEFIVendor
|
||||
}
|
||||
func (pc *PlatformConf) GetZiplSupport() bool {
|
||||
return pc.ZiplSupport
|
||||
func (d *Data) GetZiplSupport() bool {
|
||||
return d.ZiplSupport
|
||||
}
|
||||
func (pc *PlatformConf) GetPackages() []string {
|
||||
func (d *Data) GetPackages() []string {
|
||||
var merged []string
|
||||
for _, pkgList := range pc.Packages {
|
||||
for _, pkgList := range d.Packages {
|
||||
merged = append(merged, pkgList...)
|
||||
}
|
||||
return merged
|
||||
}
|
||||
func (pc *PlatformConf) GetBuildPackages() []string {
|
||||
func (d *Data) GetBuildPackages() []string {
|
||||
var merged []string
|
||||
for _, pkgList := range pc.BuildPackages {
|
||||
for _, pkgList := range d.BuildPackages {
|
||||
merged = append(merged, pkgList...)
|
||||
}
|
||||
return merged
|
||||
}
|
||||
func (pc *PlatformConf) GetBootFiles() [][2]string {
|
||||
return pc.BootFiles
|
||||
func (d *Data) GetBootFiles() [][2]string {
|
||||
return d.BootFiles
|
||||
}
|
||||
|
||||
func (pc *PlatformConf) GetBootloader() Bootloader {
|
||||
return pc.Bootloader
|
||||
func (d *Data) GetBootloader() Bootloader {
|
||||
return d.Bootloader
|
||||
}
|
||||
|
||||
// GetFIPSMenu is used to add the FIPS entry to the iso bootloader menu
|
||||
func (pc *PlatformConf) GetFIPSMenu() bool {
|
||||
return pc.FIPSMenu
|
||||
func (d *Data) GetFIPSMenu() bool {
|
||||
return d.FIPSMenu
|
||||
}
|
||||
|
|
|
|||
3
vendor/modules.txt
vendored
3
vendor/modules.txt
vendored
|
|
@ -958,14 +958,13 @@ github.com/oracle/oci-go-sdk/v54/workrequests
|
|||
## explicit; go 1.23.9
|
||||
github.com/osbuild/blueprint/internal/common
|
||||
github.com/osbuild/blueprint/pkg/blueprint
|
||||
# github.com/osbuild/images v0.177.0
|
||||
# github.com/osbuild/images v0.178.0
|
||||
## explicit; go 1.23.9
|
||||
github.com/osbuild/images/data/dependencies
|
||||
github.com/osbuild/images/data/distrodefs
|
||||
github.com/osbuild/images/data/repositories
|
||||
github.com/osbuild/images/internal/common
|
||||
github.com/osbuild/images/internal/environment
|
||||
github.com/osbuild/images/internal/workload
|
||||
github.com/osbuild/images/pkg/arch
|
||||
github.com/osbuild/images/pkg/artifact
|
||||
github.com/osbuild/images/pkg/cert
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue