similar to: exec's onlyif parameter fails for a bash one-liner

Displaying 20 results from an estimated 2000 matches similar to: "exec's onlyif parameter fails for a bash one-liner"

2011 May 02
2
exec resource: negate onlyif condition
Hi, today I''m stupid. How can I negate the test for execs onlyif? I want to run the exec onlyif command returns 1. regards, Andreas -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to
2013 Apr 15
5
Using onlyif for Windows exec
Hello, I am in the process of "trying out" Puppet, and so far, it is going really well, and I can see a clear line of how we can use it internally. I do have one question though with regard to the using the onlyif parameter of the exec command (as per here http://docs.puppetlabs.com/references/latest/type.html#exec). Ideally, what I would like to do is to only run a PowerShell exec
2012 Apr 09
7
validate_re validation failures
I am using stdlib module''s validate_re function to validate parameters passed to a parameterized class as pasted here: http://pastebin.com/7eYAeLEa . The validation works fine however when I run this manifest locally using ''puppet apply'' command where puppet execution stops if a validation test fails. However when I use it in client-server model then I do see a
2009 Dec 17
1
unless & onlyif for the exec
Hello, Can I specify multiple onlyif''s and/or unless''s in an exec statement? A quick look through the recipes didn''t find any... Thanks, -Roy -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to
2012 Jul 03
6
Using onlyif
Here''s what I''m using: exec { "cert-fix": command => "curl http://curl.haxx.se/ca/cacert.pem -o /etc/pki/tls/certs/ca-bundle.crt", onlyif => "test -e /etc/pki/tls/certs/ca-bundle.crt", } But it keeps on failing: > [default] Running Puppet with /tmp/vagrant-puppet/manifests/acid.pp... > Parameter onlyif failed: ''test -e
2013 Nov 06
4
augeas onlyif problem
I''m trying to make sure a specific user has a special ssh key used as his identity file. so I''m trying something like: augeas{"user_second_key": context => "/files/home/user/.ssh/config", changes => [ "ins IdentityFile after /files/home/user/.ssh/config/IdentityFile[last()]", " set
2012 Mar 12
10
Use onlyif in EXEC
Hi guys! I need configure one command exec with onlyif parameter. I want test file size exist or no. Ho i do this? Tks in advanced. Douglas -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to
2007 Mar 29
2
some questions regarding inhert, unless/onlyif and notify on recursive objects
hello, i''m just playing around with the really great puppet to learn the syntax and see what it can do. i''m using puppet 0.22.1 on debian etch. i created a aide class to distribute a modified aide.conf.d directory and if not already done initialize the database (yes this should probably be better organized and databas initialization should be performed as the last step):
2012 Aug 29
1
augeas and cron.allow
Hi. I am having a few problems with augeas and need some help. What I am trying to use is augeas to update the cron.allow file. I can get augeas to add the required name but I am having problems with getting it to add the name once. augeas { "check_mk_cron.allow" : context => "/files/etc/cron.allow", # changes => "set
2007 Mar 18
1
A wish or possible?
Hi, One thing I''d like to be able to do is this... define sedfile ( $file = '''', $target = '''', $pattern = '''', $options = ''-i -n'' , onlyif = '''' ) { case $file { '''': { err ( "Require valid filename: ''$file''" ) } } case $target {
2010 Dec 29
1
Puppet and augeas - onlyif conditions; overwriting default values
Hello, I am still not getting warm with augeas and puppet, there are some things I do not understand. At the moment I am trying the following: - I want to set some kernel parameters in the /etc/sysctl.conf file - in one puppet module, I have defined some default values for the kernel parameters - but for several servers I want to modify some of these values, therefore I would like to overwrite
2010 Feb 18
7
Augeas pam.d argument checking
I''m trying to change the password complexity requirements in pam.d/system-auth using augeas. I can append the values (lcredit=-1, ucredit=-1, etc) onto the correct place, but if another value is already present (i.e. lcredit=-2), the onlyif match statement doesn''t seem to support checking regular expressions inside of strings. How do I check that any numeric value exists in the
2010 Dec 23
2
Multiple AllowGroups entries in sshd_config with Puppet and Augeas
Hi, After extensively looking into puppet + augeas for managing the AllowGroups in sshd_config, I came to the conclusion that it won''t work as I expected :( So I''m sharing my thoughts here. The main objective is allowing multiple groups per-node, depending on what the security team wants. Since I want this to be dynamic, I created a define in a class: class ssh::server::config
2012 Jul 31
4
Long processing time using Augeas
Hi! I using Augeas to handle dump and passno for certain mount points in /etc/fstab. Each mount point is defined as it''s own augeas block: augeas { ''homeLV'': context => ''/files/etc/fstab'', changes => [
2008 Oct 08
10
Puppet Augeas Plugin
Bryan -- I''m using the puppet augeas plugin at http://git.et.redhat.com/?p=ace.git;a=blob;f=modules/augeas/plugins/puppet/type/augeas.rb;h=2346c37d724d7607ed4e09b0413700bec2b7cbed;hb=HEAD I''m running into a behavior that I wouldn''t expect. I''d like to confirm an entry in sysctl.conf by changing the value if necessary or appending the key/value if it
2011 Apr 21
6
ssh_authorized_key fails when home directory doesn't exist
Here is my situation: 1. We use Active directory (LDAP) to store all user info which is retrieved from linux 2. A home directory is not created until the first time the user logs into the linux system I am using the ssh_authorized_key type to push out my ssh keys to every system. However, because I haven''t logged into every system at least once. Puppet errors out due to a missing
2013 May 29
1
augeas for hosts.allow
Hi I am trying to configure hosts.allow using augeas with puppet. I can add a ip range if process exists with this code augeas { "Add ${name} to ${process}": context => "/files/etc/hosts.allow", changes => "set *[process=''${process}'']/client[last()+1] ${name}", onlyif => "match
2009 Mar 02
31
Using Augeas type to update sshd_config's AllowGroups
Hey gang, I seem to be having a brain disconnect on how to get the Augeas type to manage things that have multiple values (i.e. an Augeas tree) via Puppet. If I run this in augtool: augtool> set /files/etc/ssh/sshd_config/AllowGroups/1000 sshuser augtool> save I see this in /etc/ssh/sshd_config: AllowGroups sshuser However, if I try this in an Augeas type: augeas {
2010 Aug 31
2
Executing check times out
Hi, Just recently two nodes begun to hang, I cant see that there have been any changes in our manifest. Debug output: [...] debug: //Node[X]/X[X]/Exec[create dir]: Executing check ''test \! -d / dir'' debug: Executing ''test \! -d /dir'' [...] Here it hangs for several minutes, executin the statement manually works of course. The manifest: exec {
2007 Feb 06
14
Unless in exec doesn''t seem to be honored on notify.
This was a fun one to track down... I was trying to use the append_if_no_such_line script from the wiki and it was working fine EXCEPT when I threw a notify at it. The notify appears to completely ignore both unless and onlyif within the exec for some reason. If I put the same test in the actual command line, it works fine. Example: unless => "/bin/grep -Fqe ''$line''