41 lines
1,005 B
YAML
41 lines
1,005 B
YAML
- name: add stretch-backports
|
|
apt_repository:
|
|
repo: deb http://deb.debian.org/debian/ stretch-backports main
|
|
state: present
|
|
|
|
- name: install di-netboot-assistant from backports
|
|
apt:
|
|
name:
|
|
- di-netboot-assistant
|
|
default_release: stretch-backports
|
|
update_cache: yes
|
|
|
|
- name: add installer package
|
|
apt:
|
|
name:
|
|
- debian-installer-9-netboot-amd64
|
|
|
|
- name: bind mount images
|
|
mount:
|
|
path: "{{ tftp_root }}/d-i/n-pkg/"
|
|
src: /usr/lib/debian-installer/
|
|
fstype: none
|
|
opts: bind
|
|
# state: mounted BEGINN WORKAROUND
|
|
state: present
|
|
register: fstab
|
|
|
|
- file: path="{{ tftp_root }}/d-i/n-pkg/" state=directory recurse=yes
|
|
|
|
- name: Reload fstab
|
|
command: mount -a
|
|
when: fstab.changed
|
|
# https://github.com/ansible/ansible/issues/23487 END WORKAROUND
|
|
|
|
- name: configure dnsmasq
|
|
template:
|
|
src: dnsmasq-tftp-netboot-installer.j2
|
|
dest: /etc/dnsmasq.d/tftp-netboot-installer
|
|
notify:
|
|
- restart dnsmasq
|
|
- rebuild di-netboot-assistant menu
|