Re: [Puppet Users] Re: puppet SSHD port based on hostname

2017-08-25 Thread Rob Nelson
If you're using saz/ssh, just add this to the 'options' parameter (hash) of ssh::server. Anything that doesn't have a specific parameter can be implemented there. On Fri, Aug 25, 2017 at 11:07 PM John wrote: > So, I agree this is doable in Hiera. However, I think for the

[Puppet Users] Re: puppet SSHD port based on hostname

2017-08-25 Thread John
So, I agree this is doable in Hiera. However, I think for the SAZ SSH module, it would be better for me to include it in the sshd_config.erb. I've added the following to sshd_config.: <%- if ServerName == myhost -%> Port = <%- end -%> Puppet run finishes with no errors, but

Re: [Puppet Users] yumrepo still not working ?

2017-08-25 Thread Fabrice Bacchella
Yes. > Le 25 août 2017 à 20:10, Rob Nelson a écrit : > > The puppet log shows the resource name only. Did you check for the presence > of the file at all? > > On Fri, Aug 25, 2017 at 9:20 AM Fabrice Bacchella >

[Puppet Users] Re: Data in Modules: Fail on unsupported OS

2017-08-25 Thread Michael Watters
I usually do this within the manifest itself. For example: if $facts['osfamily']!='RedHat'{fail("$operatingsystem is not supported")} On Tuesday, August 22, 2017 at 7:34:12 AM UTC-4, plapp...@gmail.com wrote: > > Good morning :) > > I'm currently writing a puppet module for the OpenBSD

[Puppet Users] Is it possible to make a deep merge of 2 hashes in puppet code?

2017-08-25 Thread Francois Lafont
Hi @all, :) I would like to make a deep merge between 2 hashes: 1. directly in puppet code, 2. with the same behavior that the deep merging of the lookup() option (when set with 'deep' as merge policy of course). I have tried the deep_merge() function from stdlib (version v4.19.0

Re: [Puppet Users] yumrepo still not working ?

2017-08-25 Thread Rob Nelson
The puppet log shows the resource name only. Did you check for the presence of the file at all? On Fri, Aug 25, 2017 at 9:20 AM Fabrice Bacchella < fabrice.bacche...@orange.fr> wrote: > I tried to create a yumrepo for elasticsearch, and like many years ago, > puppet seems to be unable to create

[Puppet Users] puppet augeas fails with sudoers in RHEL 7.4

2017-08-25 Thread Fabrice Bacchella
I've upgraded a test machin with Centos 7.4 CR When I run puppet on it, configuring /etc/sudoers with augeas, I'm getting: Warning: Augeas[sudoers include](provider=augeas): Loading failed for one or more files, see debug for /augeas//error output augtool ls /augeas//error says : pos = 2308

[Puppet Users] yumrepo still not working ?

2017-08-25 Thread Fabrice Bacchella
I tried to create a yumrepo for elasticsearch, and like many years ago, puppet seems to be unable to create it in the requested files: yumrepo {'elasticsearch-5.x': name => 'elasticsearch-5.x', baseurl=> 'https://artifacts.elastic.co/packages/5.x/yum',

Re: [Puppet Users] Re: [ANN] Puppet Development Kit (pdk) 1.0

2017-08-25 Thread David Schmitt
On Fri, Aug 25, 2017 at 11:40 AM Pete Brown wrote: > Does it have support for puppet 5 and can you use it to test code against > multiple versions of puppet? > This kinda works with v1, using the old pattern of setting environment variables (see this snippet

Re: [Puppet Users] Re: puppet SSHD port based on hostname

2017-08-25 Thread Pete Brown
That is pretty easy to do with hiera. It’s too complex to explain in an email so i would recommend looking up the docs for it. This is the best olace to start. If you aren’t using puppet 5 just switch to the version you are using. https://docs.puppet.com/puppet/5.1/hiera_intro.html On Tue, 22

Re: [Puppet Users] Re: [ANN] Puppet Development Kit (pdk) 1.0

2017-08-25 Thread Pete Brown
Does it have support for puppet 5 and can you use it to test code against multiple versions of puppet? Could it also be used in the manner to test code under a CI/CD setup like Jenkins or Travis? On Mon, 21 Aug 2017 at 09:57, David Schmitt wrote: > Hi Charlie, > >