diff options
Diffstat (limited to 'roles/installer/debian/usb/tasks')
-rw-r--r-- | roles/installer/debian/usb/tasks/main.yml | 48 |
1 files changed, 24 insertions, 24 deletions
diff --git a/roles/installer/debian/usb/tasks/main.yml b/roles/installer/debian/usb/tasks/main.yml index 6220b02b..7e603ed6 100644 --- a/roles/installer/debian/usb/tasks/main.yml +++ b/roles/installer/debian/usb/tasks/main.yml @@ -11,49 +11,49 @@ that: usb_install_mountpoint.stat.exists msg: the path to the usb drive does not exist -- block: - - name: download installer - vars: - debian_installer_distro: "{{ install_distro }}" - debian_installer_codename: "{{ install_codename }}" - debian_installer_arch: "{{ install.arch | default('amd64') }}" - debian_installer_variant: netboot - run_once: true - import_role: - role: installer/debian/fetch +- name: download installer + vars: + debian_installer_distro: "{{ install_distro }}" + debian_installer_codename: "{{ install_codename }}" + debian_installer_arch: "{{ install.arch | default('amd64') }}" + debian_installer_variant: netboot + run_once: true + import_role: + role: installer/debian/fetch - - name: Create temporary workdir +- block: + - name: create temporary workdir tempfile: prefix: "usb-install.{{ install_hostname }}." state: directory register: tmpdir - - name: generate pressed file + - name: copy the original initramfs to the usb drive + copy: + src: "{{ debian_installer_target_dir }}/initrd.gz" + dest: "{{ usb_install_path }}/initrd.{{ install_hostname }}.gz" + + - name: generate host specific initial ramdisk vars: - preseed_orig_initrd: "{{ installer_base_path }}/{{ install_distro }}-{{ install_codename }}/{{ hostvars[install_hostname].install_cooked.arch | default('amd64') }}-netboot/initrd.gz" + preseed_initrd: "{{ usb_install_path }}/initrd.{{ install_hostname }}.gz" preseed_tmpdir: "{{ tmpdir.path }}" import_role: name: installer/debian/preseed - - name: Copy the preseed initramfs to the usb drive - copy: - src: "{{ tmpdir.path }}/initrd.{{ install_hostname }}.gz" - dest: "{{ usb_install_path }}/initrd.{{ install_hostname }}.gz" - always: - - name: Cleanup temporary workdir + - name: cleanup temporary workdir when: tmpdir.path is defined file: path: "{{ tmpdir.path }}" state: absent -- name: Copy linux kernel image to the USB drive +- name: copy linux kernel image to the USB drive run_once: true copy: - src: "{{ global_cache_dir }}/debian-installer/{{ install_distro }}-{{ install_codename }}/{{ install.arch | default('amd64') }}-{{ debian_installer_variant }}/linux" + src: "{{ debian_installer_target_dir }}/linux" dest: "{{ usb_install_path }}/" -- name: Generate syslinux configuration for BIOS boot +- name: generate syslinux configuration for BIOS boot run_once: true vars: syslinux_base_path: "" @@ -67,7 +67,7 @@ path: "{{ usb_install_path }}/EFI/boot" state: directory -- name: Generate syslinux configuration for UEFI boot +- name: generate syslinux configuration for UEFI boot run_once: true vars: syslinux_base_path: "../../" @@ -75,7 +75,7 @@ src: syslinux.cfg.j2 dest: "{{ usb_install_path }}/EFI/boot/syslinux.cfg" -- name: Make the USB disk bootable +- name: make the USB disk bootable pause: seconds: 0 prompt: | |