From: Greg Price Date: Sat, 2 Aug 2008 03:58:35 +0000 (-0400) Subject: get db connection name from config in sipb-xen-update-conserver X-Git-Tag: sipb-xen-console-server/2.05~1 X-Git-Url: http://xvm.mit.edu/gitweb/invirt/packages/invirt-console.git/commitdiff_plain/090aa4c98a7cb685a21784fe225c9ea9af4510ee get db connection name from config in sipb-xen-update-conserver svn path=/trunk/packages/sipb-xen-console-server/; revision=814 --- diff --git a/config.todo b/config.todo index b3044a7..2b1eeb4 100644 --- a/config.todo +++ b/config.todo @@ -1,3 +1,2 @@ files/etc/conserver/conserver.cf.sipb-xen: console-proxy ip files/etc/conserver/conserver.cf.sipb-xen: master-vm name -files/usr/sbin/sipb-xen-update-conserver: db uri diff --git a/debian/changelog b/debian/changelog index 36654c3..b4feddb 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,9 +1,9 @@ sipb-xen-console-server (2.05) unstable; urgency=low * use invirt.config rather than /etc/invirt/* directly - * get console-server hostname from config + * get console-server hostname, db connection string from config - -- Greg Price Fri, 1 Aug 2008 23:49:26 -0400 + -- Greg Price Fri, 1 Aug 2008 23:57:59 -0400 sipb-xen-console-server (2.04) unstable; urgency=low diff --git a/files/usr/sbin/sipb-xen-update-conserver b/files/usr/sbin/sipb-xen-update-conserver index b7f3bd8..8d99d64 100755 --- a/files/usr/sbin/sipb-xen-update-conserver +++ b/files/usr/sbin/sipb-xen-update-conserver @@ -6,7 +6,7 @@ import os import socket from invirt.config import structs as config -sipb_xen_database.connect('postgres://sipb-xen@sipb-xen-dev.mit.edu/sipb_xen') +sipb_xen_database.connect(config.db.uri) def live_vms(): p = subprocess.Popen(['/usr/sbin/xm', 'list'], stdout=subprocess.PIPE)