summaryrefslogtreecommitdiff
path: root/roles/installer/ubuntu
diff options
context:
space:
mode:
authorChristian Pointner <equinox@spreadspace.org>2024-05-28 23:24:15 +0200
committerChristian Pointner <equinox@spreadspace.org>2024-05-28 23:24:15 +0200
commit7d92af47eda7be65b307a285e7ef4a25d53158d9 (patch)
tree78f2e78a934fcac32d715058fa2b3ff892772d60 /roles/installer/ubuntu
parentmove ch-cm4-sensors* to iot vlan (diff)
ch-cm4-sensor: make install in iot possible
Diffstat (limited to 'roles/installer/ubuntu')
-rw-r--r--roles/installer/ubuntu/autoinstall/templates/autoinstall.yml.j210
1 files changed, 8 insertions, 2 deletions
diff --git a/roles/installer/ubuntu/autoinstall/templates/autoinstall.yml.j2 b/roles/installer/ubuntu/autoinstall/templates/autoinstall.yml.j2
index 9911f654..af349e5c 100644
--- a/roles/installer/ubuntu/autoinstall/templates/autoinstall.yml.j2
+++ b/roles/installer/ubuntu/autoinstall/templates/autoinstall.yml.j2
@@ -19,10 +19,16 @@ autoinstall:
{% else %}
addresses:
- {{ network.primary.address }}
- gateway4: {{ network.primary.gateway }}
+{% if 'gateway' in network %}
+ routes:
+ - to: default
+ via: {{ network.primary.gateway }}
+{% endif %}
{% if (network.nameservers | default([]) | length) > 0 %}
nameservers:
- search: [ {{ host_domain }} ]
+{% if 'domain' in network %}
+ search: [ {{ network.domain }} ]
+{% endif %}
addresses: [ {{ network.nameservers | join(', ') }} ]
{% endif %}
{% endif %}