Re: [Puppet Users] Re: Roles/profiles and hiera

2014-03-27 Thread Ramin K
	Thanks and I'm glad it helped point you in the right direction. Here 
are two more (from me at least) to add to your collection on 
role/profile and Hiera. And yes I feel your oversimplified example pain. 
It's very unhelpful though Puppet is better than most projects.


https://ask.puppetlabs.com/question/5235/what-goes-in-the-profile-part-of-roleprofile/
https://ask.puppetlabs.com/question/3146/how-to-build-a-proper-hiera-hierarchy/

	What goes in profile? is the basis of my proposed Puppet Conf talk. 
With any luck that will be accepted and force me to spend the 40+ hours 
getting it out of my head and into a coherent presentation. Now I'm 
thinking I should have called it "If you're not embarrassed of your 
profile:: manifests you're doing it wrong!"


	I agree that documentation is lacking, but there are some mitigating 
circumstances. Parameterized classes, Hiera, role/profile, and automatic 
lookup of parameters in Hiera only recently arrived on the scene. 
Without all parts and some community consensus the way forward was still 
unclear in my opinion. And I say that as someone who went down every 
blind alley from 0.24 on. As always good ideas usually appear obvious in 
hindsight.
	On the flip side I was surprised with just how little reference to 
role/profile there was on *.puppetlabs.com. You might consider opening a 
Documentation bug to create a Role/Profile doc or at least collection of 
the 20-30 external links that most people refer to in one place.


Ramin

On 3/27/2014 7:07 PM, Mike Lehner wrote:

I can't begin to describe how helpful it is to read this. I also started
down the same path using a profile::base. A slightly different setup
where all other profiles inherited from ::profile::base. Luckily,
shortly after going down this path I ran into a major roadblock (better
now than 9 months in) when I tried to override a value from
profile::base in another profile. Can't really be done. Puppet Support
also pointed me in a similar direction as Ramin using custom facts.

I really wish there was more guidance on this from Puppetlabs. When
reading through learning sites and documentation, the first thing you
read is that Roles/Profiles are the be all end all. Then you find out
you actually don't want ANY data in code. So you have to go rewrite your
all your profiles you already wrote, to work with hiera. In my opinion,
the lack of guidance in this area is the single biggest barrier to
deploying Puppet. Actually writing the code is fairly easy. The issue is
finding the best place to organize the code. Most of the examples from
Puppetlabs (or the blogs written by puppet employees before they were)
are over-simplified and tend to lead down a path that's a dead-end. I'm
not a professional developer, I'm a sysadmin simply trying to puppetize
my infrastructure. There is a lot of work to be done in clearing this up
for those of us who don't develop for a living. In my honest opinion.

On Friday, August 30, 2013 6:48:37 PM UTC-4, Frederiko Costa wrote:

Hi everyone,

Do you guys know any article/doc talking about the use of
roles/profiles approach with hiera?

I'm particularly interested in how to organize the manifests when
having multiple data centers, parametized classes and wants to use
hiera.

Being even more specific, how to organize the code using the Craig's
article (http://www.craigdunn.org/2012/05/239/
) and use hiera to  provide
node specific data.

thank you,
-fred

--
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 puppet-users+unsubscr...@googlegroups.com
.
To view this discussion on the web visit
https://groups.google.com/d/msgid/puppet-users/ca33d5be-5f90-4c90-afd1-1dd154699516%40googlegroups.com
.
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/533507EB.3030303%40badapple.net.
For more options, visit https://groups.google.com/d/optout.


[Puppet Users] Trigger re-reading of facts?

2014-03-27 Thread Jason Price
Problem: Puppet pushes two files, and two services.  One service (redis)
reads one of the files (a lua script), and spits out a sha1sum.  However,
it somehow transforms the file before it produces the sha1sum, so there's
no way to know what the sum will be, before the reading.

File two (read by service two) must know what the sha1sum if the first file
is.

Semi-obvious solution: make external fact to read in the file, and produce
the sha1sum as a fact readable by puppet.  Use said fact in the template
for file2, and you're done.

However, the facts are generated before any files are changed via puppet.
And I hate having to run puppet twice to converge on a correct setup.

Is there a way for the manifest to do:

file { 'script.lua' :
  ensure => 'present',
  ...
  source => 'puppet:///modules/foo/script.lua'
}
->
INSERT MAGIC REREAD FACTS BLOCK
->
file { 'file2' :
  ensure => 'present',
  ...
  template => template('foo/file2.erb')
}

?

Thanks for any help.
Jason

-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/CAChvjRD%3DTtCdgBGqp2en0OJsBWyfJ0xQhrf6UcrPXTUumMbDew%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Puppet Users] Help with dependancy cycle

2014-03-27 Thread Adam Clark
I am trying to use this with the modules from forgestack, which only have
mysql providers.

Might be easier to just use the puppet-mariadb module and write a new
provider into all the various openstack modules.

Regardless, would be great to get an answer for when this stuff happens in
the future.

Cheers

Adam



On Fri, Mar 28, 2014 at 2:10 PM, Xav Paice  wrote:

>  On 28/03/14 15:31, Adam Clark wrote:
>
> Hi all,
>   I am writing a module to manage MySQL/MariaDB with Galera extensions and
> have run into a problem I don't seem to be able to figure out.
>
>  Error: Could not apply complete catalog: Found 1 dependency cycle:
> (File[/etc/mysql/conf.d/wsrep.cnf] => Service[mysqld] =>
> Class[Mysql::Server] => Class[Mysql::Config] => File[/etc/mysql/conf.d] =>
> File[/etc/mysql/conf.d/wsrep.cnf])
> Cycle graph written to /var/lib/puppet/state/graphs/cycles.dot.
>
>
>  Hi,
>
> I usually find a cup of coffee and a walk round the block sorts that kind
> of issue out - but it also usually involves a bit of drastic re-thinking
> and a large whiteboard picture ;(.
>
> You might find https://github.com/xavpaice/puppet-mariadb helpful - it's
> a bit of work I nabbed from NeCTAR and added bits to, but it's quite out of
> date now.
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Puppet Users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/puppet-users/PBYkTZQ3oUY/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> puppet-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/puppet-users/5334E836.3060309%40gmail.com
> .
>
> 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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/CAJm3wwAzx%2B1hOqCDfezik8C6O8kuBQEHgS2%3DE9f1s2wCbVQqGw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Puppet Users] Help with dependancy cycle

2014-03-27 Thread Xav Paice
On 28/03/14 15:31, Adam Clark wrote:
> Hi all,
>   I am writing a module to manage MySQL/MariaDB with Galera extensions
> and have run into a problem I don't seem to be able to figure out.
>
> Error: Could not apply complete catalog: Found 1 dependency cycle:
> (File[/etc/mysql/conf.d/wsrep.cnf] => Service[mysqld] =>
> Class[Mysql::Server] => Class[Mysql::Config] =>
> File[/etc/mysql/conf.d] => File[/etc/mysql/conf.d/wsrep.cnf])
> Cycle graph written to /var/lib/puppet/state/graphs/cycles.dot.
>
>
Hi,

