]> git.openstreetmap.org Git - chef.git/blobdiff - cookbooks/networking/recipes/default.rb
Don't create ethernet devices for bond interfaces with vlans
[chef.git] / cookbooks / networking / recipes / default.rb
index 068e0edf23496052bbb5085f1b323cf005c42d06..04c1c6258d6ab9e63f1fba3184534152f8099646 100644 (file)
@@ -123,7 +123,9 @@ if node[:networking][:netplan]
   end
 
   netplan["network"]["vlans"].each_value do |vlan|
   end
 
   netplan["network"]["vlans"].each_value do |vlan|
-    netplan["network"]["ethernets"][vlan["link"]] ||= { "accept-ra" => false }
+    unless vlan["link"] =~ /^bond\d+$/
+      netplan["network"]["ethernets"][vlan["link"]] ||= { "accept-ra" => false }
+    end
   end
 
   file "/etc/netplan/99-chef.yaml" do
   end
 
   file "/etc/netplan/99-chef.yaml" do