Split out unattended_upgrades module

Change-Id: Iaf9740d077781363e82f597c7a4983fe40879431
This commit is contained in:
Spencer Krum 2015-01-28 10:25:22 -08:00 committed by James E. Blair
parent f522fda83e
commit addb7bcb1d
4 changed files with 1 additions and 71 deletions

View File

@ -89,6 +89,7 @@ INTEGRATION_MODULES["https://git.openstack.org/openstack-infra/puppet-ssh"]="ori
INTEGRATION_MODULES["https://git.openstack.org/openstack-infra/puppet-reviewday"]="origin/master"
INTEGRATION_MODULES["https://git.openstack.org/openstack-infra/puppet-drupal"]="origin/master"
INTEGRATION_MODULES["https://git.openstack.org/openstack-infra/puppet-mediawiki"]="origin/master"
INTEGRATION_MODULES["https://git.openstack.org/openstack-infra/puppet-unattended_upgrades"]="origin/master"
INTEGRATION_MODULES["https://git.openstack.org/openstack-infra/puppet-unbound"]="origin/master"
INTEGRATION_MODULES["https://git.openstack.org/openstack-infra/puppet-user"]="origin/master"

View File

@ -1,6 +0,0 @@
APT::Periodic::Enable "1";
APT::Periodic::Update-Package-Lists "1";
APT::Periodic::Download-Upgradeable-Packages "1";
APT::Periodic::AutocleanInterval "5";
APT::Periodic::Unattended-Upgrade "1";
APT::Periodic::RandomSleep "1800";

View File

@ -1,32 +0,0 @@
# == Class: unattended_upgrades
#
class unattended_upgrades(
$ensure = present,
$origins = []
) {
package { 'unattended-upgrades':
ensure => $ensure,
}
package { 'mailutils':
ensure => $ensure,
}
file { '/etc/apt/apt.conf.d/10periodic':
ensure => $ensure,
owner => 'root',
group => 'root',
mode => '0444',
source => 'puppet:///modules/unattended_upgrades/10periodic',
replace => true,
}
file { '/etc/apt/apt.conf.d/50unattended-upgrades':
ensure => $ensure,
owner => 'root',
group => 'root',
mode => '0444',
content => template('unattended_upgrades/50unattended-upgrades.erb'),
replace => true,
}
}

View File

@ -1,33 +0,0 @@
// Automatically upgrade packages from these (origin, archive) pairs
Unattended-Upgrade::Allowed-Origins {
// ${distro_id} and ${distro_codename} will be automatically expanded
"${distro_id} stable";
"${distro_id} ${distro_codename}-security";
"${distro_id} ${distro_codename}-updates";
// "${distro_id} ${distro_codename}-proposed-updates";
<% @origins.each do |origin| -%>
"<%= origin %>";
<% end -%>
};
// List of packages to not update
Unattended-Upgrade::Package-Blacklist {
// "vim";
// "libc6";
// "libc6-dev";
// "libc6-i686";
};
// Send email to this address for problems or packages upgrades
// If empty or unset then no email is sent, make sure that you
// have a working mail setup on your system. The package 'mailx'
// must be installed or anything that provides /usr/bin/mail.
Unattended-Upgrade::Mail "root";
// Do automatic removal of new unused dependencies after the upgrade
// (equivalent to apt-get autoremove)
//Unattended-Upgrade::Remove-Unused-Dependencies "false";
// Automatically reboot *WITHOUT CONFIRMATION* if a
// the file /var/run/reboot-required is found after the upgrade
//Unattended-Upgrade::Automatic-Reboot "false";