aboutsummaryrefslogtreecommitdiff
path: root/manifests/upgrade_package.pp
diff options
context:
space:
mode:
Diffstat (limited to 'manifests/upgrade_package.pp')
-rw-r--r--manifests/upgrade_package.pp15
1 files changed, 2 insertions, 13 deletions
diff --git a/manifests/upgrade_package.pp b/manifests/upgrade_package.pp
index d607150..30572c9 100644
--- a/manifests/upgrade_package.pp
+++ b/manifests/upgrade_package.pp
@@ -2,10 +2,6 @@ define apt::upgrade_package (
$version = ''
) {
- if $apt::disable_update == false {
- include apt::update
- }
-
$version_suffix = $version ? {
'' => '',
'latest' => '',
@@ -26,17 +22,10 @@ define apt::upgrade_package (
}
}
- $req = $apt::disable_update ? {
- true => Package['apt-show-versions', 'dctrl-tools'],
- default => [
- Exec['apt_updated'],
- Package['apt-show-versions', 'dctrl-tools']
- ],
- }
-
exec { "apt-get -q -y -o 'DPkg::Options::=--force-confold' install ${name}${version_suffix}":
onlyif => [ "grep-status -F Status installed -a -P $name -q", "apt-show-versions -u $name | grep -q upgradeable" ],
- require => $req
+ require => Package['apt-show-versions', 'dctrl-tools'],
+ before => Exec['apt_updated']
}
}