Last change
on this file since 2736 was
1761,
checked in by broder, 16 years ago
|
Initial checkin of xvm-munin-config package
|
-
Property svn:executable set to
*
|
File size:
488 bytes
|
Rev | Line | |
---|
[1761] | 1 | #!/usr/bin/perl -n |
---|
| 2 | BEGIN { |
---|
| 3 | print <<'EOF'; |
---|
| 4 | <% |
---|
| 5 | from invirt.config import structs as cfg |
---|
| 6 | %> |
---|
| 7 | EOF |
---|
| 8 | } |
---|
| 9 | |
---|
| 10 | s/^user root/user munin/m; |
---|
| 11 | s/^group root/group munin/m; |
---|
| 12 | s/^node.startup = manual/node.startup = automatic/m; |
---|
| 13 | # mako just generally doesn't deal well with lines that start with |
---|
| 14 | # hashes, so we'll strip them |
---|
| 15 | # |
---|
| 16 | # And empty lines too, just for cleanliness |
---|
| 17 | s/^#.*$//m; |
---|
| 18 | print unless /^$/; |
---|
| 19 | |
---|
| 20 | END { |
---|
| 21 | print <<'EOF'; |
---|
| 22 | % for host in cfg.monitoring: |
---|
| 23 | allow ^${host.ip.replace('.', '\.')}$ |
---|
| 24 | % endfor |
---|
| 25 | EOF |
---|
| 26 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.