From dd28dcf3d620a4ac7d0a1532b812213cf094cd3c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Hugo=20H=C3=B6rnquist?= Date: Wed, 12 Jan 2022 02:26:25 +0100 Subject: Revert "Move webdav into profiles." It actually reverts the non-need for the nginx module webdav_ext. Since Omnifocus requires PROPFIND. This reverts commit edf6ffe8b399679ba28cc5e558a6838919dd1ee8. --- .../nspawn/manifests/util/disable_networking.pp | 22 ------------- modules/nspawn/manifests/util/enable_networkd.pp | 38 ---------------------- 2 files changed, 60 deletions(-) delete mode 100644 modules/nspawn/manifests/util/disable_networking.pp delete mode 100644 modules/nspawn/manifests/util/enable_networkd.pp (limited to 'modules/nspawn/manifests/util') diff --git a/modules/nspawn/manifests/util/disable_networking.pp b/modules/nspawn/manifests/util/disable_networking.pp deleted file mode 100644 index 4a9b31b..0000000 --- a/modules/nspawn/manifests/util/disable_networking.pp +++ /dev/null @@ -1,22 +0,0 @@ -define nspawn::util::disable_networking ( - String $machine = $name, - String $machine_path = "/var/lib/machines/${machine}", -) { - - - $cmd = if $facts['machined-info'][$machine]['State'] == 'running' { - [ 'systemctl', '-M', $machine, 'disable', 'networking' ] - } else { - [ 'systemd-nspawn', '-M', $machine, '--quiet', - 'systemctl', 'disable', 'networking' ] - } - - exec { "Disable networking on ${machine}": - command => $cmd, - path => [ '/bin', '/usr/bin', ], - # among others - # creates => "${machine_path}/etc/systemd/system/multi-user.target.wants/systemd-networkd.service", - } - -} - diff --git a/modules/nspawn/manifests/util/enable_networkd.pp b/modules/nspawn/manifests/util/enable_networkd.pp deleted file mode 100644 index 8e447b9..0000000 --- a/modules/nspawn/manifests/util/enable_networkd.pp +++ /dev/null @@ -1,38 +0,0 @@ -define nspawn::util::enable_networkd ( - String $machine = $name, - String $machine_path = "/var/lib/machines/${machine}", -) { - - # TODO only do this if the directory is empty - networking::networkd_instance { "Initial networking on ${machine}": - priority => 50, - filename => 'puppet-initial', - path => "${machine_path}/${networking::networkd::path}", - content => { - 'Match' => { - 'Name' => 'host0', - }, - 'Network' => { - 'DHCP' => 'ipv4', - 'IPv6AcceptRA' => 1, - }, - }, - } - - $running = $facts['machined-info'][$machine] != Undef or $facts['machined-info'][$machine]['State'] == 'running' - - $cmd = if $running { - [ 'systemctl', '-M', $machine, 'enable', 'systemd-networkd' ] - } else { - [ 'systemd-nspawn', '-M', $machine, '--quiet', - 'systemctl', 'enable', 'systemd-networkd' ] - } - - exec { "Enable systemd-networkd on ${machine}": - command => $cmd, - path => [ '/bin', '/usr/bin', ], - # among others - creates => "${machine_path}/etc/systemd/system/multi-user.target.wants/systemd-networkd.service", - } - -} -- cgit v1.2.3