Hey jwkoelewijn, do you mind posting your solution for the rabbitmq 
provider.

Thanks!

On Monday, 8 October 2012 04:18:42 UTC-7, jwkoelewijn wrote:
>
> Thanks for this suggestion,
>
> this did the trick!
>
> Kind regards,
>
> J.W. Koelewijn
>
> On Thursday, October 4, 2012 4:24:26 PM UTC+2, jcbollinger wrote:
>>
>>
>>
>> On Wednesday, October 3, 2012 8:11:55 AM UTC-5, Daniele Sluijters wrote:
>>>
>>> Hi,
>>>
>>> Sorry, I got confused between two things. It's not the actual Exec type. 
>>> it's when a provider executes a command that the environment cannot be set.
>>>
>>>
>> Puppet's guts have code for setting a custom environment for commands, 
>> but the 'command' and 'commands' functions don't provide an interface to 
>> it.  I'm working from the code here, not actual experience, but it looks 
>> like you can use the has_command() function instead, something like:
>>
>> has_command(:my_command, '/usr/sbin') do
>>   environment({ 'HOME' => '/some/homedir' })
>> end
>>
>> I don't remember seeing that documented anywhere, so it probably 
>> qualifies as an internal interface -- use at your own risk.  Since you'll 
>> probably want to look at the code yourself, you can find that function in 
>> puppet/lib/puppet/provider.rb.  In particular, you can examine how it is 
>> used by the documented 'command' and 'commands' functions.
>>
>>
>> John
>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/puppet-users/-/FhtxtSinbo4J.
To post to this group, send email to puppet-users@googlegroups.com.
To unsubscribe from this group, send email to 
puppet-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en.

Reply via email to