From 420d537ac17ded4dc383c4004bf636103d03a852 Mon Sep 17 00:00:00 2001 From: Ben Godfrey Date: Fri, 11 Mar 2011 18:14:31 +0000 Subject: [PATCH] Add call to apt-update after add-apt-repository in apt::ppa --- manifests/ppa.pp | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/manifests/ppa.pp b/manifests/ppa.pp index c9ab955..2821051 100644 --- a/manifests/ppa.pp +++ b/manifests/ppa.pp @@ -7,9 +7,14 @@ define apt::ppa( package { "python-software-properties": } - exec { "/usr/bin/add-apt-repository ${name}": - require => Package["python-software-properties"], - # TODO: unless => 'check' - } + exec { "apt-update": + command => "/usr/bin/apt-get update", + refreshonly => true, + } + + exec { "/usr/bin/add-apt-repository ${name}": + require => Package["python-software-properties"], + notify => Exec["apt-update"] + } } -- 2.45.2