From: Scott McLeod Date: Mon, 18 Apr 2011 01:43:33 +0000 (-0400) Subject: Support ability to add more than one PPA X-Git-Tag: 0.0.1~33 X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=ed2d19e2f3aa025871ec8334d48db53b800a91f2;hp=420d537ac17ded4dc383c4004bf636103d03a852;p=puppet-modules%2Fpuppetlabs-apt.git Support ability to add more than one PPA --- diff --git a/manifests/init.pp b/manifests/init.pp index 7513983..677523b 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -4,6 +4,8 @@ class apt { $root = '/etc/apt' $provider = '/usr/bin/apt-get' + package { "python-software-properties": } + file { "sources.list": name => "${root}/sources.list", ensure => present, diff --git a/manifests/ppa.pp b/manifests/ppa.pp index 2821051..9c277e9 100644 --- a/manifests/ppa.pp +++ b/manifests/ppa.pp @@ -3,18 +3,16 @@ define apt::ppa( ) { - include apt + require apt - package { "python-software-properties": } - - exec { "apt-update": - command => "/usr/bin/apt-get update", + exec { "apt-update-${name}": + command => "/usr/bin/aptitude update", refreshonly => true, } - exec { "/usr/bin/add-apt-repository ${name}": - require => Package["python-software-properties"], - notify => Exec["apt-update"] + exec { "add-apt-repository-${name}": + command => "/usr/bin/add-apt-repository ${name}", + notify => Exec["apt-update-${name}"], } }