Newer
Older
# unattended-upgrades konfigurieren
class ubuntu_server::unattended_upgrades{
##
## TODO
## Paket ist noch nicht vollständig aktiv.
## es fehlt noch ein dpkg-reconfigure für puppet
##
$unattended_upgrade_automatic_reboot = hiera('unattended_upgrade_automatic_reboot')
$unattended_upgrade_autoremove = hiera('unattended_upgrade_autoremove')
File{
owner => root,
group => root,
mode => 644,
}
exec{'unattended-upgrades-debconf':
path => $path,
command => "echo unattended-upgrades unattended-upgrades/enable_auto_updates boolean true | debconf-set-selections",
unless => "debconf-get-selections | grep unattended | grep -q true",
before => Package["unattended-upgrades"],
}
package{'unattended-upgrades':
ensure => present,
}
file{'/etc/apt/apt.conf.d/50unattended-upgrades':
ensure => present,
content => template("ubuntu_server/etc/apt/apt.conf.d/${operatingsystem}_50unattended-upgrades.erb"),
}
file{'/etc/apt/apt.conf.d/20auto-upgrades':
ensure => present,
source => "puppet:///modules/ubuntu_server/etc/apt.conf.d/20auto-upgrades",