Skip to content

Commit 3d1b96c

Browse files
committed
Add hook to automate removal of --root-dev-only
1 parent 0bbceb0 commit 3d1b96c

File tree

3 files changed

+18
-1
lines changed

3 files changed

+18
-1
lines changed

doc/source/operations/upgrading-openstack.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,8 @@ Known issues
145145
<https://access.redhat.com/security/cve/CVE-2023-4001>`__, the operating
146146
system can become unbootable (boot will stop at a ``grub>`` prompt). Remove
147147
the ``--root-dev-only`` option from ``/boot/efi/EFI/rocky/grub.cfg`` after
148-
applying package updates.
148+
applying package updates. This will happen automatically as a post hook when
149+
running the ``kayobe overcloud host package update`` command.
149150

150151
Security baseline
151152
=================

etc/kayobe/ansible/fix-grub-rl9.yml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
---
2+
- name: Remove "--root-dev-only" from grub.cfg if OS is Rocky Linux 9
3+
hosts: overcloud
4+
become: yes
5+
gather_facts: true
6+
7+
tasks:
8+
- name: Remove "--root-dev-only" from /boot/efi/EFI/rocky/grub.cfg
9+
ansible.builtin.replace:
10+
path: /boot/efi/EFI/rocky/grub.cfg
11+
regexp: '--root-dev-only\s?'
12+
replace: ''
13+
when:
14+
- ansible_facts['distribution'] == 'Rocky'
15+
- ansible_facts['distribution_major_version'] == '9'
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../../../ansible/fix-grub-rl9.yml

0 commit comments

Comments
 (0)