I usually find a cup of coffee and a walk round the block sorts that
kind of issue out - but it also usually involves a bit of drastic
re-thinking and a large whiteboard picture ;(.

You might find https://github.com/xavpaice/puppet-mariadb helpful - it's
a bit of work I nabbed from NeCTAR and added bits to, but it's quite out
of date now.

-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/5334E836.3060309%40gmail.com.
For more options, visit https://groups.google.com/d/optout.


[Puppet Users] Re: Roles/profiles and hiera

2014-03-27 Thread Mike Lehner
I can't begin to describe how helpful it is to read this. I also started 
down the same path using a profile::base. A slightly different setup where 
all other profiles inherited from ::profile::base. Luckily, shortly after 
going down this path I ran into a major roadblock (better now than 9 months 
in) when I tried to override a value from profile::base in another profile. 
Can't really be done. Puppet Support also pointed me in a similar direction 
as Ramin using custom facts. 

I really wish there was more guidance on this from Puppetlabs. When reading 
through learning sites and documentation, the first thing you read is that 
Roles/Profiles are the be all end all. Then you find out you actually don't 
want ANY data in code. So you have to go rewrite your all your profiles you 
already wrote, to work with hiera. In my opinion, the lack of guidance in 
this area is the single biggest barrier to deploying Puppet. Actually 
writing the code is fairly easy. The issue is finding the best place to 
organize the code. Most of the examples from Puppetlabs (or the blogs 
written by puppet employees before they were) are over-simplified and tend 
to lead down a path that's a dead-end. I'm not a professional developer, 
I'm a sysadmin simply trying to puppetize my infrastructure. There is a lot 
of work to be done in clearing this up for those of us who don't develop 
for a living. In my honest opinion.

On Friday, August 30, 2013 6:48:37 PM UTC-4, Frederiko Costa wrote:
>
> Hi everyone,
>
> Do you guys know any article/doc talking about the use of roles/profiles 
> approach with hiera?
>
> I'm particularly interested in how to organize the manifests when having 
> multiple data centers, parametized classes and wants to use hiera. 
>
> Being even more specific, how to organize the code using the Craig's 
> article (http://www.craigdunn.org/2012/05/239/) and use hiera to  provide 
> node specific data.
>
> thank you,
> -fred
>
>  

-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/ca33d5be-5f90-4c90-afd1-1dd154699516%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Puppet Users] Help with dependancy cycle

2014-03-27 Thread Adam Clark
Hi all,
  I am writing a module to manage MySQL/MariaDB with Galera extensions and 
have run into a problem I don't seem to be able to figure out.

Error: Could not apply complete catalog: Found 1 dependency cycle:
(File[/etc/mysql/conf.d/wsrep.cnf] => Service[mysqld] => 
Class[Mysql::Server] => Class[Mysql::Config] => File[/etc/mysql/conf.d] => 
File[/etc/mysql/conf.d/wsrep.cnf])
Cycle graph written to /var/lib/puppet/state/graphs/cycles.dot.

A cut down version of my puppet file is:
class galera::server (
 #
) inherits mysql {

  #

  class { 'mysql::server':
config_hash  => $config_hash,
package_name => $server_package_name,
service_name => $service_name,
  }

  #

  file { '/etc/mysql/conf.d/wsrep.cnf' :
ensure  => present,
mode=> '0644',
owner   => 'root',
group   => $root_group,
content => template('galera/wsrep.cnf.erb'),
#require => File['/etc/mysql/conf.d/'],
notify  => Service['mysqld']
  }
}

I am using the current puppetlabs-mysql (v0.9.0) from puppet forge.
https://github.com/puppetlabs/puppetlabs-mysql/tree/master/manifests

I need the file to go in after the /etc/mysql/conf.d/ resource is complete, 
but before the service is started. 

The /etc/mysql/conf.d/ resource is listed in mysql::config as:
class mysql::config(
  # 
  $purge_conf_dir   = $mysql::purge_conf_dir,
) inherits mysql {
  

  file { '/etc/mysql/conf.d':
ensure  => directory,
mode=> '0755',
recurse => $purge_conf_dir,
purge   => $purge_conf_dir,
  }
}

class mysql(
  #
  $purge_conf_dir= $mysql::params::purge_conf_dir,
  #
) {
  #
}

class mysql::params {
 # 
  $purge_conf_dir  = false 
 #
}

Does it have something to do with the recurse/purge metaparameters?  The 
defaults seem to be set as false.

Full puppet file attached and dot file from --graph.

Any light into this would be great.

Adam

-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/3626bd7a-bfd2-4a78-b1d0-63a0465ff44d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


cycles.dot
Description: MS-Word document


server.pp
Description: Binary data


Re: [Puppet Users] Re: Final Comments on Pro Puppet 2nd Edition

2014-03-27 Thread Spencer Krum
Hi,

I am one of the authors of Pro Puppet. I have asked the Apress
administrators to link to
https://github.com/pro-puppet/pro-puppet-erratafrom the Apress errata
section. I'm sure that will appear eventually. I
invite all community members to contribute directly to this project or to
email us with any feedback, positive or negative about the book or its
content.

Jon,

Thank you for your attentive reading and comments. I don't agree with all
of your feedback, but that's to be expected. I'll be pushing up the rest of
your chapter notes and notes from others as soon as I find a hole in my
schedule.

Thanks,
Spencer


On Thu, Mar 27, 2014 at 10:47 PM, Jon Forrest  wrote:

>
>
> On Thu, Mar 27, 2014 at 3:02 PM, Daniele Sluijters
>  wrote:
> > Hi,
> >
> > I'm going to be slightly blunt here.
>
> That's fair.
>
>
> > The authors of the book have, repeatedly, ask you to connect with them
> through different channels and
> > contribute your fixes to the Github repository that was set up.
>
> One author asked me once. I've never heard from any of the other authors.
>
> Furthermore, as of today, Apress *still* doesn't show anything on
> their Errata page for the book. That's the first place where issues should
> show up.
>
>
> >Though I appreciate your review of the book, the way you've handled the
> situation is
> > not exactly exemplary.
>
> I obviously don't agree. I'm doing this editing for free, on my own
> time. I don't make any money from doing it. Helping the authors, who are
> making money
> from the book (which is entirely fine), doesn't seem like an exemplary way
> to handle the situation either. The list of issues is freely available
> for them, or anybody
> else, to do whatever they want with, including putting them on GitHub.
>
> Let's say I had chosen to work with the authors. What difference would that
> have made?
>
>
> > I'm also wondering what you're trying to achieve here. I'm sure you
> realise
> > that most people won't be reading your posts on the mailing lists before
> > buying the book.
>
> Maybe not, but I hope I've helped those that do.
>
> Other than listing the issues with the book, I'm not trying to achieve
> anything.
> I'm not a Puppet expert so I'm not promoting a Puppet consulting business.
> These days I don't work as an editor so I'm not trying to get editing work.
>
>
> > From reading your comments most of them are not about
> > errors with regard to Puppet but with (perceived) errors in grammar,
> style
> > or formatting.
>
> Exactly right. This is a point I've made several times. But these are
> exactly the kind of errors that the publisher had the responsibility
> to fix. They didn't. When I buy a book with these kinds of problems
> I feel ripped off, especially since it's not that hard to do right.
> It's the technical stuff about Puppet that's hard.
>
> I just got a copy of the latest version of Patterson and Hennesy's
> Computer Architecture book. That's an example of how a book should
> be edited.
>
>
> > Only a few are actually about code or command errors and a
> > few about terminology that's used before it's been explained or other
> issues
> > that could potentially hamper the users understanding.
>
> Right again. I even went to the trouble of clearly labeling the issues I
> found so that people who don't care about typos, grammar, style, or
> formatting can ignore all that and only look at the true errors.
>
> I knew that not everyone would be interested in what I found. That's
> why I clearly labeled my postings so that people who didn't care about
> issues in the book could ignore what I said.
>
> What would you have done?
>
> Jon Forrest
>
>  --
> 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 puppet-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/puppet-users/b0fd3dff-f8de-4b00-aa1a-dd76b16e85aa%40googlegroups.com
> .
>
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Spencer Krum
(619)-980-7820

-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/CADt6FWNVf_gcchGsDomCgx%2BFwL8BpmJ%2BLZPyLQu3dHRvi0edMQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


[Puppet Users] Re: Final Comments on Pro Puppet 2nd Edition

2014-03-27 Thread Jon Forrest


On Thu, Mar 27, 2014 at 3:02 PM, Daniele Sluijters
 wrote:
> Hi,
>
> I'm going to be slightly blunt here.

That's fair.

> The authors of the book have, repeatedly, ask you to connect with them 
through different channels and
> contribute your fixes to the Github repository that was set up.

One author asked me once. I've never heard from any of the other authors.

Furthermore, as of today, Apress *still* doesn't show anything on
their Errata page for the book. That's the first place where issues should 
show up.

>Though I appreciate your review of the book, the way you've handled the 
situation is
> not exactly exemplary.

I obviously don't agree. I'm doing this editing for free, on my own
time. I don't make any money from doing it. Helping the authors, who are 
making money
from the book (which is entirely fine), doesn't seem like an exemplary way
to handle the situation either. The list of issues is freely available
for them, or anybody
else, to do whatever they want with, including putting them on GitHub.

Let's say I had chosen to work with the authors. What difference would that
have made?

> I'm also wondering what you're trying to achieve here. I'm sure you 
realise
> that most people won't be reading your posts on the mailing lists before
> buying the book.

Maybe not, but I hope I've helped those that do.

Other than listing the issues with the book, I'm not trying to achieve 
anything.
I'm not a Puppet expert so I'm not promoting a Puppet consulting business.
These days I don't work as an editor so I'm not trying to get editing work.

> From reading your comments most of them are not about
> errors with regard to Puppet but with (perceived) errors in grammar, style
> or formatting.

Exactly right. This is a point I've made several times. But these are
exactly the kind of errors that the publisher had the responsibility
to fix. They didn't. When I buy a book with these kinds of problems
I feel ripped off, especially since it's not that hard to do right.
It's the technical stuff about Puppet that's hard.

I just got a copy of the latest version of Patterson and Hennesy's
Computer Architecture book. That's an example of how a book should
be edited.

> Only a few are actually about code or command errors and a
> few about terminology that's used before it's been explained or other 
issues
> that could potentially hamper the users understanding.

Right again. I even went to the trouble of clearly labeling the issues I
found so that people who don't care about typos, grammar, style, or
formatting can ignore all that and only look at the true errors.

I knew that not everyone would be interested in what I found. That's
why I clearly labeled my postings so that people who didn't care about
issues in the book could ignore what I said.

What would you have done?

Jon Forrest

-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/b0fd3dff-f8de-4b00-aa1a-dd76b16e85aa%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Puppet Users] Re: Final Comments on Pro Puppet 2nd Edition

