summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLars Wirzenius <liw@liw.fi>2022-08-06 21:59:02 +0300
committerLars Wirzenius <liw@liw.fi>2022-08-06 21:59:02 +0300
commit7991928535005ed4c1fbdcd94dece5b0074537a6 (patch)
tree6ab164138ba9bcf43aa62d9047586b88a44a1587
parent221c80c5e22bbc8bf2532e6840d0dc2f9b19d8d5 (diff)
downloadv-i-7991928535005ed4c1fbdcd94dece5b0074537a6.tar.gz
perf: make installer image boot faster by using system-networkd
For some reason, ifupdown was taking over half a minute longer to boot. Sponsored-by: author
-rw-r--r--installer-ansible.yml20
1 files changed, 20 insertions, 0 deletions
diff --git a/installer-ansible.yml b/installer-ansible.yml
index a53d998..5e56d32 100644
--- a/installer-ansible.yml
+++ b/installer-ansible.yml
@@ -27,6 +27,26 @@
regexp: Storage=
line: Storage=volatile
+ - name: "drop ifupdown interfaces file"
+ file:
+ path: /etc/network/interfaces
+ state: absent
+
+ - name: "enable systemd-networkd"
+ systemd:
+ name: systemd-networkd
+ enabled: true
+
+ - name: "add eth0.network"
+ copy:
+ content: |
+ [Match]
+ Name=eth0
+
+ [Network]
+ DHCP=ipv4
+ dest: /etc/systemd/network/eth0.network
+
- name: "create /root/.ssh"
file:
state: directory