diff options
-rw-r--r-- | .gitmodules | 3 | ||||
-rw-r--r-- | manifests/site.pp | 5 | ||||
-rw-r--r-- | modules/ovh_cleanup/manifests/init.pp | 14 | ||||
m--------- | modules/reboot | 0 |
4 files changed, 22 insertions, 0 deletions
diff --git a/.gitmodules b/.gitmodules index e090332..6792f86 100644 --- a/.gitmodules +++ b/.gitmodules | |||
@@ -1,3 +1,6 @@ | |||
1 | [submodule "modules/stdlib"] | 1 | [submodule "modules/stdlib"] |
2 | path = modules/stdlib | 2 | path = modules/stdlib |
3 | url = https://github.com/puppetlabs/puppetlabs-stdlib.git | 3 | url = https://github.com/puppetlabs/puppetlabs-stdlib.git |
4 | [submodule "modules/reboot"] | ||
5 | path = modules/reboot | ||
6 | url = https://github.com/puppetlabs/puppetlabs-reboot.git | ||
diff --git a/manifests/site.pp b/manifests/site.pp index d8c9843..cd2063a 100644 --- a/manifests/site.pp +++ b/manifests/site.pp | |||
@@ -1,7 +1,12 @@ | |||
1 | node default { | 1 | node default { |
2 | include stdlib | 2 | include stdlib |
3 | |||
3 | class { 'ovh_cleanup': } | 4 | class { 'ovh_cleanup': } |
4 | class { 'locales': } | 5 | class { 'locales': } |
5 | class { 'base_packages': } | 6 | class { 'base_packages': } |
6 | class { 'cron_puppet': } | 7 | class { 'cron_puppet': } |
8 | |||
9 | reboot { 'after_run': | ||
10 | apply => 'finished' | ||
11 | } | ||
7 | } | 12 | } |
diff --git a/modules/ovh_cleanup/manifests/init.pp b/modules/ovh_cleanup/manifests/init.pp index 75b4978..0704cf9 100644 --- a/modules/ovh_cleanup/manifests/init.pp +++ b/modules/ovh_cleanup/manifests/init.pp | |||
@@ -39,4 +39,18 @@ class ovh_cleanup { | |||
39 | file { '/etc/resolv.conf.pacorig': | 39 | file { '/etc/resolv.conf.pacorig': |
40 | ensure => 'absent' | 40 | ensure => 'absent' |
41 | } | 41 | } |
42 | |||
43 | |||
44 | file { '/etc/udev/rules.d/80-net-setup-link.rules': | ||
45 | ensure => 'absent', | ||
46 | } | ||
47 | exec { '/usr/bin/sed -i -e "s/Name=eth0/Name=en*/" /etc/systemd/network/eth0-dhcp.network': | ||
48 | subscribe => File['/etc/udev/rules.d/80-net-setup-link.rules'], | ||
49 | refreshonly => true | ||
50 | } | ||
51 | exec { '/usr/bin/mv /etc/systemd/network/eth0-dhcp.network /etc/systemd/network/en-dhcp.network': | ||
52 | subscribe => Exec['/usr/bin/sed -i -e "s/Name=eth0/Name=en*/" /etc/systemd/network/eth0-dhcp.network'], | ||
53 | notify => Reboot['after_run'], | ||
54 | refreshonly => true, | ||
55 | } | ||
42 | } | 56 | } |
diff --git a/modules/reboot b/modules/reboot new file mode 160000 | |||
Subproject a9b48a7325130c4ab19cbfe2de1d12b7cbbae71 | |||