From f12b007edd557e91359fd9a5fba57f49e4a59a04 Mon Sep 17 00:00:00 2001 From: varac Date: Tue, 26 Jan 2016 14:42:17 +0100 Subject: [refactor] Unify `apt-get update` into one resource Before, there were two Execs that did an `apt-get update`, `Exec[refresh_apt]` and `Exec[apt_updated]`, which were triggered by different resources. This changes gets rid of the first one, and all resources now depend on `Exec[apt_updated]`. --- manifests/update.pp | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) (limited to 'manifests/update.pp') diff --git a/manifests/update.pp b/manifests/update.pp index 3f45125..dde8320 100644 --- a/manifests/update.pp +++ b/manifests/update.pp @@ -1,13 +1,7 @@ -class apt::update { +class apt::update inherits ::apt { - exec { 'update_apt': - command => '/usr/bin/apt-get update && /usr/bin/apt-get autoclean', - require => [ - File['/etc/apt/apt.conf.d', '/etc/apt/preferences' ], - File['/etc/apt/sources.list'] ], - loglevel => info, - # Another Semaphor for all packages to reference - alias => 'apt_updated' + Exec['update_apt'] { + refreshonly => false } } -- cgit v1.2.3