Hi Sergio, Thanks for reporting this issue.
Could you open a ticket for it to make it easier to track? Thank you. Raphaël On Tue, Dec 21, 2010 at 11:11 PM, Sergio Ballestrero <[email protected]> wrote: > Hello, > it looks like in the current augeas (v7.4) the "exports" lens fails to deal > with hostnames containing dashes. If I look at the regular expression used, > it seems correct (in /usr/share/augeas/lenses/dist/exports.aug): > let client_re = /[a-za-z0-9\...@\*\?\/]+/ > > so as an newbie in augeas lenses I'm not understanding where the problem may > come from. Can someone point me at where to look? > > I've extended the test_exports.aug in case it helps - see below. > > Cheers, and thanks, > Sergio > PS besides few little hiccups, Augeas is a blessing! :-) > >> cat test_exports.aug > module Test_exports = > > let s = "/local 172.31.0.0/16(rw,sync) \t > > /home 172.31.0.0/16(rw,root_squash,sync) @netgroup(rw) *.example.com > # Yes, we export /tmp > /tmp 172.31.0.0/16(rw,root_squash,sync) > /local2 somehost(rw,sync) > /local3 some-host(rw,sync) > /local3 another-host(rw,sync) > " > > test Exports.lns get s = > { "dir" = "/local" > { "client" = "172.31.0.0/16" > { "option" = "rw" } > { "option" = "sync" } } } > { } > { "dir" = "/home" > { "client" = "172.31.0.0/16" > { "option" = "rw"} > { "option" = "root_squash" } > { "option" = "sync" } } > { "client" = "@netgroup" > { "option" = "rw" } } > { "client" = "*.example.com" } } > { "#comment" = "Yes, we export /tmp" } > { "dir" = "/tmp" > { "client" = "172.31.0.0/16" > { "option" = "rw" } > { "option" = "root_squash" } > { "option" = "sync" } } } > { "dir" = "/local2" > { "client" = "somehost" > { "option" = "rw" } > { "option" = "sync" } } } > { "dir" = "/local3" > { "client" = "some-host" > { "option" = "rw" } > { "option" = "sync" } } } > { "dir" = "/local3" > { "client" = "another-host" > { "option" = "rw" } > { "option" = "sync" } } } > >> augparse -I /usr/share/augeas/lenses test_exports.aug > test_exports.aug:13.2-44.37:exception thrown in test > test_exports.aug:13.7-.24:exception: Iterated lens matched less than it should > Lens: /usr/share/augeas/lenses/dist/exports.aug:96.12-.50: > Error encountered at 7:0 (190 characters into string) > <)\n/local2 somehost(rw,sync)\n|=|/local3 some-host(rw,sync)\n/> > > Tree generated so far: > /dir[1] = "/local" > /dir[1]/client = "172.31.0.0/16" > /dir[1]/client/option[1] = "rw" > /dir[1]/client/option[2] = "sync" > /(none) > /dir[2] = "/home" > /dir[2]/client[1] = "172.31.0.0/16" > /dir[2]/client[1]/option[1] = "rw" > /dir[2]/client[1]/option[2] = "root_squash" > /dir[2]/client[1]/option[3] = "sync" > /dir[2]/client[2] = "@netgroup" > /dir[2]/client[2]/option = "rw" > /dir[2]/client[3] = "*.example.com" > /#comment = "Yes, we export /tmp" > /dir[3] = "/tmp" > /dir[3]/client = "172.31.0.0/16" > /dir[3]/client/option[1] = "rw" > /dir[3]/client/option[2] = "root_squash" > /dir[3]/client/option[3] = "sync" > /dir[4] = "/local2" > /dir[4]/client = "somehost" > /dir[4]/client/option[1] = "rw" > /dir[4]/client/option[2] = "sync" > > > Syntax error in lens definition > Failed to load test_exports.aug > > > > > > > > _______________________________________________ > augeas-devel mailing list > [email protected] > https://www.redhat.com/mailman/listinfo/augeas-devel > _______________________________________________ augeas-devel mailing list [email protected] https://www.redhat.com/mailman/listinfo/augeas-devel
