summaryrefslogtreecommitdiff
path: root/files/puppet/modules/custom
diff options
context:
space:
mode:
Diffstat (limited to 'files/puppet/modules/custom')
-rw-r--r--files/puppet/modules/custom/manifests/apt/additional_sources.pp24
-rw-r--r--files/puppet/modules/custom/manifests/init.pp8
2 files changed, 30 insertions, 2 deletions
diff --git a/files/puppet/modules/custom/manifests/apt/additional_sources.pp b/files/puppet/modules/custom/manifests/apt/additional_sources.pp
new file mode 100644
index 0000000..029c92d
--- /dev/null
+++ b/files/puppet/modules/custom/manifests/apt/additional_sources.pp
@@ -0,0 +1,24 @@
+# Add additional sources and configure unattended updates for it
+define custom::apt::additional_sources (
+ $ensure = 'present',
+ $signed_by = '[signed-by=/usr/share/keyrings/leap-archive.gpg]',
+ $repodomain = 'deb.leap.se',
+ $project = 'platform',
+ $dist = $::lsbdistcodename,
+ $component = 'master'
+){
+
+ apt::sources_list { "${name}.list":
+ ensure => $ensure,
+ content => "deb ${signed_by} http://${repodomain}/${project} ${dist} ${component}",
+ }
+
+ apt::apt_conf { "52unattended-upgrades-${name}":
+ content => "Unattended-Upgrade::Origins-Pattern {
+ \"site=${repodomain},component=${component}\";
+}",
+ require => Package['unattended-upgrades'],
+ refresh_apt => false,
+ }
+
+}
diff --git a/files/puppet/modules/custom/manifests/init.pp b/files/puppet/modules/custom/manifests/init.pp
index 0a67491..db5dfbb 100644
--- a/files/puppet/modules/custom/manifests/init.pp
+++ b/files/puppet/modules/custom/manifests/init.pp
@@ -22,7 +22,11 @@ class custom {
include custom_munin_node::openvpn
}
- if member ( $services, 'pixelated') {
- include ::pixelated
+ # Use additional packages from master repo
+ if $::domain == 'unstable.bitmask.net' {
+ ::custom::apt::additional_sources {'leap-master':
+ component => 'master'
+ }
}
+
}