Skip to content

Commit 0d0fd23

Browse files
mvo5supakeen
authored andcommitted
image: update bib for latest images
This commit makes bib use the latest images library, i.e. update for the explicit use of `OSCustomizations`.
1 parent 9e96476 commit 0d0fd23

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

bib/cmd/bootc-image-builder/image.go

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -369,15 +369,15 @@ func manifestForDiskImage(c *ManifestConfig, rng *rand.Rand) (*manifest.Manifest
369369
}
370370

371371
img := image.NewBootcDiskImage(containerSource, buildContainerSource)
372-
img.Users = users.UsersFromBP(customizations.GetUsers())
373-
img.Groups = users.GroupsFromBP(customizations.GetGroups())
374-
img.SELinux = c.SourceInfo.SELinuxPolicy
375-
img.BuildSELinux = img.SELinux
372+
img.OSCustomizations.Users = users.UsersFromBP(customizations.GetUsers())
373+
img.OSCustomizations.Groups = users.GroupsFromBP(customizations.GetGroups())
374+
img.OSCustomizations.SELinux = c.SourceInfo.SELinuxPolicy
375+
img.OSCustomizations.BuildSELinux = img.OSCustomizations.SELinux
376376
if c.BuildSourceInfo != nil {
377-
img.BuildSELinux = c.BuildSourceInfo.SELinuxPolicy
377+
img.OSCustomizations.BuildSELinux = c.BuildSourceInfo.SELinuxPolicy
378378
}
379379

380-
img.KernelOptionsAppend = []string{
380+
img.OSCustomizations.KernelOptionsAppend = []string{
381381
"rw",
382382
// TODO: Drop this as we expect kargs to come from the container image,
383383
// xref https://github.com/CentOS/centos-bootc-layered/blob/main/cloud/usr/lib/bootc/install/05-cloud-kargs.toml
@@ -415,7 +415,7 @@ func manifestForDiskImage(c *ManifestConfig, rng *rand.Rand) (*manifest.Manifest
415415
}
416416

417417
if kopts := customizations.GetKernel(); kopts != nil && kopts.Append != "" {
418-
img.KernelOptionsAppend = append(img.KernelOptionsAppend, kopts.Append)
418+
img.OSCustomizations.KernelOptionsAppend = append(img.OSCustomizations.KernelOptionsAppend, kopts.Append)
419419
}
420420

421421
pt, err := genPartitionTable(c, customizations, rng)
@@ -436,11 +436,11 @@ func manifestForDiskImage(c *ManifestConfig, rng *rand.Rand) (*manifest.Manifest
436436
if err := blueprint.CheckFileCustomizationsPolicy(fc, policies.OstreeCustomFilesPolicies); err != nil {
437437
return nil, err
438438
}
439-
img.Files, err = blueprint.FileCustomizationsToFsNodeFiles(fc)
439+
img.OSCustomizations.Files, err = blueprint.FileCustomizationsToFsNodeFiles(fc)
440440
if err != nil {
441441
return nil, err
442442
}
443-
img.Directories, err = blueprint.DirectoryCustomizationsToFsNodeDirectories(dc)
443+
img.OSCustomizations.Directories, err = blueprint.DirectoryCustomizationsToFsNodeDirectories(dc)
444444
if err != nil {
445445
return nil, err
446446
}

0 commit comments

Comments
 (0)