diff options
Diffstat (limited to 'roles')
8 files changed, 23 insertions, 11 deletions
diff --git a/roles/preseed/tasks/main.yml b/roles/preseed/tasks/main.yml index d8898460..8e00fb82 100644 --- a/roles/preseed/tasks/main.yml +++ b/roles/preseed/tasks/main.yml @@ -1,3 +1,4 @@ +--- - name: Copy initramfs into position copy: remote_src: yes diff --git a/roles/preseed/templates/preseed_debian-buster.cfg.j2 b/roles/preseed/templates/preseed_debian-buster.cfg.j2 index 91cd687a..7dbeb680 100644 --- a/roles/preseed/templates/preseed_debian-buster.cfg.j2 +++ b/roles/preseed/templates/preseed_debian-buster.cfg.j2 @@ -31,7 +31,7 @@ d-i netcfg/wireless_wep string d-i mirror/country string manual -d-i mirror/http/hostname string deb.debian.org +d-i mirror/http/hostname string {{ apt_repo_providers[(hostvars[hostname].apt_repo_provider | default('default'))].debian }} d-i mirror/http/directory string /debian d-i mirror/http/proxy string @@ -116,7 +116,7 @@ d-i partman/confirm_nooverwrite boolean true d-i base-installer/install-recommends boolean false -d-i apt-setup/security_host string deb.debian.org +d-i apt-setup/security_host string {{ apt_repo_providers[(hostvars[hostname].apt_repo_provider | default('default'))].debian }} tasksel tasksel/first multiselect d-i pkgsel/include string openssh-server python3 python3-apt diff --git a/roles/preseed/templates/preseed_debian-stretch.cfg.j2 b/roles/preseed/templates/preseed_debian-stretch.cfg.j2 index a5bef09e..d99a7626 100644 --- a/roles/preseed/templates/preseed_debian-stretch.cfg.j2 +++ b/roles/preseed/templates/preseed_debian-stretch.cfg.j2 @@ -31,7 +31,7 @@ d-i netcfg/wireless_wep string d-i mirror/country string manual -d-i mirror/http/hostname string deb.debian.org +d-i mirror/http/hostname string {{ apt_repo_providers[(hostvars[hostname].apt_repo_provider | default('default'))].debian }} d-i mirror/http/directory string /debian d-i mirror/http/proxy string @@ -116,7 +116,7 @@ d-i partman/confirm_nooverwrite boolean true d-i base-installer/install-recommends boolean false -d-i apt-setup/security_host string deb.debian.org +d-i apt-setup/security_host string {{ apt_repo_providers[(hostvars[hostname].apt_repo_provider | default('default'))].debian }} tasksel tasksel/first multiselect d-i pkgsel/include string openssh-server python python-apt diff --git a/roles/preseed/templates/preseed_ubuntu-bionic.cfg.j2 b/roles/preseed/templates/preseed_ubuntu-bionic.cfg.j2 index d2188392..9d0b13ee 100644 --- a/roles/preseed/templates/preseed_ubuntu-bionic.cfg.j2 +++ b/roles/preseed/templates/preseed_ubuntu-bionic.cfg.j2 @@ -35,7 +35,7 @@ d-i netcfg/wireless_wep string d-i mirror/country string manual -d-i mirror/http/hostname string archive.ubuntu.com +d-i mirror/http/hostname string {{ apt_repo_providers[(hostvars[hostname].apt_repo_provider | default('default'))].ubuntu }} d-i mirror/http/directory string /ubuntu d-i mirror/http/proxy string @@ -121,7 +121,7 @@ d-i partman/confirm_nooverwrite boolean true d-i base-installer/install-recommends boolean false -d-i apt-setup/security_host string archive.ubuntu.com +d-i apt-setup/security_host string {{ apt_repo_providers[(hostvars[hostname].apt_repo_provider | default('default'))].ubuntu }} tasksel tasksel/first multiselect d-i pkgsel/include string openssh-server python python-apt diff --git a/roles/preseed/templates/preseed_ubuntu-xenial.cfg.j2 b/roles/preseed/templates/preseed_ubuntu-xenial.cfg.j2 index e49a3886..9e18c2ee 100644 --- a/roles/preseed/templates/preseed_ubuntu-xenial.cfg.j2 +++ b/roles/preseed/templates/preseed_ubuntu-xenial.cfg.j2 @@ -35,7 +35,7 @@ d-i netcfg/wireless_wep string d-i mirror/country string manual -d-i mirror/http/hostname string archive.ubuntu.com +d-i mirror/http/hostname string {{ apt_repo_providers[(hostvars[hostname].apt_repo_provider | default('default'))].ubuntu }} d-i mirror/http/directory string /ubuntu d-i mirror/http/proxy string @@ -121,7 +121,7 @@ d-i partman/confirm_nooverwrite boolean true d-i base-installer/install-recommends boolean false -d-i apt-setup/security_host string archive.ubuntu.com +d-i apt-setup/security_host string {{ apt_repo_providers[(hostvars[hostname].apt_repo_provider | default('default'))].ubuntu }} tasksel tasksel/first multiselect d-i pkgsel/include string openssh-server python python-apt diff --git a/roles/preseed/templates/preseed_xubuntu-cosmic-desktop-with-raid.cfg.j2 b/roles/preseed/templates/preseed_xubuntu-cosmic-desktop-with-raid.cfg.j2 index cc4c4714..13c30e93 100644 --- a/roles/preseed/templates/preseed_xubuntu-cosmic-desktop-with-raid.cfg.j2 +++ b/roles/preseed/templates/preseed_xubuntu-cosmic-desktop-with-raid.cfg.j2 @@ -33,7 +33,7 @@ d-i netcfg/wireless_wep string d-i mirror/country string manual -d-i mirror/http/hostname string debian.ffgraz.net +d-i mirror/http/hostname string {{ apt_repo_providers[(hostvars[hostname].apt_repo_provider | default('default'))].ubuntu }} d-i mirror/http/directory string /ubuntu d-i mirror/http/proxy string @@ -118,7 +118,7 @@ d-i partman/confirm_nooverwrite boolean true d-i base-installer/install-recommends boolean false -d-i apt-setup/security_host string debian.ffgraz.net +d-i apt-setup/security_host string {{ apt_repo_providers[(hostvars[hostname].apt_repo_provider | default('default'))].ubuntu }} tasksel tasksel/first multiselect xubuntu-desktop d-i pkgsel/include string openssh-server python python-apt diff --git a/roles/vm/network/templates/interfaces.j2 b/roles/vm/network/templates/interfaces.j2 index 829a3e7d..d59d53e1 100644 --- a/roles/vm/network/templates/interfaces.j2 +++ b/roles/vm/network/templates/interfaces.j2 @@ -15,3 +15,9 @@ iface {{ network.primary.interface }} inet static gateway {{ network.primary.gateway }} pre-up echo 0 > /proc/sys/net/ipv6/conf/$IFACE/accept_ra pre-up echo 0 > /proc/sys/net/ipv6/conf/$IFACE/autoconf +{% if 'prefix6' in network.primary %} + +iface {{ network.primary.interface }} inet6 static + address {{ network.primary.prefix6 }} + gateway {{ network.primary.gateway6 }} +{% endif %} diff --git a/roles/vm/network/templates/netplan.yaml.j2 b/roles/vm/network/templates/netplan.yaml.j2 index 0d78ab46..7725f15f 100644 --- a/roles/vm/network/templates/netplan.yaml.j2 +++ b/roles/vm/network/templates/netplan.yaml.j2 @@ -5,6 +5,11 @@ network: renderer: networkd ethernets: {{ network.primary.interface }}: - addresses: [ {{ (network.primary.ip + '/' + network.primary.mask) | ipaddr('address/prefix') }} ] + addresses: + - {{ (network.primary.ip + '/' + network.primary.mask) | ipaddr('address/prefix') }} +{% if 'prefix6' in network.primary %} + - {{ network.primary.prefix6 }} + gateway6: {{ network.primary.gateway6 }} +{% endif %} gateway4: {{ network.primary.gateway }} accept-ra: false |