2014-03-27 Thread Daniele Sluijters
Hi,

I'm going to be slightly blunt here. The authors of the book have, 
repeatedly, ask you to connect with them through different channels and 
contribute your fixes to the Github repository that was set up. Though I 
appreciate your review of the book, the way you've handled the situation is 
not exactly exemplary.

I'm also wondering what you're trying to achieve here. I'm sure you realise 
that most people won't be reading your posts on the mailing lists before 
buying the book. From reading your comments most of them are not about 
errors with regard to Puppet but with (perceived) errors in grammar, style 
or formatting. Only a few are actually about code or command errors and a 
few about terminology that's used before it's been explained or other 
issues that could potentially hamper the users understanding.

-- 
Daniele Sluijters

On Thursday, 27 March 2014 05:17:40 UTC+1, Jon Forrest wrote:
>
> I just posted my list of issues I discovered in Chapters 11 
> and 12 - the last two chapters of Pro Puppet 2nd Edition. 
>
> I found a lot of issues with this book. I simply don't 
> understand how these issues escaped the editors. One reason 
> I posted what I did is so that anyone thinking about buying 
> the book will know what to expect. 
>
> I just hope the technical material about Puppet was higher 
> quality than the editing job that went into this book. Since 
> I'm not a Puppet expert I have no way of judging, so I won't 
> comment. 
>
> I've posted the complete list of issues on 
> https://www.dropbox.com/s/qmcdgdo4bvq620q/propuppet2.txt 
>
> Jon Forrest 
>

-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/65be6841-340e-434e-ad6f-5e2798fae87e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Puppet Users] [SOLVED] Re: Error: Could not send report: Error 400 on SERVER: Could not intern from pson: undefined method `intern' for nil:NilClass

2014-03-27 Thread Race Boyer
I have found the issue, its with the stdlib module both version 3.2.1 and 
4.x with puppet 2.6.18 and facter 1.5.2.1 on SLES 11.x. I tried both 
versions and removed them both and got normal function back to puppet 3.4.3 
after they were removed. Only took 3 days of troubleshooting but the 
good part is that I was able to fully setup a functioning puppet-dashboard! 
(because I thought it was a foreman 1.4 issue) 
SLES can be such a pain the buttocks.

On Friday, March 21, 2014 1:21:09 PM UTC-5, Race Boyer wrote:
>
> This is driving me mad.
> I get this error on two OpenSuse 12.3 nodes
> puppet-3.0.2-2.9.1.x86_64
> facter-1.6.17-2.1.1.x86_64
>
> I ran this command:
> *sudo puppet agent -t --verbose --noop --debug --trace *
>
> *and I get this ouput:*
> Info: Retrieving plugin
> Debug: file_metadata supports formats: b64_zlib_yaml pson raw yaml; using 
> pson
> Debug: Finishing transaction 19305160
> Info: Loading facts in /var/lib/puppet/lib/facter/ip6tables_version.rb
> Info: Loading facts in 
> /var/lib/puppet/lib/facter/iptables_persistent_version.rb
> Info: Loading facts in /var/lib/puppet/lib/facter/iptables_version.rb
> Info: Loading facts in /var/lib/puppet/lib/facter/facter_dot_d.rb
> Info: Loading facts in /var/lib/puppet/lib/facter/root_home.rb
> Info: Loading facts in /var/lib/puppet/lib/facter/puppet_vardir.rb
> Info: Loading facts in /var/lib/puppet/lib/facter/pe_version.rb
> Debug: catalog supports formats: b64_zlib_yaml dot pson raw yaml; using 
> pson
> Info: Caching catalog for svteustst02.hco.hc.hctx.net
> Debug: Creating default schedules
> Debug: Loaded state in 0.00 seconds
> Info: Applying configuration version '1395341101'
> Debug: /Schedule[daily]: Skipping device resources because running on a 
> host
> Debug: /Schedule[monthly]: Skipping device resources because running on a 
> host
> Debug: /Schedule[hourly]: Skipping device resources because running on a 
> host
> Debug: /Schedule[never]: Skipping device resources because running on a 
> host
> Debug: /Schedule[weekly]: Skipping device resources because running on a 
> host
> Debug: /Schedule[puppet]: Skipping device resources because running on a 
> host
> Debug: Finishing transaction 18621940
> Debug: Storing state
> Debug: Stored state in 0.02 seconds
> Notice: Finished catalog run in 0.09 seconds
> Debug: report supports formats: b64_zlib_yaml pson raw yaml; using pson
> Debug: report supports formats: b64_zlib_yaml pson raw yaml; using pson
> Debug: report supports formats: b64_zlib_yaml pson raw yaml; using pson
> *Error: Could not send report: Error 400 on SERVER: Could not intern from 
> pson: undefined method `intern' for nil:NilClass*
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/indirector/rest.rb:177:in 
> `is_http_200?'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/indirector/rest.rb:145:in `save'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/indirector/indirection.rb:266:in 
> `save'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/configurer.rb:200:in `send_report'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/configurer.rb:194:in `run'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/agent.rb:45:in `block (5 levels) 
> in run'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/agent/locker.rb:20:in `lock'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/agent.rb:45:in `block (4 levels) 
> in run'
> /usr/lib64/ruby/1.9.1/sync.rb:227:in `sync_synchronize'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/agent.rb:45:in `block (3 levels) 
> in run'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/agent.rb:119:in `with_client'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/agent.rb:42:in `block (2 levels) 
> in run'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/agent.rb:84:in `run_in_fork'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/agent.rb:41:in `block in run'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/application.rb:175:in `call'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/application.rb:175:in 
> `controlled_run'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/agent.rb:39:in `run'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/application/agent.rb:338:in 
> `onetime'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/application/agent.rb:312:in 
> `run_command'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/application.rb:346:in `block (2 
> levels) in run'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/application.rb:438:in 
> `plugin_hook'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/application.rb:346:in `block in 
> run'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/util.rb:496:in `exit_on_fail'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/application.rb:346:in `run'
> /usr/lib64/ruby/vendor_ruby/1.9.1/puppet/util/command_line.rb:87:in 
> `execute'
> /usr/bin/puppet:4:in `'
>
>
> I'm sure its on the server, but I'm not exactly sure where to look because 
> i get the same error in the server logs. I checked the firewall and it goes 
> through, I don't know enough arout ruby to hunt down a pson error, but what 
> what it looks like there is a syntax error somewhere? Anyone have any ideas?
>
>

-- 

[Puppet Users] PuppetDB 1.6.3 final now available

2014-03-27 Thread Ken Barber
PuppetDB 1.6.3 final - March 27th, 2014.

PuppetDB 1.6.3 Downloads


Available in native package format in the release repositories at:
http://yum.puppetlabs.com and http://apt.puppetlabs.com

For information on how to enable the Puppet Labs repos, see:
http://docs.puppetlabs.com/guides/puppetlabs_package_repositories.html#open-source-repositories

Binary tarball: http://downloads.puppetlabs.com/puppetdb/

Source: http://github.com/puppetlabs/puppetdb

Please report feedback via the Puppet Labs tickets site, using an
affected PuppetDB version of 1.6.3:
https://tickets.puppetlabs.com/browse/PDB

Documentation: http://docs.puppetlabs.com/puppetdb/1.6

Puppet module:
http://forge.puppetlabs.com/puppetlabs/puppetdb

PuppetDB 1.6.3 Release Notes


PuppetDB 1.6.3 is a bugfix release.

Things to take note of before upgrading:

* (PDB-510) Add migration to fix sequence for catalog.id

  The sequence for catalog.id had not been incremented during insert
for migration
  20 'differential-catalog-resources'.

  This meant that the catalog.id column would throw a constraint
exception during
  insertion until the sequence had increased enough to be greater then
the max id
  already used in the column.

  While this was only a temporary error, it does cause puppetdb to
start to throw
  errors and potentially dropping some catalog updates until a certain number of
  catalogs had been attempted. In some cases catalogs had been queued up and
  retried successfully, other cases meant they were simply dropped into the DLQ.

  The fix is to reset the sequence to match the max id on the
catalogs.id column.

* RHEL 7 beta packages are now included

* (PDB-343) Fedora 18 packages are no longer to be built

* (PDB-468) Update CLI tools to use correct JAVA_BIN and JAVA_ARGS

  Some tools such as `puppetdb import|export` and `puppetdb
