How to specify dependency

20 views
Skip to first unread message

Andrey Ageyev

unread,
Dec 25, 2012, 11:16:31 PM12/25/12
to puppet...@googlegroups.com
Hi,

sorry for stupid question, but how I can specify package depends on class with parameters?

class nginx::install ( 
$nginx  = "nginx-light",
$ensure = 'installed'
) {
include nginx::service

package { $nginx :
   ensure  => $ensure,
notify  => Class["nginx::service"],
}
}
Must depend on:
apt::ppa { "ppa:nginx/stable": }

How to correctly specify this inside class "nginx::install"?

Thanks.

Roman Shaposhnik

unread,
Dec 26, 2012, 3:50:30 PM12/26/12
to puppet...@googlegroups.com
Unless I've misunderstood your question, wouldn't a
simple dependency of the following kind work?
require => Apt::Ppa[ "ppa:nginx/stable" ]

Thanks,
Roman.
Reply all
Reply to author
Forward
0 new messages