Skip to content

Commit

Permalink
Fix ipv6 activation in cloud-init
Browse files Browse the repository at this point in the history
  • Loading branch information
cmd-ntrf committed Jan 9, 2024
1 parent 69c6ce8 commit 7ea5d41
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions common/configuration/puppet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,11 @@ runcmd:
# Remove all ifcfg configuration files that have no corresponding network interface in ip link show.
# Activate IPV6 config for existing links
- for i in /etc/sysconfig/network-scripts/ifcfg-*; do
if ! ip link show | grep -q "$${i##*-}:"; then
rm -f $i;
else
sed -i 's/^IPV6INIT=no$/IPV6INIT=yes/' $i
if ! ip link show | grep -q "$${i##*-}:"; then rm -f $i;
else sed -i 's/^IPV6INIT=.*$/IPV6INIT=yes/' $i;
fi;
done
- systemctl NetworkManager restart
- systemctl restart NetworkManager
# Install package and configure kernel only if building from a "vanilla" linux image
- |
if ! test -f /etc/magic-castle-release; then
Expand Down

0 comments on commit 7ea5d41

Please sign in to comment.