Skip to content

Commit

Permalink
Clean NetworkManager and resolv.conf config in prepare4image.sh
Browse files Browse the repository at this point in the history
This avoids cluttering resolv.conf with nameservers that would
not exist in another cluster.
  • Loading branch information
cmd-ntrf committed Aug 27, 2024
1 parent e702cbe commit 1ba3a12
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions site/profile/files/base/prepare4image.sh
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,10 @@ rm -f /etc/hostname
rm -f /etc/udev/rules.d/70-persistent-net.rules
: > /etc/sysconfig/network
: > /etc/machine-id

rm /etc/NetworkManager/conf.d/zzz-puppet.conf
: > /etc/resolv.conf

cat > /etc/sysconfig/network-scripts/ifcfg-eth0 << EOF
DEVICE=eth0
TYPE=Ethernet
Expand Down

0 comments on commit 1ba3a12

Please sign in to comment.