diff options
Diffstat (limited to 'roles/bootstrap')
| -rw-r--r-- | roles/bootstrap/tasks/install-archlinux-mac.yml | 24 | ||||
| -rw-r--r-- | roles/bootstrap/tasks/install-ubuntu-mac.yml | 24 | ||||
| -rw-r--r-- | roles/bootstrap/tasks/install-ubuntu.yml | 5 |
3 files changed, 49 insertions, 4 deletions
diff --git a/roles/bootstrap/tasks/install-archlinux-mac.yml b/roles/bootstrap/tasks/install-archlinux-mac.yml index 26ae9ee..9184207 100644 --- a/roles/bootstrap/tasks/install-archlinux-mac.yml +++ b/roles/bootstrap/tasks/install-archlinux-mac.yml @@ -1,4 +1,28 @@ --- +- name: "Ensure EFI/refind directory exists for Mac NVRAM compatibility" + ansible.builtin.file: + path: "{{ mnt_boot_path }}/EFI/refind" + state: directory + mode: "0755" + # Mac NVRAM entries persist across disk wipes (stored in firmware) and point to EFI/refind/ + # refind-install --usedefault only creates EFI/BOOT/ so we must create this explicitly + tags: ["molecule-notest"] + +- name: "Copy rEFInd binary to EFI/refind for Mac NVRAM entries" + ansible.builtin.copy: + src: "{{ mnt_boot_path }}/EFI/BOOT/bootx64.efi" + dest: "{{ mnt_boot_path }}/EFI/refind/refind_x64.efi" + remote_src: true + mode: "0644" + tags: ["molecule-notest"] + +- name: "Configure rEFInd base settings in EFI/refind for Mac NVRAM entries" + ansible.builtin.template: + src: "refind.conf.j2" + dest: "{{ mnt_boot_path }}/EFI/refind/refind.conf" + mode: "0644" + tags: ["molecule-notest"] + - name: "Install broadcom-wl driver" ansible.builtin.command: cmd: "arch-chroot {{ mnt_root_path }} pacman -S --noconfirm broadcom-wl" diff --git a/roles/bootstrap/tasks/install-ubuntu-mac.yml b/roles/bootstrap/tasks/install-ubuntu-mac.yml index 23ead61..69b9a88 100644 --- a/roles/bootstrap/tasks/install-ubuntu-mac.yml +++ b/roles/bootstrap/tasks/install-ubuntu-mac.yml @@ -1,4 +1,28 @@ --- +- name: "Ensure EFI/refind directory exists for Mac NVRAM compatibility" + ansible.builtin.file: + path: "{{ mnt_boot_path }}/EFI/refind" + state: directory + mode: "0755" + # Mac NVRAM entries persist across disk wipes (stored in firmware) and point to EFI/refind/ + # refind-install --usedefault only creates EFI/BOOT/ so we must create this explicitly + tags: ["molecule-notest"] + +- name: "Copy rEFInd binary to EFI/refind for Mac NVRAM entries" + ansible.builtin.copy: + src: "{{ mnt_boot_path }}/EFI/BOOT/bootx64.efi" + dest: "{{ mnt_boot_path }}/EFI/refind/refind_x64.efi" + remote_src: true + mode: "0644" + tags: ["molecule-notest"] + +- name: "Configure rEFInd base settings in EFI/refind for Mac NVRAM entries" + ansible.builtin.template: + src: "refind.conf.j2" + dest: "{{ mnt_boot_path }}/EFI/refind/refind.conf" + mode: "0644" + tags: ["molecule-notest"] + - name: "Install broadcom-sta-dkms in chroot" ansible.builtin.command: cmd: "arch-chroot {{ mnt_root_path }} apt-get install -y broadcom-sta-dkms" diff --git a/roles/bootstrap/tasks/install-ubuntu.yml b/roles/bootstrap/tasks/install-ubuntu.yml index 9d32543..89f351f 100644 --- a/roles/bootstrap/tasks/install-ubuntu.yml +++ b/roles/bootstrap/tasks/install-ubuntu.yml @@ -75,11 +75,8 @@ - name: "Configure rEFInd base settings" ansible.builtin.template: src: "refind.conf.j2" - dest: "{{ item }}" + dest: "{{ mnt_boot_path }}/EFI/BOOT/refind.conf" mode: "0644" - loop: - - "{{ mnt_boot_path }}/EFI/BOOT/refind.conf" - - "{{ mnt_boot_path }}/EFI/refind/refind.conf" # NOTE: this is skipped because the docker test doesn't have proper EFI/BOOT directory created tags: ["molecule-notest"] |
