manifest: move ostree config stage after the deployment
Configure ostree after it's deployed and add the ostree mount. This fixes sysroot not being mounted 'ro' in the final image when it's booted.
This commit is contained in:
parent
9eab01874a
commit
445de61a80
1 changed files with 14 additions and 11 deletions
|
|
@ -93,17 +93,6 @@ func (p *OSTreeDeployment) serialize() osbuild.Pipeline {
|
|||
OSName: p.osName,
|
||||
},
|
||||
))
|
||||
pipeline.AddStage(osbuild.NewOSTreeConfigStage(
|
||||
&osbuild.OSTreeConfigStageOptions{
|
||||
Repo: repoPath,
|
||||
Config: &osbuild.OSTreeConfig{
|
||||
Sysroot: &osbuild.SysrootOptions{
|
||||
ReadOnly: common.BoolToPtr(true),
|
||||
Bootloader: "none",
|
||||
},
|
||||
},
|
||||
},
|
||||
))
|
||||
pipeline.AddStage(osbuild.NewMkdirStage(&osbuild.MkdirStageOptions{
|
||||
Paths: []osbuild.Path{
|
||||
{
|
||||
|
|
@ -156,6 +145,20 @@ func (p *OSTreeDeployment) serialize() osbuild.Pipeline {
|
|||
},
|
||||
))
|
||||
|
||||
configStage := osbuild.NewOSTreeConfigStage(
|
||||
&osbuild.OSTreeConfigStageOptions{
|
||||
Repo: repoPath,
|
||||
Config: &osbuild.OSTreeConfig{
|
||||
Sysroot: &osbuild.SysrootOptions{
|
||||
ReadOnly: common.BoolToPtr(true),
|
||||
Bootloader: "none",
|
||||
},
|
||||
},
|
||||
},
|
||||
)
|
||||
configStage.MountOSTree(p.osName, p.osTreeRef, 0)
|
||||
pipeline.AddStage(configStage)
|
||||
|
||||
fstabOptions := osbuild.NewFSTabStageOptions(p.PartitionTable)
|
||||
fstabStage := osbuild.NewFSTabStage(fstabOptions)
|
||||
fstabStage.MountOSTree(p.osName, p.osTreeRef, 0)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue