Merge "Copy generated /boot/grub2/grubenv to EFI dirs"
This commit is contained in:
commit
602039ef1d
|
@ -53,12 +53,23 @@
|
|||
path: "{{ item }}"
|
||||
register: grub_stat
|
||||
loop:
|
||||
- /boot/grub2/grub.cfg
|
||||
- /boot/efi/EFI/redhat/grub.cfg
|
||||
- /boot/efi/EFI/centos/grub.cfg
|
||||
- /boot/efi/EFI/fedora/grub.cfg
|
||||
- /boot/efi/EFI/BOOT
|
||||
- /boot/efi/EFI/redhat
|
||||
- /boot/efi/EFI/centos
|
||||
- /boot/efi/EFI/fedora
|
||||
- name: Generate grub config
|
||||
command: "grub2-mkconfig -o {{ item.stat.path }}"
|
||||
command: "grub2-mkconfig -o /boot/grub2/grub.cfg"
|
||||
|
||||
- name: Generate EFI grub config
|
||||
command: "grub2-mkconfig -o {{ item.stat.path }}/grub.cfg"
|
||||
when: item.stat.exists|bool
|
||||
loop: "{{ grub_stat.results }}"
|
||||
|
||||
- name: Copy grubenv to EFI directory
|
||||
copy:
|
||||
remote_src: true
|
||||
src: /boot/grub2/grubenv
|
||||
dest: "{{ item.stat.path }}/grubenv"
|
||||
when: item.stat.exists|bool
|
||||
loop: "{{ grub_stat.results }}"
|
||||
- name: Set reboot required fact
|
||||
|
|
Loading…
Reference in New Issue