Robin Lee Powell
2009-Jan-18 06:01 UTC
[Puppet Users] Need onlyifnot (or something) for Augeas
There is, as far as I can tell, no way to make Augeas *not* do anything if a node exists. What I want is for the Augeas block to be skipped if the augtool command match /files/etc/exports/dir /foo would return true. Since I don''t know which dir number it''ll be, I can''t use get, and onlyif => "match dir include /foo" does exactly the opposite of what I want. -Robin -- They say: "The first AIs will be built by the military as weapons." And I''m thinking: "Does it even occur to you to try for something other than the default outcome?" -- http://shorl.com/tydruhedufogre http://www.digitalkingdom.org/~rlpowell/ *** http://www.lojban.org/ --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Peter Meier
2009-Jan-18 12:16 UTC
[Puppet Users] Re: Need onlyifnot (or something) for Augeas
Hi> There is, as far as I can tell, no way to make Augeas *not* do > anything if a node exists. What I want is for the Augeas block to > be skipped if the augtool command > > match /files/etc/exports/dir /foo > > would return true. Since I don''t know which dir number it''ll be, I > can''t use get, and > > onlyif => "match dir include /foo" > > does exactly the opposite of what I want.for exec there is unless, this might be the right term? However "unless" is not (yet) a metaparameter and therefore needs to be implemented. Maybe you find an idea how to do it, by looking at the onlyif and unless in the exec-type. I think if the options you have with onlyif aren''t satisfying every and in this case your situation, patches would be welcomed for an unless parameter. cheers pete --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
windowsrefund
2009-Jan-18 17:37 UTC
[Puppet Users] Re: Need onlyifnot (or something) for Augeas
Peter, Check out David Lutterkort''s responses to my 2009-01-16 thread entitled "[Puppet Users] Work in progress: Using augeas to manage /etc/ exports" Best, Adam On Jan 18, 7:16 am, Peter Meier <peter.me...@immerda.ch> wrote:> Hi > > > There is, as far as I can tell, no way to make Augeas *not* do > > anything if a node exists. What I want is for the Augeas block to > > be skipped if the augtool command > > > match /files/etc/exports/dir /foo > > > would return true. Since I don''t know which dir number it''ll be, I > > can''t use get, and > > > onlyif => "match dir include /foo" > > > does exactly the opposite of what I want. > > for exec there is unless, this might be the right term? > > However "unless" is not (yet) a metaparameter and therefore needs to be > implemented. > Maybe you find an idea how to do it, by looking at the onlyif and unless > in the exec-type. > > I think if the options you have with onlyif aren''t satisfying every and > in this case your situation, patches would be welcomed for an unless > parameter. > > cheers pete--~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---