From 96439f922b4c1612035111a6ce8050d34b488538 Mon Sep 17 00:00:00 2001 From: Lennart Betz Date: Fri, 7 Jun 2024 12:19:51 +0200 Subject: [PATCH] Limit package dependency to icinga modules --- manifests/repos/apt.pp | 4 ++-- manifests/repos/yum.pp | 2 +- manifests/repos/zypper.pp | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/manifests/repos/apt.pp b/manifests/repos/apt.pp index beac7f3..f7b1577 100644 --- a/manifests/repos/apt.pp +++ b/manifests/repos/apt.pp @@ -15,7 +15,7 @@ if $configure_backports { include apt::backports - Apt::Source['backports'] -> Package <| title != 'apt-transport-https' |> + Apt::Source['backports'] -> Package <| tag == 'icinga' or tag == 'icinga2' or tag == 'icingadb' or tag == 'icingaweb2' |> } $repos.each |String $repo_name, Hash $repo_config| { @@ -27,7 +27,7 @@ $_repo_config = $repo_config } - Apt::Source[$repo_name] -> Package <| title != 'apt-transport-https' |> + Apt::Source[$repo_name] -> Package <| tag == 'icinga' or tag == 'icinga2' or tag == 'icingadb' or tag == 'icingaweb2' |> apt::source { $repo_name: * => { ensure => present } + $_repo_config, } diff --git a/manifests/repos/yum.pp b/manifests/repos/yum.pp index 07764f5..f1e02d1 100644 --- a/manifests/repos/yum.pp +++ b/manifests/repos/yum.pp @@ -26,7 +26,7 @@ $repos.each |String $repo_name, Hash $repo_config| { if $repo_name in keys($managed) and $managed[$repo_name] { - Yumrepo[$repo_name] -> Package <| |> + Yumrepo[$repo_name] -> Package <| tag == 'icinga' or tag == 'icinga2' or tag == 'icingadb' or tag == 'icingaweb2' |> yumrepo { $repo_name: * => $repo_config, } diff --git a/manifests/repos/zypper.pp b/manifests/repos/zypper.pp index 89d10a9..7ea0191 100644 --- a/manifests/repos/zypper.pp +++ b/manifests/repos/zypper.pp @@ -32,7 +32,7 @@ path => "/etc/zypp/repos.d/${repo_name}.repo", line => "proxy=${repo_config['proxy']}", } - -> Package <| |> + -> Package <| tag == 'icinga' or tag == 'icinga2' or tag == 'icingadb' or tag == 'icingaweb2' |> } } }