[augeas-devel] Module for func using augeas

Louis Coilliot louis.coilliot at gmail.com
Thu Nov 27 19:45:36 UTC 2008


> I'm thinking it's about time for another release.
> (...)
> So if anyone has anything outstanding (patches, modules,
> must have features, must fix bugs, docs, etc) it would be
> great if you could get it ready soon ;-)
>(...)
> Adrian

Hello, so here is a new module proposal.

This is a module to handle (get, set, list...) parameters in configuration
files.

It relies on augeas (http://augeas.net/).

I wanted to post later,
because in comparison with augeas.py I didn't make the move and insert
methods,
because I have improvements in mind,
and because I want to add more behaviour consistency with augtool of Augeas.

But I will not have time for this before Christmas, and the module is
working fine as-is.

A quick example:
#!/usr/bin/env python
import sys
import func.overlord.client as fc
c = fc.Client("*")
print 'Set PermitRootLogin to no in sshd_config'
print c.confmgt_augeas.set('/etc/ssh/sshd_config','PermitRootLogin','no')

(which does what is expected, of course)

In attachment you'll find:
- the module
- a test script I use to check the behaviour of the module
- the result of this test script on my test platform
  (so you can see what the module does)
- a minimal doc. inspired from the quick tour on the augeas web site

Let me know if you think it is useful.

Louis Coilliot
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/augeas-devel/attachments/20081127/e0c02f63/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: confmgt_augeas.py
Type: text/x-python
Size: 13060 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/augeas-devel/attachments/20081127/e0c02f63/attachment.py>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: confmgt_augeas-doc.txt
URL: <http://listman.redhat.com/archives/augeas-devel/attachments/20081127/e0c02f63/attachment.txt>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test-confmgt_augeas.py
Type: text/x-python
Size: 6762 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/augeas-devel/attachments/20081127/e0c02f63/attachment-0001.py>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test-confmgt_augeas.out
Type: application/octet-stream
Size: 5278 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/augeas-devel/attachments/20081127/e0c02f63/attachment.obj>


More information about the augeas-devel mailing list