On Thursday, November 7, 2013 9:37:02 AM UTC-6, lth wrote:
>
> Thanks but I still get a syntax error when doing
>
> file{"bar":
>     require => A:foo['baz']
> }
>
>>

Evidently you have not understood the advice for which you are giving 
thanks, because it was to NOT DO THAT.  Instead, do this:

file { 'bar':
  # initial uppercase name components:
  require => A::Foo['baz']
}

Note there that

   1. EACH name component in a resource reference must be capitalized (i.e. 
   both the 'A' and the 'Foo'), and
   2. the name component separator is a double colon (::), not a single 
   colon.

In addition, the actual names of modules, classes, and resource types 
should begin with *lowercase* letters, so that resource references (which 
use capital letters) are distinguished from other uses of class and 
resource names.  Thus, you should not have any module named "A"; rather, it 
should be named "a".  Your definitions should thus have the form

# initial lowercase letters:
define a::foo(...) {
  #...
}

The autoloader will expect to find that definition in <module 
path>/a/manifests/foo.pp, where in principle case matters, but in practice 
that depends on the filesystem.


John

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/ec36270d-cbc0-4653-ad71-7437795b9e7b%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to