summaryrefslogtreecommitdiffstats
path: root/examples/TGenshi/tmp
diff options
context:
space:
mode:
authorNarayan Desai <desai@mcs.anl.gov>2007-07-18 19:00:57 +0000
committerNarayan Desai <desai@mcs.anl.gov>2007-07-18 19:00:57 +0000
commitfd787917bdcd0aaf5f5b0b99dfa5e2a992d734a4 (patch)
tree0f71d021b49cf0698baabee9ba91a9b957d29318 /examples/TGenshi/tmp
parente21264fd11c7f2e32572467403fda08b0c94fe6d (diff)
downloadbcfg2-fd787917bdcd0aaf5f5b0b99dfa5e2a992d734a4.tar.gz
bcfg2-fd787917bdcd0aaf5f5b0b99dfa5e2a992d734a4.tar.bz2
bcfg2-fd787917bdcd0aaf5f5b0b99dfa5e2a992d734a4.zip
Initial TGenshi checking (from jcollie)
git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@3476 ce84e21b-d406-0410-9b95-82705330c041
Diffstat (limited to 'examples/TGenshi/tmp')
-rw-r--r--examples/TGenshi/tmp/bar/template.txt20
-rw-r--r--examples/TGenshi/tmp/foo/template.xml46
2 files changed, 66 insertions, 0 deletions
diff --git a/examples/TGenshi/tmp/bar/template.txt b/examples/TGenshi/tmp/bar/template.txt
new file mode 100644
index 000000000..3e43340fe
--- /dev/null
+++ b/examples/TGenshi/tmp/bar/template.txt
@@ -0,0 +1,20 @@
+[communication]
+protocol = xmlrpc/ssl
+#if metadata.uuid != None
+user = $metadata.uuid
+#end
+#choose
+#when metadata.password is not None
+password = $metadata.password
+#end
+#when metadata.password is None
+password = GlobalPassword
+#end
+#end
+fingerprint = ac152f42f03253a30d3379dea88eddf2be033d47
+
+[client]
+drivers = Action,Chkconfig,POSIX,YUMng
+
+[components]
+bcfg2 = https://config.example.com:6789
diff --git a/examples/TGenshi/tmp/foo/template.xml b/examples/TGenshi/tmp/foo/template.xml
new file mode 100644
index 000000000..522c6e7fe
--- /dev/null
+++ b/examples/TGenshi/tmp/foo/template.xml
@@ -0,0 +1,46 @@
+<html xmlns:py="http://genshi.edgewall.org/">
+ <head>
+ <title>${name}</title>
+ </head>
+ <body>
+ <table>
+ <tr><th>Name:</th><td>${name}</td></tr>
+ <tr><th>Hostname:</th><td>${metadata.hostname}</td></tr>
+ <tr><th>Toolset:</th><td>${metadata.hostname}</td></tr>
+ <tr><th>UUID:</th><td>${metadata.uuid}</td></tr>
+ <tr><th>Password:</th><td>${metadata.password}</td></tr>
+ <tr>
+ <th>Bundles:</th>
+ <td>
+ <table>
+ <tr py:for="bundle in metadata.bundles"><td>${bundle}</td></tr>
+ </table>
+ </td>
+ </tr>
+ <tr>
+ <th>Groups:</th>
+ <td>
+ <table>
+ <tr py:for="group in metadata.groups"><td>${group}</td></tr>
+ </table>
+ </td>
+ </tr>
+ <tr>
+ <th>Categories:</th>
+ <td>
+ <table>
+ <tr py:for="category in metadata.categories"><td>${category}</td></tr>
+ </table>
+ </td>
+ </tr>
+ <tr>
+ <th>Probes:</th>
+ <td>
+ <table>
+ <tr py:for="probe in metadata.probes"><td>${probe}</td><td>${metadata.probes[probe]}</td></tr>
+ </table>
+ </td>
+ </tr>
+ </table>
+ </body>
+</html>