On Jun 20, 2007, at 5:07 PM, Robert Nickel wrote:
> Is it possible to have a require line in a virtual resource when
> the required
> resource is itself a virtual resource?
>
> Specifically, it would be great if the following worked:
>
> @file { usr_local:
> path => "/usr/local",
> mode => 0755,
> owner => root,
> group => root,
> ensure => directory
> }
>
> @file { usr_local_bin:
> path => "/usr/local/bin",
> mode => 0755,
> owner => root,
> group => root,
> require => File <| title == usr_local |>,
> ensure => directory
> }
>
> Yes, I know that listing both works but just commenting. :-)
You''d have to do a normal ''require'', with
File[usr_local], not the
collection, but otherwise, yes, this will work as long as the
usr_local file gets realized at some point.
Realizing usr_local_bin would not automatically realize usr_local,
which is possibly what you meant.
--
Wear the old coat and buy the new book. -- Austin Phelps
---------------------------------------------------------------------
Luke Kanies | http://reductivelabs.com | http://madstop.com