require "ipaddr"
require "yaml"
+include_recipe "ruby"
+
keys = data_bag_item("networking", "keys")
file "/etc/netplan/00-installer-config.yaml" do
end
end
+# Setup dokken network in systemd-networkd to avoid systemd-networkd-wait-online delay
+template "/etc/systemd/network/dokken.network" do
+ source "dokken.network.erb"
+ owner "root"
+ group "root"
+ mode "644"
+ notifies :run, "execute[networkctl-reload]", :immediately
+ only_if { kitchen? }
+end
+
notify_group "networkctl-reload"
execute "networkctl-reload" do
to "../run/systemd/resolve/stub-resolv.conf"
end
+gem_package "dbus-systemd" do
+ gem_binary node[:ruby][:gem]
+end
+
+prometheus_exporter "resolved" do
+ port 10028
+ user "systemd-resolve"
+ restrict_address_families "AF_UNIX"
+end
+
hosts = { :inet => [], :inet6 => [] }
search(:node, "networking:interfaces").collect do |n|