manifest: add support for waagent and udevrules to liveImage
Extend the OSCustomizations to include the WAAgentConfig and UdevRules options. Propagate those options from the image's config down to the OSCustomizations and add the stages to the os pipeline when they're specified.
This commit is contained in:
parent
f3e43a01bc
commit
db88c734c1
2 changed files with 12 additions and 0 deletions
|
|
@ -134,6 +134,8 @@ func osCustomizations(
|
|||
osc.PwQuality = imageConfig.PwQuality
|
||||
osc.RHSMConfig = imageConfig.RHSMConfig
|
||||
osc.Subscription = options.Subscription
|
||||
osc.WAAgentConfig = imageConfig.WAAgentConfig
|
||||
osc.UdevRules = imageConfig.UdevRules
|
||||
|
||||
return osc
|
||||
}
|
||||
|
|
|
|||
|
|
@ -83,6 +83,8 @@ type OSCustomizations struct {
|
|||
PwQuality *osbuild.PwqualityConfStageOptions
|
||||
OpenSCAPConfig *osbuild.OscapRemediationStageOptions
|
||||
NTPServers []osbuild.ChronyConfigServer
|
||||
WAAgentConfig *osbuild.WAAgentConfStageOptions
|
||||
UdevRules *osbuild.UdevRulesStageOptions
|
||||
LeapSecTZ *string
|
||||
|
||||
Subscription *distro.SubscriptionImageOptions
|
||||
|
|
@ -428,6 +430,14 @@ func (p *OS) serialize() osbuild.Pipeline {
|
|||
}
|
||||
}
|
||||
|
||||
if waConfig := p.WAAgentConfig; waConfig != nil {
|
||||
pipeline.AddStage(osbuild.NewWAAgentConfStage(waConfig))
|
||||
}
|
||||
|
||||
if udevRules := p.UdevRules; udevRules != nil {
|
||||
pipeline.AddStage(osbuild.NewUdevRulesStage(udevRules))
|
||||
}
|
||||
|
||||
if pt := p.PartitionTable; pt != nil {
|
||||
kernelOptions := osbuild.GenImageKernelOptions(p.PartitionTable)
|
||||
kernelOptions = append(kernelOptions, p.KernelOptionsAppend...)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue