diff options
author | nl6720 <nl6720@gmail.com> | 2023-11-07 13:45:21 +0200 |
---|---|---|
committer | nl6720 <nl6720@gmail.com> | 2023-11-07 13:45:21 +0200 |
commit | 81c556dd77f218e964ee83463e55d88a70752052 (patch) | |
tree | 64b0e6f48cd4e70685432004e90f7acc959d8445 | |
parent | d9805786ef1055654255d0f371d8194a06e8b0d3 (diff) |
Run DHCP client on predictable network interfaces
Make sure networking still works when someone removes the silly
`net.ifnames=0` kernel parameter from the boot loader configuration and
chooses to use predictable network interface names.
-rw-r--r-- | images/basic.sh | 1 | ||||
-rw-r--r-- | images/common.sh | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/images/basic.sh b/images/basic.sh index f97c286..d2a0934 100644 --- a/images/basic.sh +++ b/images/basic.sh @@ -14,6 +14,7 @@ function pre() { cat <<EOF >"${MOUNT}/etc/systemd/network/80-dhcp.network" [Match] +Name=en* Name=eth* [Network] diff --git a/images/common.sh b/images/common.sh index 36dc0d8..7a5ddcf 100644 --- a/images/common.sh +++ b/images/common.sh @@ -16,6 +16,7 @@ EOF # setup network cat <<EOF >"${MOUNT}/etc/systemd/network/80-dhcp.network" [Match] +Name=en* Name=eth* [Network] |