[Puppet Users] Can't access custom fact as hash

2015-11-04 Thread Bret Wortman
I defined this custom fact, which queries a local tool to determine what roles a particular system should have assigned to it: Facter.add(:dgroles) do setcode do roles = {} res_hash = {} results = Facter::Core::Execution.exec("dg-role -b").split("/n") results.e

[Puppet Users] Re: Can't access custom fact as hash

2015-11-04 Thread Bret Wortman
This is on Puppet open source V3.8.3 server and V3.8.1 client. On Wednesday, November 4, 2015 at 8:08:20 AM UTC-5, Bret Wortman wrote: > > I defined this custom fact, which queries a local tool to determine what > roles a particular system should have assigned to it: > > Facter.add(:dgroles) do >

[Puppet Users] epp conditionals not working, erb is

2015-11-04 Thread Erwin Bogaard
As epp is the way to go, I'm trying to create all my new templates in epp-format. I have a problem with using conditionals, though. I have the following conditional in an epp template: ... <%- if $xxx_yyy == true { -%> // code here <%- } -%> ... When I apply this template with a defined type res

[Puppet Users] Re: epp conditionals not working, erb is

2015-11-04 Thread mathworks
I ran into this problem also. Are you access the variable $xxx_yyy will full puppet path? IE $classname::xxx_yyy If not you need to pass the variable into the template like this. content => epp('module/template.epp', { 'xxx_yyy' => "$xxx_yyy"}), Hope This helps On Wednesday, November 4,

[Puppet Users] Re: epp conditionals not working, erb is

2015-11-04 Thread Erwin Bogaard
Aaron, thanks! That was the problem. I think I misread (or didn't read) the paragraph "Accessing variables" in the documentation. Thanks for helping me out with this. On Wednesday, 4 November 2015 14:34:11 UTC+1, Aaron Russell wrote: > > I ran into this problem also. > > Are you access the varia

[Puppet Users] Re: Can't access custom fact as hash

2015-11-04 Thread Bret Wortman
For completeness' sake, the answer was to set stringify_facts = false in puppet.conf's [main] section. On Wednesday, November 4, 2015 at 8:09:36 AM UTC-5, Bret Wortman wrote: > > This is on Puppet open source V3.8.3 server and V3.8.1 client. > > On Wednesday, November 4, 2015 at 8:08:20 AM UTC-5,

Re: [Puppet Users] Re: Forge ACL Module 1.1.1 on Windows 7 x64 SP1

2015-11-04 Thread Rob Reynolds
On Mon, Oct 19, 2015 at 10:10 AM, jmp242 wrote: > Hmm, so on one test computer, the upgrade to puppet 3.8.3 fixed the issue. > On the second test computer, it didn't - everything remains the same, but > getting the same repeated ACE... > What does 'cacls *folderlocation*' return? > > > On Thur

Re: [Puppet Users] powershell detect then install nonexistent or replace existing custom service

2015-11-04 Thread Aaron
Thanks Rob! This appears to work well after looking into your suggestions...I tried to include an "unless" statement at the end of the Install New FooService Service" block for a little extra security, but it didn't seem to like that so I removed it - I'm not sure of the reason for that, howeve

Re: [Puppet Users] powershell detect then install nonexistent or replace existing custom service

2015-11-04 Thread Aaron
blech - nevermind. still throws horrible errors when the service has not been installed yet and puppet runs (such as on a new VM). Is there any way to have it see that there is an error during the uninstall and then run an ELSE and move onto the Install portion without getting hung up on not