ansible-install-server/roles/fai/tasks/fai-ipxe.yml

38 lines
720 B
YAML

---
- name: "Install package ipxe"
become: true
ansible.builtin.package:
name: ipxe
state: present
tags:
- ipxe
- ipxe_install
- name: "Copy iPXE binaries to '{{ tftp_dir }}'"
become: true
ansible.builtin.copy:
src: "{{ item }}"
dest: "{{ tftp_dir }}"
remote_src: true
with_items:
- "/usr/lib/ipxe/ipxe.efi"
- "/usr/lib/ipxe/ipxe.pxe"
- "/usr/lib/ipxe/ipxe.lkrn"
notify: restart tftpd
tags:
- ipxe
- ipxe_copy
- name: "Write ipxe menu"
become: true
ansible.builtin.template:
src: "menu.ipxe.j2"
dest: "{{ tftp_dir }}/menu.ipxe"
mode: '0644'
owner: root
group: root
notify: restart tftpd
tags:
- ipxe
- ipxe_menu_write