Skip to content

Commit

Permalink
fedora: fix default kernel command line
Browse files Browse the repository at this point in the history
Fix the default Fedora kernel command line. It was advertised as the
default but the reality is the options were for cloud, so set a real
default as the option and update the cloud options to something
special for them. It's not truly correct as at least one of the
options is x86 specific but when booted on other architectures those
kernels will ignore it (and I honestly think it's ancient cargo
culted kernel command line options).

Signed-off-by: Peter Robinson <[email protected]>
  • Loading branch information
nullr0ute authored and thozza committed Sep 13, 2023
1 parent e06ea82 commit 3d36490
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions pkg/distro/fedora/distro.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,11 @@ const (
// blueprint package set name
blueprintPkgsKey = "blueprint"

//Kernel options for ami, qcow2, openstack, vhd and vmdk types
defaultKernelOptions = "ro no_timer_check console=ttyS0,115200n8 biosdevname=0 net.ifnames=0"
//Default kernel command line
defaultKernelOptions = "ro"

// Added kernel command line options for ami, qcow2, openstack, vhd and vmdk types
cloudKernelOptions = "ro no_timer_check console=ttyS0,115200n8 biosdevname=0 net.ifnames=0"
)

var (
Expand Down Expand Up @@ -237,7 +240,7 @@ var (
"cloud-init-local.service",
},
},
kernelOptions: defaultKernelOptions,
kernelOptions: cloudKernelOptions,
bootable: true,
defaultSize: 5 * common.GibiByte,
image: diskImage,
Expand Down Expand Up @@ -265,7 +268,7 @@ var (
osPkgsKey: vmdkCommonPackageSet,
},
defaultImageConfig: vmdkDefaultImageConfig,
kernelOptions: defaultKernelOptions,
kernelOptions: cloudKernelOptions,
bootable: true,
defaultSize: 2 * common.GibiByte,
image: diskImage,
Expand All @@ -283,7 +286,7 @@ var (
osPkgsKey: vmdkCommonPackageSet,
},
defaultImageConfig: vmdkDefaultImageConfig,
kernelOptions: defaultKernelOptions,
kernelOptions: cloudKernelOptions,
bootable: true,
defaultSize: 2 * common.GibiByte,
image: diskImage,
Expand Down

0 comments on commit 3d36490

Please sign in to comment.