I this correct in your provider/karaf_feature/karaf_feature.rb file?
if resource = resources[prov.name]
Should that be "=="?
Best regards,
Cristian Falcas
On Fri, Jun 27, 2014 at 4:14 PM, Gavin Williams <[email protected]> wrote:
> Felix
>
> Cheers for the response.
>
> Whilst the 'client' command can be run as root, the fact that there are
> command line args that can be optionally passed in makes it more
> challenging...
> I guess I could look at creating a client config file and use that to
> define the args if appropriate...
>
> Cheers again
> Gavin
>
> On Friday, 27 June 2014 13:25:29 UTC+1, Felix.Frank wrote:
>>
>> Hi,
>>
>> since the karaf_exec method is trying to access an instance member
>> (@resource), it should not be a class method - it needs to be an
>> instance method.
>>
>> As such, you cannot use it for prefetching, true.
>>
>> I think you need to take a step back and think about what the Puppet
>> agent is expected to do here in the prefetch phase. Can it do its things
>> as root? If not, is there a cue in some config file that it can rely on
>> to pick a suitable user?
>>
>> If both are not the case, you may indeed find it impossible to perform
>> prefetching, because you cannot pass arguments from your manifest to the
>> agent at that level of granularity [1].
>>
>> HTH,
>> Felix
>>
>> [1] https://github.com/puppetlabs/puppet/pull/2136#issuecomment-35562203
>>
>> On 06/27/2014 01:14 PM, Gavin Williams wrote:
>> > What I was aiming to achieve is that the command is executed by Puppet
>> > as a specified user, as defined on Line 24 of [4].
>> > However as '@resource' is nil at the point of prefetch call, it's not
>> > working :(
>>
> --
> 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/155d2e09-df7e-4f44-86f0-7a6af28252c8%40googlegroups.com
> <https://groups.google.com/d/msgid/puppet-users/155d2e09-df7e-4f44-86f0-7a6af28252c8%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>
> For more options, visit https://groups.google.com/d/optout.
>
--
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/CAMo7R_da4ca4OYGknpNKYo3GTFq5XE3KH8zmXP%2By50CLNqV5Kg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.