Issue #13578 has been updated by Josh Cooper.

Status changed from Unreviewed to Rejected

Hi Eslam, As Stefan mentioned this is the intended behavior around 
postrun_command. I'd recommend adding your postrun command as an exec resource 
in a postrun stage. This way the command will only be run if everything else in 
the catalog is successfully applied.
----------------------------------------
Bug #13578: postrun_command exectes even if puppet run has failures
https://projects.puppetlabs.com/issues/13578#change-59524

Author: Eslam El Husseiny
Status: Rejected
Priority: Normal
Assignee: 
Category: 
Target version: 
Affected Puppet version: 2.7.9
Keywords: puppet agent, postrun_command
Branch: 


Hi,
i was testing puppet postrun_command option and i found that it will be 
executed even if puppet run has failures 
as seen in this snippets :

    debug: Executing 'rm /root/file'
    debug: catalog supports formats: b64_zlib_yaml dot marshal pson raw yaml; 
using pson
    err: Could not retrieve catalog from remote server: Error 400 on SERVER: 
Could not find class standardbuild for natty64.in at 
/etc/puppet/manifests/nodes.pp:7 on node natty64.in
    info: Not using expired catalog for natty64.in from cache; expired at Tue 
Mar 27 15:53:04 +0000 2012
    notice: Using cached catalog
    err: Could not retrieve catalog; skipping run
    debug: Executing 'touch /root/file'


so i'd like to know if i can make sure that postrun_command won't be executed 
if puppet run fails Or even has a single individual failure

Thanks in advance  


-- 
You have received this notification because you have either subscribed to it, 
or are involved in it.
To change your notification preferences, please click here: 
http://projects.puppetlabs.com/my/account

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Bugs" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/puppet-bugs?hl=en.

Reply via email to