diff options
author | Lars Wirzenius <liw@liw.fi> | 2022-01-08 16:17:35 +0200 |
---|---|---|
committer | Lars Wirzenius <liw@liw.fi> | 2022-01-08 16:17:35 +0200 |
commit | f8e3f4a638b27cb025672dfa129e44ff3278b1a1 (patch) | |
tree | fc8629ff0f763a470c8aed058891426c7b910b0f /std.yml | |
parent | 889f540f80e96f196d610bb469384d4d2144ca61 (diff) | |
download | v-i-f8e3f4a638b27cb025672dfa129e44ff3278b1a1.tar.gz |
use systemd-networkd to get network access, instead of ifupdown
Sponsored-by: author
Diffstat (limited to 'std.yml')
-rw-r--r-- | std.yml | 25 |
1 files changed, 23 insertions, 2 deletions
@@ -8,9 +8,10 @@ {{ hostname }} dest: /etc/hostname - - name: "disable root password" + - name: "remove root password" shell: | - passwd -l root + # passwd -l root + sed -i '/^root:[^:]*:/root::/' /etc/passwd - name: "create ~root/.ssh" file: @@ -70,6 +71,26 @@ # regex: "#* *PasswordAuthentication" # line: "PasswordAuthentication no" + - name: "configure networkd" + copy: + content: | + [Match] + Name=eth0 + + [Network] + DHCP=ipv4 + dest: /etc/systemd/network/lan0.network + + - name: "remove ifupdown" + apt: + name: ifupdown + state: absent + + - name: "enable networkd" + systemd: + name: systemd-networkd + enabled: yes + vars: hostname: v-i user_pub: | |