foreground` where not
  honouring the JAVA_BIN defined in /etc/default|sysconfig/puppetdb.

* (PDB-437) Reduce API source code and version inconsistencies

  The API code when split between different versions created an opportunity for
  inconsistencies to grow. For example, some versioning inside the
code supported
  this file based way of abstracting versions, but other functions required
  version specific handling.

  This patch solidifies the version handling to ensure we reduce in regressions
  relating to different versions of the query API and different
operator handling.

* Use v3 end-point for import and benchmark tools

* (PDB-80)(packaging) Fixup logic in defaults file for java on EL

* (PDB-463) Fix assertion error in /v1/resources

* (PDB-238) Some code reduction work related to simplifying future
query API version removal

* (PDB-446) Start in on the merge of v2 and v3 test namespaces for testing

* (PDB-435) Travis no longer has bundler installed by default, now
installing it explicitly

* (PDB-437) Clojure lint cleanups

* Change tutorial and curl documentation examples to use v3 API

* Added examples to documentation for latest-report? and file

PuppetDB 1.6.3 Contributors
---

Aric Gardner, Chris Price, Deepak Giridharagopal, Ken Barber, Matthaus
Owens, Moses Mendoza, Rob Braden, Ryan McKern, Ryan Senior

PuppetDB 1.6.3 Changlog
---

Aric Gardner (1):
  f55c349 Added example for latest-report? and file

Chris Price (1):
  37928e2 Don't use global schema validation

Ken Barber (18):
  27e53b9 PDB-437 Reduce API source code and version inconsistencies
  92d0e26 PDB-437 Clojure lint cleanups
  2eff902 PDB-234 Cleanup some minor code duplication and missing
versions from case
  7a5ed7c Change tutorial examples to use v3 API
  c4fb8fe Switch curl examples to v3 also
  59bce95 PDB-342 Use our own JDK repo for JDK 7 testing
  ff62272 PDB-342 Fix order precedence issue with boolean logic
for use_our_jdk test
  a0d0cc3 PDB-342 Ensure we use the correct GPG key for the JDK repo
  981a457 Remove redmine links
  1231d78 PDB-463 Fix assertion error in /v1/resources
  8b39fa5 PDB-463 Add back missing query-resources
  bda3953 Use v3 end-point for import and benchmark tools
  6e09f22 Unpin beaker now that 1.7.0 is released
  b7eccd8 PDB-510 Add migration to fix sequence for catalog.id
  e335bbb PDB-510 Add explicit locking and move fix-identity-sequence
  772bc64 Pin Rake for Ruby 1.8.7
  174f5be PDB-549 Release notes for 1.6.3
  daaeaf9 PDB-549 Some release note cleanups for 1.6.3

Moses Mendoza (6):
  43b030b (packaging) Update top-level Rakefile's version and pe
determination
  eb6a936 (packaging) Update template task for new erb_file method
  8f5b484 (packaging) Fully qualify variables supplied by the
packaging repo in templates
  1513b66 (packaging) set project to pe-puppetdb when building pe-puppetdb
  168bea7 (packaging) Evaluate rpm spec file just like debian templates
  44f7591 (packaging) Rep

[Puppet Users] 403 You don't have permission to access /production/... after switching from puppemaster to passenger

2014-03-27 Thread bjoern pohl
Hi,
since puppet should be used for more clients here, I moved from the 
puppetmaster daemon to a passenger setup (as described on various websites)

Problem is that I am facing the following errors while accessing the REST 
API: (possibly this will hit me with normal clients, too..)
403 You don't have permission to access 
/production/certificate_statuses/no_key on this server.

What I checked up to now:
Puppet CA has the same ownerships as *config.ru* of the Rack Server, 
 "puppet:puppet". So Passenger runs that stuff as the puppet user.

changing config.ru to root for testing made no difference.

Apache Logs only gave me the 403 above, even with extended logging.

Any Idea what this could be or how I can get better debug information what 
passenger does not like here ? ( PassengerLog is currently pointing to the 
webserver logs, but does not tell me anything...)


thanks & best regards,
Björn



-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/3dc7dac0-e0cc-41dc-a3ef-f5282253d7c6%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Puppet Users] Re: external facts are not updated

2014-03-27 Thread yannig rousseau
Hello,
I couldn't find any traces explaining this behaviour.
What could be the difference between the process run manually and the one 
run by service ??

Regards

On Tuesday, March 25, 2014 5:41:12 PM UTC+1, yannig rousseau wrote:
>
> Hi all,
>
> I use external facts to collect data to our puppetmaster.
> When running the "facter" or the "puppet agent -t" command, the external 
> facts are correctly collected.
>
> But as soon as I let the puppet service run, the external facts are no 
> more gathered into inventory anymore
>
> I use puppet puppet-3.2.2 and facter-1.7.1 on a RHEL5.10
> The puppetmaster is puppet-server-3.3.2 on RHEL 6.5
>
> Does anyone have an idea ?
>
> Regards
> Yannig
>

-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/1d1856d6-8181-4e28-861d-67c83a8c0dfa%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Puppet Users] Final Comments on Pro Puppet 2nd Edition

2014-03-27 Thread Kurt Wall
I'll make the observation that it *is* possible to produce an
error-free printed product, but the cost to do so would easily double
or triple the cost of the title. The cost of proofing, plus the
smaller and captive market, is why quality textbooks are so
ridiculously expensive. And why mass market softback titles are not.

Kurt

On Wed, Mar 26, 2014 at 9:17 PM, Jon Forrest  wrote:
> I just posted my list of issues I discovered in Chapters 11
> and 12 - the last two chapters of Pro Puppet 2nd Edition.
>
> I found a lot of issues with this book. I simply don't
> understand how these issues escaped the editors. One reason
> I posted what I did is so that anyone thinking about buying
> the book will know what to expect.
>
> I just hope the technical material about Puppet was higher
> quality than the editing job that went into this book. Since
> I'm not a Puppet expert I have no way of judging, so I won't
> comment.
>
> I've posted the complete list of issues on
> https://www.dropbox.com/s/qmcdgdo4bvq620q/propuppet2.txt
>
> Jon Forrest
>
> --
> 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 puppet-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/puppet-users/5333A664.7080707%40gmail.com.
> 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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/CADJx5NkiQ%3D2agNNmpT6%2BLqymXEnSpDdfUd_8JFXoUfJpNue2eA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Puppet Users] tagging nodes in site.pp (tagmail)

2014-03-27 Thread Martin Alfke
Hi

On 27 Mar 2014, at 16:00, cko  wrote:

> hi,
> 
> i want to be able to send reports via email for certain hosts. for example:
> 
> site.pp
> 
> node 'node1.localdomain' {
>tag 'webshop'
> }
> node 'node2.localdomain' {
>tag 'webshop'
> }
> node 'node3.localdomain' {
>tag 'foo''
> }

tag is a function.

you might want to use

tag('')

> 
> tagmail.conf
> 
> webshop: developers@company.domain
> 
> 
> So only the changes applied to node1 and node2 would be e-mailed to the 
> webshop team.
> 
> Is there a way to do this?

hth,

Martin

> 
> 
> 
> 
> 
> 
> -- 
> 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 puppet-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/puppet-users/290e57bc-4158-46a3-a85c-527ed1617c2d%40googlegroups.com.
> 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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/C21E5830-6652-4CEA-A306-8166E1B532C5%40gmail.com.
For more options, visit https://groups.google.com/d/optout.


[Puppet Users] tagging nodes in site.pp (tagmail)

2014-03-27 Thread cko
hi,

i want to be able to send reports via email for certain hosts. for example:

*site.pp*

node 'node1.localdomain' {
   tag 'webshop'
}
node 'node2.localdomain' {
   tag 'webshop'
}
node 'node3.localdomain' {
   tag 'foo''
}

*tagmail.conf*

webshop*:* developers@company.domain


So only the changes applied to node1 and node2 would be e-mailed to the 
webshop team.

Is there a way to do this?





-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/290e57bc-4158-46a3-a85c-527ed1617c2d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Puppet Users] error in puppet certificate signing

2014-03-27 Thread David Schmitt

On 2014-03-27 11:08, Ankita kumari wrote:

Hi,

I am new to puppet. I have installed puppet agent and puppet master 
on

two different centos. For starting communication between client and
server I am sending request from client. This certificate is signed 
my

master. But on client it is giving this error

Info: Caching certificate for puppetagentappd.eng.vmware.com
Error: Could not request certificate: Server hostname
'puppetmasterappd.eng.vmware.com' did not match server certificate;
expected one of centos, DNS:centos, DNS:puppet



Your puppetmaster is calling itself "one of centos, DNS:centos, 
DNS:puppet", but you're expecting to talk to 
"puppetmasterappd.eng.vmware.com". Therefore your agent refuses to talk 
to this server.
Use the "certname" configuration directive or fix the hostname of the 
puppetmaster to generate and use certificates matching the required 
hostnames.


Regards, David

--
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/71a12f0c7e40d05ffadd13e55710ca29%40hosting.edv-bus.at.
For more options, visit https://groups.google.com/d/optout.


[Puppet Users] Foreman + katello to manage puppet

2014-03-27 Thread Unix SA
Hello Guys,

anyone is using foreman + katello to manage puppet modules ?? ..

if yes, can you help me with Design, we want to setup multimaster puppet
env.. i know we can create multiple foreman-proxy and acheiv it but not
sure how i will assign multiple puppet master and manage module and puppet
classes in foreman UI ..

also any suggestion to manage diff puppet ENVs using GIT ?

appreciate some design stuffs ..

Regards,
DJ

-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/CACDG_KeBc4BNp0UkFrAnXFShWsVzYecSDkfdp6vzNDin8TPgfw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


[Puppet Users] Re: How to handle multiple modules requiring the same packages

2014-03-27 Thread och ach
same problem here. just find that razor module has static def of package 
curl.
what is the best practice?

for now i have deleted the definition from module and included my virtual 
packages definitions but would love to solve it not dirty fix it

On Saturday, 21 January 2012 15:02:27 UTC+1, bel wrote:
>
> I find it confusing that Puppet defines modules as reusable code yet, 
> when it comes to packages, you have to have prior knowledge of what 
> other package resources are defined. 
>
> Thank you for all the proposed solutions but does anyone know if 
> Puppet has a best practice they recommend in this case? Otherwise, I'm 
> going with defining new classes for the packages. 
>
> On Jan 17, 4:11 am, Steve Shipway  wrote: 
> > You can make the package resource definition conditional. 
> > 
> > class foo { 
> >  if ! defined( Package[gcc] ) { 
> >   package { gcc: ensure=>installed; } 
> >  }} 
> > 
> > class bar { 
> >  if ! defined( Package[gcc] ) { 
> >   package { gcc: ensure=>installed; } 
> >  } 
> > 
> > } 
> > 
> > Or, define a new class for the package(s) and include that 
> > 
> > class pkg::gcc { 
> >   package { gcc: ensure=>installed; }} 
> > 
> > class foo { 
> > include pkg::gcc} 
> > 
> > class bar { 
> > include pkg::gcc 
> > 
> > } 
> > 
> > Second method is more elegant IMHO; but if its a one-off then first 
> might be simpler. 
> > 
> > Steve 
> > 
> > Steve Shipway 
> > University of Auckland ITS 
> > UNIX Systems Design Lead 
> > s.ship...@auckland.ac.nz 
> > Ph: +64 9 373 7599 ext 86487

-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/df5d4469-4bd5-4f48-b7d4-a221aadc0edd%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Puppet Users] error in puppet certificate signing

2014-03-27 Thread Ankita kumari
Hi, 

I am new to puppet. I have installed puppet agent and puppet master on two 
different centos. For starting communication between client and server I am 
sending request from client. This certificate is signed my master. But on 
client it is giving this error

Info: Caching certificate for puppetagentappd.eng.vmware.com
Error: Could not request certificate: Server hostname 
'puppetmasterappd.eng.vmware.com' did not match server certificate; 
expected one of centos, DNS:centos, DNS:puppet

Please help me with this

-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/f9cba96e-2b10-4336-935d-a257dabc15a6%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Puppet Users] Re: i require a defined type which contains a file resource, but the file resource does not retain the relatioship

2014-03-27 Thread David Portabella
simpler example, showing the transivity in resource dependencies.
(as opposed to no transivity in class 
dependencies
 by 
default)

d3 {'test': }

define d1 {
  exec { exec1: command => '/bin/echo exec1; exit 1' }
}

define d2 {
  d1 {$name: }
}

define d3 {
  d2 {$name: }
  ->
  exec { exec3: command => '/bin/echo exec3; exit 1' }
}

$ puppet apply test.pp
Notice: /Stage[main]//D3[test]/D2[test]/D1[test]/Exec[exec1]/returns: exec1
Error: /bin/echo exec1; exit 1 returned 1 instead of one of [0]
Error: /Stage[main]//D3[test]/D2[test]/D1[test]/Exec[exec1]/returns: change 
from notrun to 0 failed: /bin/echo exec1; exit 1 returned 1 instead of one 
of [0]
Notice: /Stage[main]//D3[test]/Exec[exec3]: Dependency Exec[exec1] has 
failures: true
Warning: /Stage[main]//D3[test]/Exec[exec3]: Skipping because of failed 
dependencies

-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/0ae75c3f-2391-42d0-bbe4-7a342085c188%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Puppet Users] puppet class dependencies

2014-03-27 Thread David Portabella
it seems there is a bug in puppet --graph, that misses some dependencies.
https://tickets.puppetlabs.com/browse/PUP-2075

so, this code actually works as expected:

class { c3: }

class c1 {
  exec { exec1: command => '/bin/echo exec1; exit 1' }
}

class c2 {
*  # include c1*
*  contain c1*
  exec { exec2: command => '/bin/echo exec2' }
}

class c3 {
  class { c2: }
  ->
  exec { exec3: command => '/bin/echo exec3; exit 1' }
}

puppet does not execute exec3 because exec1 failed (thanks to replacing include 
c1 by contain c1).

$ puppet apply test.pp Notice: /Stage[main]/C1/Exec[exec1]/returns: exec1
Error: /bin/echo exec1; exit 1 returned 1 instead of one of [0]
Error: /Stage[main]/C1/Exec[exec1]/returns: change from notrun to 0 failed: 
/bin/echo exec1; exit 1 returned 1 instead of one of [0]
Notice: /Stage[main]/C2/Exec[exec2]/returns: executed successfully
Notice: /Stage[main]/C3/Exec[exec3]: Dependency Exec[exec1] has failures: 
true
Warning: /Stage[main]/C3/Exec[exec3]: Skipping because of failed 
dependencies

-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/5f9bb9b3-403e-4e53-9ffb-3bbcee794ce0%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Puppet Users] Re: i require a defined type which contains a file resource, but the file resource does not retain the relatioship

2014-03-27 Thread David Portabella
d2 {'test': }
-> 
d3 {'test': }

define d1 {
  exec { exec1: command => '/bin/echo exec1; exit 1' }
}

define d2 {
  d1 {$name: }
  ->
  exec { exec2: command => '/bin/echo exec2; exit 1' }
}

define d3 {
  exec { exec3: command => '/bin/echo exec3; exit 1' }
}


and this also works as expected, even if puppet --graph does not show it.

$ puppet apply --graph cc.pp 
Notice: Compiled catalog for mac4c.local in environment production in 0.08 
seconds 
Notice: /Stage[main]//D2[test]/D1[test]/Exec[exec1]/returns: exec1 
Error: /bin/echo exec1; exit 1 returned 1 instead of one of [0] 
Error: /Stage[main]//D2[test]/D1[test]/Exec[exec1]/returns: change from 
notrun to 0 failed: /bin/echo exec1; exit 1 returned 1 instead of one of 
[0] 
Notice: /Stage[main]//D2[test]/Exec[exec2]: Dependency Exec[exec1] has 
failures: true 
Warning: /Stage[main]//D2[test]/Exec[exec2]: Skipping because of failed 
dependencies 
Notice: /Stage[main]//D3[test]/Exec[exec3]: Dependency Exec[exec1] has 
failures: true 
Warning: /Stage[main]//D3[test]/Exec[exec3]: Skipping because of failed 
dependencies 
Notice: Finished catalog run in 0.14 seconds

$ open -a GraphViz /Users/david/.puppet/var/state/graphs/relationships.dot 

no relation between exec1, exec2 and/or exec3.


On Thursday, March 27, 2014 11:11:02 AM UTC+1, David Portabella wrote:
>
> I've open a bug ticket:
> puppet --graph misses some dependencies
> https://tickets.puppetlabs.com/browse/PUP-2075
>
>
> d1 {'test': }
> -> 
> d2 {'test': }
>
> define d1 {
>   exec { exec1: command => '/bin/echo exec1; exit 1' }
> }
>
> define d2 {
>   exec { exec2: command => '/bin/echo exec2; exit 1' }
> }
>
> ---
> $ puppet apply --graph test.pp 
>
> the graph does not show any dependency between exec1 and exec2.
>
> However the dependency does exists, as puppet does nor execute exec2 
> because of "failed dependencies":
>
> $ puppet apply --graph dd.pp 
> Notice: Compiled catalog for mac4c.local in environment production in 0.08 
> seconds
> Notice: /Stage[main]//D1[test]/Exec[exec1]/returns: exec1
> Error: /bin/echo exec1; exit 1 returned 1 instead of one of [0]
> Error: /Stage[main]//D1[test]/Exec[exec1]/returns: change from notrun to 0 
> failed: /bin/echo exec1; exit 1 returned 1 instead of one of [0]
> Notice: /Stage[main]//D2[test]/Exec[exec2]: Dependency Exec[exec1] has 
> failures: true
> Warning: /Stage[main]//D2[test]/Exec[exec2]: Skipping because of failed 
> dependencies
> Notice: Finished catalog run in 0.11 seconds
>
>
> So, it seems that there is a bug in puppet --graph.
>
>
>
> On Wednesday, March 19, 2014 9:51:08 PM UTC+1, jcbollinger wrote:
>>
>>
>>
>> On Wednesday, March 19, 2014 7:54:27 AM UTC-5, David Portabella wrote:
>>>
>>> I have this test.pp example on puppet 3.4.3 on OSX 10.9:
>>>
>>> c2 {'test': }
>>> -> 
>>> c3 {'test': }
>>>
>>> define c1 {
>>>   notice "+++"
>>>   file {'/tmp/c1.txt': ensure => present }
>>> }
>>>
>>> define c2 {
>>>   c1 {$name: }
>>>   notice "+++"
>>>   file {'/tmp/c2.txt': ensure => present }
>>> }
>>>
>>> define c3 {
>>>   notice "+++"
>>>   file {'/tmp/c3.txt': ensure => present }
>>> }
>>>
>>> running:
>>>
>>> $ puppet apply --graph test.pp 
>>>
>>> produces this graph 
>>> /Users/david/.puppet/var/state/graphs/relationships.dot,
>>>
>>> *which shows that /tmp/c3.txt does not require /tmp/c2.txt.*
>>>
>>> *why?*
>>>
>>
>>
>> I don't know, and your graph did not come across.  However, it may simply 
>> be a case of Puppet optimizing.  Two unrelated File resources cannot have a 
>> *bona 
>> fide* ordering relationship between them, because syncing one in no way 
>> affects syncing the other.
>>
>> Still, I find it surprising.  Is there at least a chain of relationships 
>> that will cause File['/tmp/c2.txt'] to be applied before 
>> File['/tmp/c3.txt']?  Are you sure the catalog you analyzed corresponds to 
>> the version of your manifest set that contains the chain operator you 
>> depict?
>>
>>
>> John
>>
>>

-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/732981db-939c-4efd-a6dd-e04c93894aba%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Puppet Users] puppet agent doesn't start service on initial run

2014-03-27 Thread Bogdan Mania
Ok, I sorted it out... I used your suggestion too, but the problem was that 
on the first run puppet created the log folder after initiating the service 
start. And having nowhere to write the log, the application failed to 
launch.

So I added require File["/var/log/java/java-app"] to the service 
declaration and it worked perfectly.

Thanks for the answers.

On Thursday, March 27, 2014 11:01:02 AM UTC+2, Jose Luis Ledesma wrote:
>
> I think you should declare the require Jdk7::Install7['jdk1.7.0_51'] in 
> the service.
>
> If it doesn't work, I would comment out the service and would try to run 
> it manually. It doesn't seem a  puppet problem.
> El 27/03/2014 09:09, "Bogdan Mania" > 
> escribió:
>
>> Yes it does. But java gets installed first when executing the catalog for 
>> the first time. In the Puppet dashboard it shows for the service "ensure 
>> changed 'stopped' to 'running'".
>>
>> But the service is not running. If I trigger a second puppet run it shows 
>> again the 
>>
>> On Wednesday, March 26, 2014 6:50:36 PM UTC+2, Jose Luis Ledesma 
>> wrote:"ensure changed 'stopped' to 'running'" message and this time is 
>> actually running.
>>
>> The service requiere the java to be installed first?
>>> El 26/03/2014 14:49, "Bogdan Mania"  escribió:
>>>
 Hi,

 I've created a module to manage a custom java application. It has it's 
 own SysV init script which is working perfectly.

 My issue is this: when a node pulls it's catalog from the master for 
 the first time, it doesn't also start the service. It starts the service 
 however on the second run.
 This is the module's init.pp file:

 class java-app {

 $java_paths = ["/usr/local/java/", "/usr/local/java/java-app/", 
 "/var/log/java/", "/var/log/java/java-app/", "/etc/java/", 
 "/etc/java/java-app/",]

 jdk7::install7 { 'jdk1.7.0_51':
 version =>  "7u51",
 fullVersion =>  "jdk1.7.0_51",
 x64 =>  true,
 downloadDir =>  "/install",
 }

 file { $java_paths:
 ensure  => directory,
 owner   => "ec2-user",
 group   => "ec2-user",
 recurse => true,
 }

 file { "/usr/local/java/java-app/java-app.jar":
 ensure => present,
 owner  => "ec2-user",
 group  => "ec2-user",
 notify => Service["java-app"],
 source => "puppet:///files/java-app/java-app.jar",
 }
  
 file { "/etc/java/java-app/java-app.yml":
 ensure => present,
 owner  => "ec2-user",
 group  => "ec2-user",
  notify => Service["java-app"],
 source => "puppet:///files/java-app/java-app.yml",
 }

 file { "/etc/init.d/java-app":
 ensure => present,
 source => "puppet:///files/java-app/java-app",
 }

 service { "java-app":
 ensure  => running,
 enable  => true,
 hasrestart  => true,
 hasstatus   => true,
 status  => '/sbin/service java-app status | grep "is 
 running"',
 restart => "/sbin/service java-app restart",
 start   => "/sbin/service java-app start",
 stop=> "/sbin/service java-app stop",
 require => [ File['/etc/java/java-app/java-app.yml'], 
 File['/usr/local/java/java-app/java-app.jar'], 
 File['/etc/init.d/java-app'] ]
 }
 }
  
 -- 
 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 puppet-users...@googlegroups.com.
 To view this discussion on the web visit https://groups.google.com/d/
 msgid/puppet-users/d707884b-4280-4905-8519-412c7eecb36b%
 40googlegroups.com
 .
 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 puppet-users...@googlegroups.com .
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/puppet-users/cc548fed-244a-4610-aea5-d28417b18f65%40googlegroups.com
>> .
>> 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 emai

[Puppet Users] Re: i require a defined type which contains a file resource, but the file resource does not retain the relatioship

2014-03-27 Thread David Portabella
I've open a bug ticket:
puppet --graph misses some dependencies
https://tickets.puppetlabs.com/browse/PUP-2075


d1 {'test': }
-> 
d2 {'test': }

define d1 {
  exec { exec1: command => '/bin/echo exec1; exit 1' }
}

define d2 {
  exec { exec2: command => '/bin/echo exec2; exit 1' }
}

---
$ puppet apply --graph test.pp 

the graph does not show any dependency between exec1 and exec2.

However the dependency does exists, as puppet does nor execute exec2 
because of "failed dependencies":

$ puppet apply --graph dd.pp 
Notice: Compiled catalog for mac4c.local in environment production in 0.08 
seconds
Notice: /Stage[main]//D1[test]/Exec[exec1]/returns: exec1
Error: /bin/echo exec1; exit 1 returned 1 instead of one of [0]
Error: /Stage[main]//D1[test]/Exec[exec1]/returns: change from notrun to 0 
failed: /bin/echo exec1; exit 1 returned 1 instead of one of [0]
Notice: /Stage[main]//D2[test]/Exec[exec2]: Dependency Exec[exec1] has 
failures: true
Warning: /Stage[main]//D2[test]/Exec[exec2]: Skipping because of failed 
dependencies
Notice: Finished catalog run in 0.11 seconds


So, it seems that there is a bug in puppet --graph.



On Wednesday, March 19, 2014 9:51:08 PM UTC+1, jcbollinger wrote:
>
>
>
> On Wednesday, March 19, 2014 7:54:27 AM UTC-5, David Portabella wrote:
>>
>> I have this test.pp example on puppet 3.4.3 on OSX 10.9:
>>
>> c2 {'test': }
>> -> 
>> c3 {'test': }
>>
>> define c1 {
>>   notice "+++"
>>   file {'/tmp/c1.txt': ensure => present }
>> }
>>
>> define c2 {
>>   c1 {$name: }
>>   notice "+++"
>>   file {'/tmp/c2.txt': ensure => present }
>> }
>>
>> define c3 {
>>   notice "+++"
>>   file {'/tmp/c3.txt': ensure => present }
>> }
>>
>> running:
>>
>> $ puppet apply --graph test.pp 
>>
>> produces this graph 
>> /Users/david/.puppet/var/state/graphs/relationships.dot,
>>
>> *which shows that /tmp/c3.txt does not require /tmp/c2.txt.*
>>
>> *why?*
>>
>
>
> I don't know, and your graph did not come across.  However, it may simply 
> be a case of Puppet optimizing.  Two unrelated File resources cannot have a 
> *bona 
> fide* ordering relationship between them, because syncing one in no way 
> affects syncing the other.
>
> Still, I find it surprising.  Is there at least a chain of relationships 
> that will cause File['/tmp/c2.txt'] to be applied before 
> File['/tmp/c3.txt']?  Are you sure the catalog you analyzed corresponds to 
> the version of your manifest set that contains the chain operator you 
> depict?
>
>
> John
>
>

-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/9fe34fdb-4b31-4df3-ac5d-d0d1bfec49d8%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Puppet Users] Re: Error when checking out repo with svn+ssh

2014-03-27 Thread Alexander Fortin
On Wednesday, March 26, 2014 8:06:02 PM UTC+1, rupsmaths wrote:
>
> When i try running puppet agent -t --server 
> i get the following error:
> *Error: Execution of '/usr/bin/svn --non-interactive checkout 
> svn+ssh://repo' returned 1: svn: To better debug SSH connection problems, 
> remove the -q option from 'ssh' in the [tunnels] section of your Subversion 
> configuration file.*
> *svn: Network connection closed unexpectedly*
>
> I have added the private key on to my client machine so that i dont have 
> to enter the password again and again.
>
> What should i do? I hope i have explained the problem good enough..Waiting 
> for your help guys.
>

Hi. Not sure where that vcsrepo resource is coming from, anyway I guess 
it's a defined resource declaring an Exec that tries to run your svn 
command. Maybe the (shell) environment you're testing your script from is 
different from the one your Puppet run is using (i.e. different users) ?

Anyway, the general advise is to provide the more data and context you can 
if you want others to help you out solving your problem ;) For example, try 
to run puppet with --debug and/or --trace option and see if it gives you 
more hints, by the way the svn error message is already giving you some, so 
maybe also remove (temporally) the -q option there to have more information.
 

-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/e2942599-f21e-44ac-846b-9dd67ac27e44%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Puppet Users] puppet class dependencies

2014-03-27 Thread David Portabella
My colleague Guillaume showed me a possible implementation of the anchor 
pattern:

class { c2: }
->
class { c3: }

class c1 {
  notice "+++"

  anchor {'before_c1':}
  ->
  file {'/tmp/c1.txt': ensure => present }
  ->
  anchor {'after_c1':}
}

class c2 {
  include c1
  notice "+++"

  anchor {'before_c2':}
  ->
  file {'/tmp/c2.txt': ensure => present }
  ->
  anchor {'after_c2':}
}

class c3 {
  notice "+++"

  anchor {'before_c3':}
  ->
  file {'/tmp/c3.txt': ensure => present }
  ->
  anchor {'after_c3':}
}

Anchor['after_c1'] -> Anchor['before_c2']
Anchor['after_c2'] -> Anchor['before_c3']

$ puppet apply --graph test.pp

$ open -a GraphViz /Users/david/.puppet/var/state/graphs/relationships.dot 


class C3 itself does not depend on class C1,
but all the resource declared in class C3 (in this case, only 
/tmp/file3.txt) do depend on all the resources declared on class C2 (in 
this case, only /tmp/file2.txt),
and transitively they depend also on all the resources declared on class C1 
(in this case, only /tmp/file1.txt)


-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/44052423-3c8c-4d2a-9cf5-4eec6a54af2a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Puppet Users] Books and resources for Test Driven Development for Puppet?

2014-03-27 Thread Garrett Honeycutt
On 3/24/14, 6:24 PM, Alex Scoble wrote:
> Hi All,
> 
> Was wondering if anyone knew of any good books or resources for learning
> Test Driven Development of Puppet including puppet-rspec, beaker and
> Jenkins. Yes, I know that beaker is more for acceptance testing than
> unit testing, but I still see it as part of the testing tool chain that
> Puppet pros should ultimately know how to use.
> 
> I'm looking for resources that really start with the basics for each
> subject and then help people ramp up to more advanced usage.
> 
> Yes, I know there's
> this http://puppetlabs.com/blog/test-driven-development-with-puppet and
> some other blog posts, but they don't really start basic enough or go
> deep enough.
> 
> What I'm looking for are resources that help me build our testing tool
> chain and also show how to use the tool chain once it's built.
> 
> Thanks,
> 
> Alex


Hi,

Here are my slides[1] from a tutorial I recently gave at Cascadia IT
Conference in Seattle about Test Driven Development with Puppet. Not
sure how great they are on their own, but they at least have some
examples and links to get you started. April 5th I will be doing another
free tutorial session at LOADays[2] in Antwerp. I also teach a two day
Advanced Puppet course[3] that focuses on testing.

[1] -
http://www.slideshare.net/gh/20140307-cascadia-itconftddwithpuppettutorial

[2] - http://loadays.org/

[3] - http://learnpuppet.com/training/

Best regards,
-g

-- 
Garrett Honeycutt
@learnpuppet
Puppet Training with LearnPuppet.com
Mobile: +1.206.414.8658

-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/5333ED2B.9000202%40garretthoneycutt.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Puppet Users] puppet agent doesn't start service on initial run

2014-03-27 Thread José Luis Ledesma
I think you should declare the require Jdk7::Install7['jdk1.7.0_51'] in the
service.

If it doesn't work, I would comment out the service and would try to run it
manually. It doesn't seem a  puppet problem.
El 27/03/2014 09:09, "Bogdan Mania"  escribió:

> Yes it does. But java gets installed first when executing the catalog for
> the first time. In the Puppet dashboard it shows for the service "ensure
> changed 'stopped' to 'running'".
>
> But the service is not running. If I trigger a second puppet run it shows
> again the
>
> On Wednesday, March 26, 2014 6:50:36 PM UTC+2, Jose Luis Ledesma
> wrote:"ensure changed 'stopped' to 'running'" message and this time is
> actually running.
>
> The service requiere the java to be installed first?
>> El 26/03/2014 14:49, "Bogdan Mania"  escribió:
>>
>>> Hi,
>>>
>>> I've created a module to manage a custom java application. It has it's
>>> own SysV init script which is working perfectly.
>>>
>>> My issue is this: when a node pulls it's catalog from the master for the
>>> first time, it doesn't also start the service. It starts the service
>>> however on the second run.
>>> This is the module's init.pp file:
>>>
>>> class java-app {
>>>
>>> $java_paths = ["/usr/local/java/", "/usr/local/java/java-app/",
>>> "/var/log/java/", "/var/log/java/java-app/", "/etc/java/",
>>> "/etc/java/java-app/",]
>>>
>>> jdk7::install7 { 'jdk1.7.0_51':
>>> version =>  "7u51",
>>> fullVersion =>  "jdk1.7.0_51",
>>> x64 =>  true,
>>> downloadDir =>  "/install",
>>> }
>>>
>>> file { $java_paths:
>>> ensure  => directory,
>>> owner   => "ec2-user",
>>> group   => "ec2-user",
>>> recurse => true,
>>> }
>>>
>>> file { "/usr/local/java/java-app/java-app.jar":
>>> ensure => present,
>>> owner  => "ec2-user",
>>> group  => "ec2-user",
>>> notify => Service["java-app"],
>>> source => "puppet:///files/java-app/java-app.jar",
>>> }
>>>
>>> file { "/etc/java/java-app/java-app.yml":
>>> ensure => present,
>>> owner  => "ec2-user",
>>> group  => "ec2-user",
>>> notify => Service["java-app"],
>>> source => "puppet:///files/java-app/java-app.yml",
>>> }
>>>
>>> file { "/etc/init.d/java-app":
>>> ensure => present,
>>> source => "puppet:///files/java-app/java-app",
>>> }
>>>
>>> service { "java-app":
>>> ensure  => running,
>>> enable  => true,
>>> hasrestart  => true,
>>> hasstatus   => true,
>>> status  => '/sbin/service java-app status | grep "is
>>> running"',
>>> restart => "/sbin/service java-app restart",
>>> start   => "/sbin/service java-app start",
>>> stop=> "/sbin/service java-app stop",
>>> require => [ File['/etc/java/java-app/java-app.yml'],
>>> File['/usr/local/java/java-app/java-app.jar'],
>>> File['/etc/init.d/java-app'] ]
>>> }
>>> }
>>>
>>> --
>>> 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 puppet-users...@googlegroups.com.
>>> To view this discussion on the web visit https://groups.google.com/d/
>>> msgid/puppet-users/d707884b-4280-4905-8519-412c7eecb36b%
>>> 40googlegroups.com
>>> .
>>> 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 puppet-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/puppet-users/cc548fed-244a-4610-aea5-d28417b18f65%40googlegroups.com
> .
> 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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/CAF_B3dfnXsFtHQoguNf9Rxve7ni03f9%3DmZcg0tmaTpNG66_mLQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Puppet Users] UTF8 package names on windows (invalid byte sequence)

2014-03-27 Thread mailnoxx
Hi Rob,

thanks for your answer.
I tried chocolatey as it seems to be the easiest solution and very useful 
for other packages on windows, too.
Chocolatey worked, but I hadn't time so far to take a look into how it 
handle this specific case.
Thanks for the tip.

Kind regards.


On Tuesday, March 25, 2014 10:45:26 PM UTC+1, Rob Reynolds wrote:
>
> I'm not sure we have a workaround for this at the current time. I know in 
> 3.5.0 we have made some improvements in puppet resource package. You might 
> give the RC a try.
>
> If that doesn't work, please file an issue on this.
>
> As a current workaround for using the windows package resource, have you 
> looked at chocolatey package resource?
>
>
> On Tue, Mar 25, 2014 at 9:25 AM, >wrote:
>
>> Hi,
>>
>> I'm currently trying to install Skype's MSI using puppet.
>> The name of the  package returned by 'puppet resource package' is "SkypeT 
>> 6.14".
>> The correct one would be "Skype™ 6.14".
>>
>> However, puppet fails to handle both:
>> If specified with the trademark sign, I get an "invalid byte sequence in 
>> US-ASCII" error.
>> If specified following the return value if the puppet resource, it also 
>> tries to install it again (as it does not match the windows package name).
>>
>> It seems that puppet has a general problem with utf-8 characters or other 
>> special signs like umlauts [1],[2] which had not been fixed yet.
>> But I wasn't able to find a workaround/solution for this kind of problem.
>>
>> Software in use:
>> Puppet Client: v3.4.3 on Windows 7 Professional (German language)
>> Puppet Master: v3.4.3 on Debian 7
>>
>> Anyone has an idea?
>> Thanks in advance.
>>
>> [1] https://groups.google.com/forum/#!topic/puppet-users/49ovbwcC7vs
>> [2] https://tickets.puppetlabs.com/browse/PUP-1225
>>
>> -- 
>> 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 puppet-users...@googlegroups.com .
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/puppet-users/91b2a79c-d7e2-4286-a267-00cfa2af11d6%40googlegroups.com
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
> -- 
> Rob Reynolds
> Developer, Puppet Labs
>
> *Join us at PuppetConf 2014, September 23-24 in San Francisco - *
> http://bit.ly/pupconf14
> Register now and save $350!
>  

-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/e3ed55ff-1294-43af-8dd4-c683c60d5075%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Puppet Users] Re: Books and resources for Test Driven Development for Puppet?

2014-03-27 Thread Johan De Wit

On 26/03/14 19:30, Alex Scoble wrote:
It's kind of annoying that there's a TDD for Chef book from O'Reilly, 
but not one for Puppet. There's definitely a need for it, in my opinion.


unfortunatly, my rspec is not good enough yet ...  and indeed, i think 
this is a gap that needs to be filled.


the information is out there somewhere, but hard to find, and some are 
outdated ...


I still have to check the 'puppetlabs supported modules' in respect of 
the unit testing, and i hope the tests are done for those modules in a 
'consistent' way.


I have seen rspec code for many modules, but every time, it was done in 
just another way ...


Makes it hard to get started.

And if you do TDD, you just need the rspec thing



m2c








On Monday, March 24, 2014 10:24:35 AM UTC-7, Alex Scoble wrote:

Hi All,

Was wondering if anyone knew of any good books or resources for
learning Test Driven Development of Puppet including puppet-rspec,
beaker and Jenkins. Yes, I know that beaker is more for acceptance
testing than unit testing, but I still see it as part of the
testing tool chain that Puppet pros should ultimately know how to use.

I'm looking for resources that really start with the basics for
each subject and then help people ramp up to more advanced usage.

Yes, I know there's this
http://puppetlabs.com/blog/test-driven-development-with-puppet

and some other blog posts, but they don't really start basic
enough or go deep enough.

What I'm looking for are resources that help me build our testing
tool chain and also show how to use the tool chain once it's built.

Thanks,

Alex

--
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 puppet-users+unsubscr...@googlegroups.com 
.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/4e311142-b45c-45b2-a991-1d2e5447a5fd%40googlegroups.com 
.

For more options, visit https://groups.google.com/d/optout.



--
Johan De Wit

Open Source Consultant

Red Hat Certified Engineer  (805008667232363)
Puppet Certified Professional 2013/2014 (PCP006)
_
 
Open-Future Phone +32 (0)2/255 70 70

Zavelstraat 72  Fax   +32 (0)2/255 70 71
3071 KORTENBERG Mobile+32 (0)474/42 40 73
BELGIUM http://www.open-future.be
_
 



Next Events:
Puppet Introduction Course | 
http://www.open-future.be/puppet-introduction-course-14th-april
Puppet Advanced Training | 
http://www.open-future.be/puppet-advanced-training-15-till-17th-april
Linux Training | https://www.open-future.be/linux-training-5-till-9th-may
Puppet Introduction Course | 
https://www.open-future.be/puppet-introduction-course-12th-may
Subscribe to our newsletter | http://eepurl.com/BUG8H

--
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/5333DF1C.7010304%40open-future.be.
For more options, visit https://groups.google.com/d/optout.


Re: [Puppet Users] puppet agent doesn't start service on initial run

2014-03-27 Thread Bogdan Mania
Yes it does. But java gets installed first when executing the catalog for 
the first time. In the Puppet dashboard it shows for the service "ensure 
changed 'stopped' to 'running'".

But the service is not running. If I trigger a second puppet run it shows 
again the 

On Wednesday, March 26, 2014 6:50:36 PM UTC+2, Jose Luis Ledesma 
wrote:"ensure changed 'stopped' to 'running'" message and this time is 
actually running.

The service requiere the java to be installed first?
> El 26/03/2014 14:49, "Bogdan Mania" > 
> escribió:
>
>> Hi,
>>
>> I've created a module to manage a custom java application. It has it's 
>> own SysV init script which is working perfectly.
>>
>> My issue is this: when a node pulls it's catalog from the master for the 
>> first time, it doesn't also start the service. It starts the service 
>> however on the second run.
>> This is the module's init.pp file:
>>
>> class java-app {
>>
>> $java_paths = ["/usr/local/java/", "/usr/local/java/java-app/", 
>> "/var/log/java/", "/var/log/java/java-app/", "/etc/java/", 
>> "/etc/java/java-app/",]
>>
>> jdk7::install7 { 'jdk1.7.0_51':
>> version =>  "7u51",
>> fullVersion =>  "jdk1.7.0_51",
>> x64 =>  true,
>> downloadDir =>  "/install",
>> }
>>
>> file { $java_paths:
>> ensure  => directory,
>> owner   => "ec2-user",
>> group   => "ec2-user",
>> recurse => true,
>> }
>>
>> file { "/usr/local/java/java-app/java-app.jar":
>> ensure => present,
>> owner  => "ec2-user",
>> group  => "ec2-user",
>> notify => Service["java-app"],
>> source => "puppet:///files/java-app/java-app.jar",
>> }
>>
>> file { "/etc/java/java-app/java-app.yml":
>> ensure => present,
>> owner  => "ec2-user",
>> group  => "ec2-user",
>> notify => Service["java-app"],
>> source => "puppet:///files/java-app/java-app.yml",
>> }
>>
>> file { "/etc/init.d/java-app":
>> ensure => present,
>> source => "puppet:///files/java-app/java-app",
>> }
>>
>> service { "java-app":
>> ensure  => running,
>> enable  => true,
>> hasrestart  => true,
>> hasstatus   => true,
>> status  => '/sbin/service java-app status | grep "is 
>> running"',
>> restart => "/sbin/service java-app restart",
>> start   => "/sbin/service java-app start",
>> stop=> "/sbin/service java-app stop",
>> require => [ File['/etc/java/java-app/java-app.yml'], 
>> File['/usr/local/java/java-app/java-app.jar'], File['/etc/init.d/java-app'] 
>> ]
>> }
>> }
>>  
>> -- 
>> 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 puppet-users...@googlegroups.com .
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/puppet-users/d707884b-4280-4905-8519-412c7eecb36b%40googlegroups.com
>> .
>> 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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/cc548fed-244a-4610-aea5-d28417b18f65%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.