2016-06-04 19:54:39 +02:00
|
|
|
from bootstrapvz.base import Task
|
|
|
|
from bootstrapvz.common import phases
|
|
|
|
from bootstrapvz.common.tasks import grub
|
|
|
|
|
|
|
|
|
|
|
|
class AddVirtualConsoleGrubOutputDevice(Task):
|
|
|
|
description = 'Adding `tty0\' as output device for grub'
|
|
|
|
phase = phases.system_modification
|
2018-01-20 15:08:33 +01:00
|
|
|
predecessors = [grub.SetGrubConsolOutputDeviceToSerial]
|
2016-06-04 19:54:39 +02:00
|
|
|
successors = [grub.WriteGrubConfig]
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
def run(cls, info):
|
2019-11-04 03:08:27 +01:00
|
|
|
info.grub_config['GRUB_CMDLINE_LINUX'].extend([
|
|
|
|
'console=tty0',
|
|
|
|
'consoleblank=0',
|
|
|
|
'elevator=noop',
|
2019-11-04 03:13:25 +01:00
|
|
|
'noibrs',
|
|
|
|
'noibpb',
|
|
|
|
'nopti',
|
|
|
|
'nospectre_v2',
|
|
|
|
'nospectre_v1',
|
|
|
|
'l1tf=off',
|
|
|
|
'nospec_store_bypass_disable',
|
|
|
|
'no_stf_barrier',
|
|
|
|
'mds=off',
|
|
|
|
'mitigations=off',
|
2019-11-04 03:08:27 +01:00
|
|
|
])
|