You had to make me actually try it in Puppet, huh? ;)

My original example was missing commas after the various set statements. Not 
sure if you fixed that. It also specified the full path, even though the 
context should have taken care of most of it. That didn't seem to hurt, but to 
be safe, I took it out. I'm also using 0.25.4 and this worked:

    augeas { 'app_tcp':
      context => '/files/etc/services',
      changes => [
        "set service-name[port = '1002']/port 1002",
        "set service-name[port = '1002'] app_tcp",
        "set service-name[port = '1002']/protocol tcp",
        # "set service-name[port = '1002']/#comment foo",
      ],
    }

I disabled the comment because the line ended up looking like this:

    app_tcp 1002/tcp# foo

But that's probably a bug in the Agueas lens, not Puppet.

-- 
Rob McBroom
<http://www.skurfer.com/>


-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To post to this group, send email to puppet-us...@googlegroups.com.
To unsubscribe from this group, send email to 
puppet-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en.

Reply via email to