On Friday, May 4, 2012 10:07:33 PM UTC-7, Dan Bode wrote:
>
>
> ..
> The main thing that Puppet really 'logs' is state transitions. (it also 
> logs command on debug, but the thing it is really designe to do is describe 
> system state transitions)
>
> - it a resource exists and is ensurable,
> - then resource can use the ensure property to describe if the thing 
> should exist
> - exists will be used to query if the thing currently exists 
>   - true means it currently exists on the system
>   - false indicates it does not
> - if the resource was specified as being in the ensure state present, then 
> if the thing does not exist, then create will be called to ensure that it 
> is in the state of present
>
> If this process occurs, the Puppet should log the state transition
>

Okay, thanks for confirming that.

btw, I found solution to my "create not called" problem. I think it was 
that I had forgotten to force "ensure=present" in the manifest.
At any rate, that part is working now :-}

*Almost* done with this beastie!  Now I just have to force it to return 
"true" when things already look good!
ruby is wierd. sigh.   I have
@resource[:value]    claiming its value is "true"
and the output of a command, in variable 'output', claming its value is 
"true".
BUT...

    if output == @resource[:value]
      Puppet.debug "svcprop value is desired value. sysprop return true"
      return true
    end

is NOT returning true. "exists?" falling through and returning false. 
sighh...

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Developers" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/puppet-dev/-/Hh7lJDzqqb4J.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/puppet-dev?hl=en.

Reply via email to