grub: add oem_id variable to kernel parameters

This commit is contained in:
Alex Crawford 2015-10-20 14:47:16 -07:00
parent 6ee030b4f5
commit f7bcd4f547

View File

@ -15,6 +15,7 @@ set timeout=1
set linux_root="root=LABEL=ROOT"
set linux_console=""
set first_boot=""
set oem_id=""
# Anything else the OEM adds should use this variable.
set linux_append=""
@ -44,6 +45,10 @@ if [ -n "$first_boot" ]; then
set first_boot="coreos.first_boot=1"
fi
if [ -n "$oem_id" ]; then
set oem_id="coreos.oem.id=$oem_id"
fi
# If no specific console has been set by the OEM then select based on
# platform, most systems use vga text as primary and ttyS0 as secondary.
if [ -z "$linux_console" ]; then
@ -71,7 +76,7 @@ else
fi
# Assemble the options applicable to all the kernels below
set linux_cmdline="rootflags=rw mount.usrflags=ro $linux_root $linux_console $first_boot $linux_append"
set linux_cmdline="rootflags=rw mount.usrflags=ro $linux_root $linux_console $first_boot $oem_id $linux_append"
menuentry "CoreOS default" --id=coreos {
gptprio.next -d usr -u usr_uuid