[Puppet Users] Question: performing actions based on user account being present

2014-01-31 Thread Matthew Reams
I want to create a default module for SMTP. However, I want to put some logic into it. I have postfix as my default local SMTP server for my Linux servers. However, I also have a Zimbra server. Basically what I want to do is If 'id zimbra' is true, then ensure service postfix is stopped. Els

[Puppet Users] Error: Puppet::Parser::AST::Resource failed with error ArgumentError: Invalid resource type jdk7::javaexec

2014-01-31 Thread Supriya Uppalapati
Hi, I am new to writing code for puppet. I installed biemond/jdk7 module. In that it has install7.pp and javaexec.pp Now I am trying to modify the parameters using wrapper class. In that I wrote class javajdk { include jdk7,java7_exec jdk7::install7{ "jdk1.7.0_25" : version =>

Re: [Puppet Users] Puppet resources or plain script?

2014-01-31 Thread Ian Mortimer
On Sat, 1 Feb 2014, zerozerouno...@gmail.com wrote: Actually, I have to work with custom config files, too. But they use standard .ini and .conf file structure, with [sections] and parameter=value pairs. Does augeas need custom templates to be developed in this case, too? I hoped it could work f

[Puppet Users] FreeBSD / osfamily

2014-01-31 Thread John
I've got the following code error: Error: openssh: not in required origin format: .*// Error: /Stage[main]/Ssh::Server::Install/Package[openssh]/ensure: change from absent to present failed: openssh: not in required origin format: .*// when I run the following: puppet agent --server=puppet --

Re: [Puppet Users] Re: CA puppetmaster

2014-01-31 Thread vassiliy vins
Yes, I did, because I copied the whole ca/ directory from my primary. And private/ folder is inside of ca/ What I discovered right now - client gets secondary puppetmasters' name and compare with the name in certificate. If they do not match each other , it does not accept certificate. On 31 Jan

Re: [Puppet Users] Re: CA puppetmaster

2014-01-31 Thread José Luis Ledesma
I don't have experience with ca in ha, but I think you should copy also ca private keys. El 31/01/2014 21:19, "Vassiliy Vins" escribió: > So, I have to copy ca/ directory from primary puppetmaster to secondary > one? Right? > > I did, no success , the same message Server hostname 'puppetserver

[Puppet Users] Re: CA puppetmaster

2014-01-31 Thread Vassiliy Vins
So, I have to copy ca/ directory from primary puppetmaster to secondary one? Right? I did, no success , the same message Server hostname 'puppetserver' did not match server certificate; expected puppetslave I can formulate my question with another words - why does client expect puppetslave,

[Puppet Users] Error: undefined method `gsub' for nil:NilClass

2014-01-31 Thread Juan Pablo Daniel
Hi guys, can you give me a hint on this? Thanks! Debug: Executing '/sbin/sysctl -n net.ipv4.ip_local_port_range' Error: undefined method `gsub' for nil:NilClass Error: /Stage[main]/Spotflux_pweb::Sysctl/Sysctl[net.ipv4.ip_local_port_range]/value: change from to 5000 65000 failed: undefined metho

Re: [Puppet Users] Re: Node Corruption

2014-01-31 Thread Doug_F
Yikes... (Scope(Class[Mail])) ::osfamily = Debian (Scope(Class[Mail])) Module mail, OsFamily RedHat, Operatingsystem Debian On Friday, January 31, 2014 10:35:39 AM UTC-7, Jose Luis Ledesma wrote: > > Sorry, i mean $::osfamily > > Regards > El 31/01/2014 18:29, joseluis...@gmail.com escribió:

[Puppet Users] Re: Warning: Unable to fetch my node definition, but the agent run will continue:

2014-01-31 Thread Szerémi Attila
I had this same issue. It seemed like the very first warning was the key. By adding the hostname that my own agent server was configured as to /etc/hosts as 127.0.0.1, all the errors went away and the command ran successfully. On Wednesday, November 27, 2013 1:01:38 AM UTC, Shawn Parker wrote:

Re: [Puppet Users] Re: How to execute a target action before this one when this one triggers

2014-01-31 Thread Bret Wortman
Here's what I did, and it seems to be working for now: service { 'cups': ensure => running, enable => true, } file { '/etc/cups/printers.conf': require => Package['cups'], ensure => present, so

Re: [Puppet Users] Re: Node Corruption

2014-01-31 Thread José Luis Ledesma
This is why you should always use explicit scoping :) Probably someone introduced some osfamily=RedHat in the current scope. Regards, El 31/01/2014 18:46, "Doug_F" escribió: > > Yikes... > > (Scope(Class[Mail])) ::osfamily = Debian > (Scope(Class[Mail])) Module mail, OsFamily RedHat, Operatings

Re: [Puppet Users] Re: Node Corruption

2014-01-31 Thread José Luis Ledesma
Please, could you try using $::operatingsystem? It could be some variable scoping problem... Regards, El 31/01/2014 18:27, "Doug_F" escribió: > I have tried additionally disconnecting puppetdb via removing storeconfigs > and puppetdb.yaml on the puppet master. > > >> I'm looking for more direct

Re: [Puppet Users] Re: Node Corruption

2014-01-31 Thread José Luis Ledesma
Sorry, i mean $::osfamily Regards El 31/01/2014 18:29, joseluis.lede...@gmail.com escribió: Please, could you try using $::operatingsystem? It could be some variable scoping problem... Regards, El 31/01/2014 18:27, "Doug_F" escribió: I have tried additionally disconnecting puppetdb via removi

[Puppet Users] Re: Node Corruption

2014-01-31 Thread Doug_F
I have tried additionally disconnecting puppetdb via removing storeconfigs and puppetdb.yaml on the puppet master. > I'm looking for more direct evidence of what fact values the master > receives. Humor me, please. > If I run Factor on deb-vm it matches /var/lib/puppet/yaml/node/deb-vm.par

[Puppet Users] Re: Copy files after Apache install...but only once.

2014-01-31 Thread jcbollinger
On Thursday, January 30, 2014 10:22:59 AM UTC-6, pskov...@gmail.com wrote: > > Hi, > > I am trying to install Apache with a default set of config files. I have > the following class: > > class base_apache { > > case $operatingsystem { > windows: { > file { 'apache_install

Re: [Puppet Users] circular dependency between user/home and parent directory owned by that user

2014-01-31 Thread jcbollinger
On Thursday, January 30, 2014 10:51:20 AM UTC-6, David Portabella wrote: > > again, > it is a circular dependency. > > what you are saying is to first create user and then file. > but to create the user, we need the file first also. > > An explicit relationship between the two resources takes pr

Re: [Puppet Users] Puppet resources or plain script?

2014-01-31 Thread zerozerounouno
On Friday, January 31, 2014 3:08:53 PM UTC+1, liu.cy wrote: > 1. augeas, but it depends on what application are you using. augeas only > works when template available. the most common config files are built-in > supported like sysctl.conf, iptables, httpd.conf. you have to write your > own au

Re: [Puppet Users] Puppet resources or plain script?

2014-01-31 Thread liu.cy
there are some ways to deal with it. 1. augeas, but it depends on what application are you using. augeas only works when template available. the most common config files are built-in supported like sysctl.conf, iptables, httpd.conf. you have to write your own augeas template if you are using own

Re: [Puppet Users] Puppet resources or plain script?

2014-01-31 Thread liu.cy
there are some ways to deal with it. 1. augeas, but it depends on what application are you using. augeas only works when template available. the most common config files are built-in supported like sysctl.conf, iptables, httpd.conf. you have to write your own augeas template if you are using own

Re: [Puppet Users] Puppet resources or plain script?

2014-01-31 Thread liu.cy
there are some ways to deal with it. 1. augeas, but it depends on what application are you using. augeas only works when template available. the most common config files are built-in supported like sysctl.conf, iptables, httpd.conf. you have to write your own augeas template if you are using own

Re: [Puppet Users] Puppet resources or plain script?

2014-01-31 Thread liu.cy
there are some ways to deal with it. 1. augeas, but it depends on what application are you using. augeas only works when template available. the most common config files are built-in supported like sysctl.conf, iptables, httpd.conf. you have to write your own augeas template if you are using own

Re: [Puppet Users] Puppet resources or plain script?

2014-01-31 Thread liu.cy
there are some ways to deal with it. 1. augeas, but it depends on what application are you using. augeas only works when template available. the most common config files are built-in supported like sysctl.conf, iptables, httpd.conf. you have to write your own augeas template if you are using own

Re: [Puppet Users] Puppet resources or plain script?

2014-01-31 Thread liu.cy
there are some ways to deal with it. 1. augeas, but it depends on what application are you using. augeas only works when template available. the most common config files are built-in supported like sysctl.conf, iptables, httpd.conf. you have to write your own augeas template if you are using own

[Puppet Users] Re: Node Corruption

2014-01-31 Thread jcbollinger
On Thursday, January 30, 2014 3:19:48 PM UTC-6, Doug_F wrote: > > /etc/debian_version is in place and facter on the box returns correctly. > If I run the puppetmaster in debug I can see it checking hiera for RedHat > not Debian values as it does when another debian client contacts it. > > I'm

[Puppet Users] Re: Trouble with notify/require/before/subscribe

2014-01-31 Thread zerozerounouno
On Friday, January 31, 2014 1:40:38 PM UTC+1, Stack Kororā wrote: > > Huh. I don't know why, but for some silly reason I thought I had to use > subclasses with arrows. I will re-work my script with them and see how it > goes. > Hi, I'll add that chaining arrows between single resources can quic

[Puppet Users] Re: Trouble with notify/require/before/subscribe

2014-01-31 Thread Stack Kororā
Greetings, Huh. I don't know why, but for some silly reason I thought I had to use subclasses with arrows. I will re-work my script with them and see how it goes. Thanks! I appreciate the suggestion. -- You received this message because you are subscribed to the Google Groups "Puppet Users"

[Puppet Users] Failed to generate additional resources using 'eval_generate': Error 403 on SERVER: Forbidden request access to

2014-01-31 Thread prasanna
Hi, I am newbie to pupet and It may looks like existing issue for everyone, but I am facing a strange issue that when I run the puppetmaster through apache/passenger, I am getting the error below. When i stop apache and start the puppetmasterd i am not facing any issue. I understood that pup

[Puppet Users] Re: Trouble with notify/require/before/subscribe

2014-01-31 Thread Luis León
I use arrows to specify the order without class, you could use: Package['a.i386']->Yumrepo ['RepoA']->Package ['a.x86_64']->File ['/etc/config_file_1] and so on... For example now I'm working with mongo and I use a single class with the previous dependence: Package['mongo-10gen-server-2. 2.6'

[Puppet Users] Re: Trouble with notify/require/before/subscribe

2014-01-31 Thread Luis León
I use arrows to specify the order without class, you could use: Package['a.i386']->Yumrepo ['RepoA']->Package ['a.x86_64']->File ['/etc/config_file_1] and so on... For example now I'm working with mongo and I use a single class with the previous dependence_ Package['mongo-10gen-server-2.2.6']

[Puppet Users] Re: Is there any other tool other than mcollective for orchestration..

2014-01-31 Thread Andreas Dvorak
Hi Derek, can you please explain who to build the Solaris package? Best regards Andreas Am Donnerstag, 7. Februar 2013 22:42:53 UTC+1 schrieb Derek Olsen: > > Rajeev. > > We run mcollective in a 100% Solaris shop. We have not encountered > any Solaris specific issues. Email me if you want t

Re: [Puppet Users] Puppet resources or plain script?

2014-01-31 Thread zerozerounouno
On Friday, January 31, 2014 11:30:53 AM UTC+1, Jose Luis Ledesma wrote: Without knowing exactly everything you do to deploy a new server, I would > suggest make use of templates to deploy these config files you modify with > seds... > Well, I'm not very skilled with templates yet, but wouldn't

[Puppet Users] Re: Using facts that don't exist yet...

2014-01-31 Thread Krist van Besien
On Friday, January 31, 2014 11:27:49 AM UTC+1, Daniele Sluijters wrote: > > Facts get sent at the start to the Puppet master so bringing an interface > online during a Puppet run won't make it available as a Fact during that > run, only on the next run as then the Facts are collected again. You

Re: [Puppet Users] Puppet resources or plain script?

2014-01-31 Thread José Luis Ledesma
Hi, Without knowing exactly everything you do to deploy a new server, I would suggest make use of templates to deploy these config files you modify with seds... Regards El 31/01/2014 11:09, escribió: > Hi, > I'm going to use Puppet to replace a long manual process which involves > lots of ste

[Puppet Users] Re: Using facts that don't exist yet...

2014-01-31 Thread Daniele Sluijters
Facts get sent at the start to the Puppet master so bringing an interface online during a Puppet run won't make it available as a Fact during that run, only on the next run as then the Facts are collected again. Your best bet is to make it conditional, check for the existence of the Fact and onl

[Puppet Users] Puppet resources or plain script?

2014-01-31 Thread zerozerounouno
Hi, I'm going to use Puppet to replace a long manual process which involves lots of steps mostly like installing packages, copying configuration files, and also doing many string replacements with sed and line additions inside those configuration files. All on CentOS. I was wondering whether tr

Re: [Puppet Users] Using facts that don't exist yet...

2014-01-31 Thread José Luis Ledesma
I don't know which is the best solution, what I do is: if $::factX != undef { } Regards El 31/01/2014 09:57, "Krist van Besien" escribió: > > Hello, > > I run puppet with foreman, and want to do the following: > > > - Initalize a network interface > - Start a service, bound to that inter

[Puppet Users] Using facts that don't exist yet...

2014-01-31 Thread Krist van Besien
Hello, I run puppet with foreman, and want to do the following: - Initalize a network interface - Start a service, bound to that interface. eg: #Start an interface for vlan 301 on interface em1 network::if::dynamic { 'em1.301': ensure => up, } #Start an openstack L2 agent cl