I can''t seem to get exec unless to work right, it ignores the unless and always runs the exec: root@puppet-test:~# cat /tmp/exectest.pp exec{"echo 1 > /tmp/ran": path => "/", unless => "true", } root@puppet-test:~# root@puppet-test:~# rm /tmp/ran ; ls /tmp/ran ls: cannot access /tmp/ran: No such file or directory root@puppet-test:~# root@puppet-test:~# puppet --verbose /tmp/exectest.pp info: Loading fact acpi_available info: Loading fact interfaces info: Loading fact virtual sh: Syntax error: Bad fd number sh: Syntax error: Bad fd number notice: //Exec[echo 1 > /tmp/ran]/returns: executed successfully root@puppet-test:~# root@puppet-test:~# ls /tmp/ran /tmp/ran root@puppet-test:~# seph --~--~---------~--~----~------------~-------~--~----~ 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 puppet-users+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~----------~----~----~----~------~----~------~--~---
2009/5/26 seph <seph@directionless.org>:> > I can''t seem to get exec unless to work right, it ignores the unless and > always runs the exec: > > root@puppet-test:~# cat /tmp/exectest.pp > exec{"echo 1 > /tmp/ran": > path => "/", > unless => "true", > } > root@puppet-test:~#Is the program ''true'' in your root directory? It''s in /bin on my desktop. you should try setting the path to "/bin" or running puppetd with --debug and looking at what command it''s running. .r'' --~--~---------~--~----~------------~-------~--~----~ 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 puppet-users+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~----------~----~----~----~------~----~------~--~---
>> I can''t seem to get exec unless to work right, it ignores the unless and >> always runs the exec: > > Is the program ''true'' in your root directory? It''s in /bin on my > desktop. you should try setting the path to "/bin" or running puppetd > with --debug and looking at what command it''s running.In fact... Too much cargo culting led to a bad path parameter. Thanks for the sanity check. seph --~--~---------~--~----~------------~-------~--~----~ 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 puppet-users+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~----------~----~----~----~------~----~------~--~---