From 78cd1676b7620749b74b20153989eb6fdf571f73 Mon Sep 17 00:00:00 2001 From: Yang Zhang Date: Thu, 14 Aug 2008 15:19:04 -0400 Subject: [PATCH] generate config files using mako svn path=/trunk/packages/sipb-xen-remctl-auto/; revision=891 --- debian/changelog | 6 ++++++ debian/sipb-xen-remctl-auto.init | 5 +++-- files/etc/remctl/acl/remote.mako | 2 ++ 3 files changed, 11 insertions(+), 2 deletions(-) create mode 100644 files/etc/remctl/acl/remote.mako diff --git a/debian/changelog b/debian/changelog index d372ef6..bb20064 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +sipb-xen-remctl-auto (1.0.20) unstable; urgency=low + + * generate config files using mako + + -- Yang Zhang Thu, 14 Aug 2008 15:18:46 -0400 + sipb-xen-remctl-auto (1.0.19) unstable; urgency=low * simplify the init script a la sipb-xen-dev diff --git a/debian/sipb-xen-remctl-auto.init b/debian/sipb-xen-remctl-auto.init index d78d948..91ab5af 100755 --- a/debian/sipb-xen-remctl-auto.init +++ b/debian/sipb-xen-remctl-auto.init @@ -15,8 +15,9 @@ PACKAGE=sipb-xen-remctl-auto gen_config() { - echo "host/$(invirt-getconf remote.hostname)@$(invirt-getconf authn.0.realm)" \ - > /etc/remctl/acl/remote + for i in /etc/remctl/acl/remote + do mako-render $i.mako > $i + done } case "$1" in diff --git a/files/etc/remctl/acl/remote.mako b/files/etc/remctl/acl/remote.mako new file mode 100644 index 0000000..8a223ff --- /dev/null +++ b/files/etc/remctl/acl/remote.mako @@ -0,0 +1,2 @@ +<% from invirt.config import structs as cfg %>\ +host/${cfg.remote.hostname}@${cfg.authn[0].realm} -- 1.7.9.5