From b4cc317aaf95e76fe648ef36895f6d4ba6fea490 Mon Sep 17 00:00:00 2001 From: Micah Anderson Date: Thu, 4 Jun 2015 13:36:24 -0400 Subject: add preferences snippet for leap repository (#7090) Change-Id: Ia7a35c8613350ad75ff1ebbdda0a09efa0960ba6 --- puppet/modules/site_apt/manifests/init.pp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/puppet/modules/site_apt/manifests/init.pp b/puppet/modules/site_apt/manifests/init.pp index c32c29c4..02f85140 100644 --- a/puppet/modules/site_apt/manifests/init.pp +++ b/puppet/modules/site_apt/manifests/init.pp @@ -31,6 +31,12 @@ class site_apt { priority => 999 } + apt::preferences_snippet { 'leap': + priority => 999, + package => '*', + pin => 'origin "deb.leap.se"' + } + # All packages should be installed _after_ refresh_apt is called, # which does an apt-get update. # There is one exception: -- cgit v1.2.3 From 251178948efda3cf15b6f64af57d6d594f31695e Mon Sep 17 00:00:00 2001 From: varac Date: Sat, 6 Jun 2015 15:38:52 +0200 Subject: Configure apt preferences before installing any packages Change-Id: Iac4dc8428ff5e663870ed4dd6a2b840e0904e5be --- puppet/modules/site_apt/manifests/init.pp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/puppet/modules/site_apt/manifests/init.pp b/puppet/modules/site_apt/manifests/init.pp index 02f85140..cf49f870 100644 --- a/puppet/modules/site_apt/manifests/init.pp +++ b/puppet/modules/site_apt/manifests/init.pp @@ -1,3 +1,4 @@ +# setup apt on all nodes class site_apt { $sources = hiera('sources') @@ -36,13 +37,14 @@ class site_apt { package => '*', pin => 'origin "deb.leap.se"' } - + # All packages should be installed _after_ refresh_apt is called, # which does an apt-get update. # There is one exception: # The creation of sources.list depends on the lsb package File['/etc/apt/preferences'] -> + Apt::Preferences_snippet <| |> -> Exec['refresh_apt'] -> - Package <| ( title != 'lsb' ) |> + Package <| ( title != 'lsb' ) |> } -- cgit v1.2.3 From 18e247ae29e7ee787e350724e2884da0a74bbd63 Mon Sep 17 00:00:00 2001 From: varac Date: Sun, 7 Jun 2015 02:31:38 +0200 Subject: deploy check_openvpn_server.pl after nagios-plugins-standard package is installed Change-Id: I272b30fd79e89ddf968c0a6e453d53a1f0540397 --- puppet/modules/site_nagios/manifests/server.pp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/puppet/modules/site_nagios/manifests/server.pp b/puppet/modules/site_nagios/manifests/server.pp index ae266c36..cb6c8d95 100644 --- a/puppet/modules/site_nagios/manifests/server.pp +++ b/puppet/modules/site_nagios/manifests/server.pp @@ -1,3 +1,4 @@ +# configures nagios on monitoring node class site_nagios::server inherits nagios::base { # First, purge old nagios config (see #1467) @@ -42,10 +43,11 @@ class site_nagios::server inherits nagios::base { # deploy serverside plugins file { '/usr/lib/nagios/plugins/check_openvpn_server.pl': - source => 'puppet:///modules/nagios/plugins/check_openvpn_server.pl', - mode => '0755', - owner => 'nagios', - group => 'nagios', + source => 'puppet:///modules/nagios/plugins/check_openvpn_server.pl', + mode => '0755', + owner => 'nagios', + group => 'nagios', + require => Package['nagios-plugins']; } create_resources ( site_nagios::add_host_services, $nagios_hosts ) -- cgit v1.2.3