From 1ab4aaa5934a4e4126fd91ac2ba29c6476870673 Mon Sep 17 00:00:00 2001 From: Evan Broder Date: Sat, 22 Nov 2008 05:36:20 -0500 Subject: [PATCH 01/16] Punt more tabs I bet I wrote this with tabs, too. *sigh* svn path=/trunk/packages/invirt-console-server/; revision=1740 --- debian/invirt-console-server.init | 120 ++++++++++++++++++------------------- 1 file changed, 60 insertions(+), 60 deletions(-) diff --git a/debian/invirt-console-server.init b/debian/invirt-console-server.init index 1ed7309..3b60f73 100755 --- a/debian/invirt-console-server.init +++ b/debian/invirt-console-server.init @@ -51,14 +51,14 @@ gen_config() # do_start() { - # Return - # 0 if daemon has been started - # 1 if daemon was already running - # 2 if daemon could not be started - modprobe fuse - gen_config - daemon --running -n $NAME && return 1 - daemon -r -O daemon.info -E daemon.err -n $NAME -U $DAEMON $DAEMON_ARGS || return 2 + # Return + # 0 if daemon has been started + # 1 if daemon was already running + # 2 if daemon could not be started + modprobe fuse + gen_config + daemon --running -n $NAME && return 1 + daemon -r -O daemon.info -E daemon.err -n $NAME -U $DAEMON $DAEMON_ARGS || return 2 } # @@ -66,70 +66,70 @@ do_start() # do_stop() { - # Return - # 0 if daemon has been stopped - # 1 if daemon was already stopped - # 2 if daemon could not be stopped - # other if a failure occurred - daemon --stop -n $NAME - RETVAL="$?" - [ "$RETVAL" = 2 ] && return 2 - # Many daemons don't delete their pidfiles when they exit. - rm -f $PIDFILE - umount "$DAEMON_ARGS" - return "$RETVAL" + # Return + # 0 if daemon has been stopped + # 1 if daemon was already stopped + # 2 if daemon could not be stopped + # other if a failure occurred + daemon --stop -n $NAME + RETVAL="$?" + [ "$RETVAL" = 2 ] && return 2 + # Many daemons don't delete their pidfiles when they exit. + rm -f $PIDFILE + umount "$DAEMON_ARGS" + return "$RETVAL" } do_reload() { - gen_config - invoke-rc.d conserver-server reload + gen_config + invoke-rc.d conserver-server reload } case "$1" in start) - [ "$VERBOSE" != no ] && log_daemon_msg "Starting $DESC" "$NAME" - do_start - case "$?" in - 0|1) [ "$VERBOSE" != no ] && log_end_msg 0 ;; - 2) [ "$VERBOSE" != no ] && log_end_msg 1 ;; - esac - ;; + [ "$VERBOSE" != no ] && log_daemon_msg "Starting $DESC" "$NAME" + do_start + case "$?" in + 0|1) [ "$VERBOSE" != no ] && log_end_msg 0 ;; + 2) [ "$VERBOSE" != no ] && log_end_msg 1 ;; + esac + ;; stop) - [ "$VERBOSE" != no ] && log_daemon_msg "Stopping $DESC" "$NAME" - do_stop - case "$?" in - 0|1) [ "$VERBOSE" != no ] && log_end_msg 0 ;; - 2) [ "$VERBOSE" != no ] && log_end_msg 1 ;; - esac - ;; + [ "$VERBOSE" != no ] && log_daemon_msg "Stopping $DESC" "$NAME" + do_stop + case "$?" in + 0|1) [ "$VERBOSE" != no ] && log_end_msg 0 ;; + 2) [ "$VERBOSE" != no ] && log_end_msg 1 ;; + esac + ;; reload|force-reload) - log_daemon_msg "Reloading $DESC" "$NAME" - do_reload - log_end_msg $? - ;; + log_daemon_msg "Reloading $DESC" "$NAME" + do_reload + log_end_msg $? + ;; restart) - log_daemon_msg "Restarting $DESC" "$NAME" - do_stop - case "$?" in - 0|1) - do_start - case "$?" in - 0) log_end_msg 0 ;; - 1) log_end_msg 1 ;; # Old process is still running - *) log_end_msg 1 ;; # Failed to start - esac - ;; - *) - # Failed to stop - log_end_msg 1 - ;; - esac - ;; + log_daemon_msg "Restarting $DESC" "$NAME" + do_stop + case "$?" in + 0|1) + do_start + case "$?" in + 0) log_end_msg 0 ;; + 1) log_end_msg 1 ;; # Old process is still running + *) log_end_msg 1 ;; # Failed to start + esac + ;; + *) + # Failed to stop + log_end_msg 1 + ;; + esac + ;; *) - echo "Usage: $SCRIPTNAME {start|stop|restart|reload|force-reload}" >&2 - exit 3 - ;; + echo "Usage: $SCRIPTNAME {start|stop|restart|reload|force-reload}" >&2 + exit 3 + ;; esac : -- 1.7.9.5 From d8481c7273070ee6e6b16c8c786dc747e3268510 Mon Sep 17 00:00:00 2001 From: Evan Broder Date: Sat, 22 Nov 2008 05:36:22 -0500 Subject: [PATCH 02/16] Clean up the invirt-console-server init script with some ideas from debathena-pyhesiodfs svn path=/trunk/packages/invirt-console-server/; revision=1741 --- debian/changelog | 6 ++++++ debian/invirt-console-server.init | 23 +++++++++++++++++------ 2 files changed, 23 insertions(+), 6 deletions(-) diff --git a/debian/changelog b/debian/changelog index 13f29f2..dec5b18 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +invirt-console-server (0.1.1) unstable; urgency=low + + * Clean up the init script with some ideas from debathena-pyhesiodfs. + + -- Evan Broder Sat, 22 Nov 2008 05:25:54 -0500 + invirt-console-server (0.1.0) unstable; urgency=low * Add real caching to consolefs diff --git a/debian/invirt-console-server.init b/debian/invirt-console-server.init index 3b60f73..17e44bb 100755 --- a/debian/invirt-console-server.init +++ b/debian/invirt-console-server.init @@ -18,7 +18,8 @@ PATH=/sbin:/usr/sbin:/bin:/usr/bin DESC="the Invirt console server" NAME=invirt-console-server DAEMON=/usr/bin/invirt-consolefs -DAEMON_ARGS="/consolefs" +MOUNTPOINT="/consolefs" +DAEMON_ARGS="-f $MOUNTPOINT" PIDFILE=/var/run/$NAME.pid SCRIPTNAME=/etc/init.d/$NAME @@ -55,10 +56,17 @@ do_start() # 0 if daemon has been started # 1 if daemon was already running # 2 if daemon could not be started - modprobe fuse + + # Try to make sure fuse is setup + [ -e /dev/fuse ] || modprobe fuse || return 2 + + if cat /proc/mounts | grep " $MOUNTPOINT " >/dev/null 2>&1; then + return 1 + fi + gen_config - daemon --running -n $NAME && return 1 - daemon -r -O daemon.info -E daemon.err -n $NAME -U $DAEMON $DAEMON_ARGS || return 2 + + daemon -r -O daemon.info -E daemon.err -n $NAME -- $DAEMON $DAEMON_ARGS || return 2 } # @@ -71,13 +79,16 @@ do_stop() # 1 if daemon was already stopped # 2 if daemon could not be stopped # other if a failure occurred + + if ! cat /proc/mounts | grep " $MOUNTPOINT " >/dev/null 2>&1; then + return 1 + fi + daemon --stop -n $NAME RETVAL="$?" [ "$RETVAL" = 2 ] && return 2 # Many daemons don't delete their pidfiles when they exit. rm -f $PIDFILE - umount "$DAEMON_ARGS" - return "$RETVAL" } do_reload() -- 1.7.9.5 From 987bd2edcf07a12e1683026e9a3bca46993c5bee Mon Sep 17 00:00:00 2001 From: Evan Broder Date: Sat, 22 Nov 2008 05:36:24 -0500 Subject: [PATCH 03/16] Switch to using std-init in invirt-console-server svn path=/trunk/packages/invirt-console-server/; revision=1742 --- debian/changelog | 3 +- debian/invirt-console-server.init | 58 ++----------------------------------- 2 files changed, 4 insertions(+), 57 deletions(-) diff --git a/debian/changelog b/debian/changelog index dec5b18..58c6ef9 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,8 +1,9 @@ invirt-console-server (0.1.1) unstable; urgency=low * Clean up the init script with some ideas from debathena-pyhesiodfs. + * Switch to using std-init. - -- Evan Broder Sat, 22 Nov 2008 05:25:54 -0500 + -- Evan Broder Sat, 22 Nov 2008 05:26:22 -0500 invirt-console-server (0.1.0) unstable; urgency=low diff --git a/debian/invirt-console-server.init b/debian/invirt-console-server.init index 17e44bb..f347622 100755 --- a/debian/invirt-console-server.init +++ b/debian/invirt-console-server.init @@ -26,15 +26,7 @@ SCRIPTNAME=/etc/init.d/$NAME # Exit if the package is not installed [ -x "$DAEMON" ] || exit 0 -# Read configuration variable file if it is present -[ -r /etc/default/$NAME ] && . /etc/default/$NAME - -# Load the VERBOSE setting and other rcS variables -. /lib/init/vars.sh - -# Define LSB log_* functions. -# Depend on lsb-base (>= 3.0-6) to ensure that this file is present. -. /lib/lsb/init-functions +. /lib/init/std-init.sh gen_config() { @@ -97,50 +89,4 @@ do_reload() invoke-rc.d conserver-server reload } -case "$1" in - start) - [ "$VERBOSE" != no ] && log_daemon_msg "Starting $DESC" "$NAME" - do_start - case "$?" in - 0|1) [ "$VERBOSE" != no ] && log_end_msg 0 ;; - 2) [ "$VERBOSE" != no ] && log_end_msg 1 ;; - esac - ;; - stop) - [ "$VERBOSE" != no ] && log_daemon_msg "Stopping $DESC" "$NAME" - do_stop - case "$?" in - 0|1) [ "$VERBOSE" != no ] && log_end_msg 0 ;; - 2) [ "$VERBOSE" != no ] && log_end_msg 1 ;; - esac - ;; - reload|force-reload) - log_daemon_msg "Reloading $DESC" "$NAME" - do_reload - log_end_msg $? - ;; - restart) - log_daemon_msg "Restarting $DESC" "$NAME" - do_stop - case "$?" in - 0|1) - do_start - case "$?" in - 0) log_end_msg 0 ;; - 1) log_end_msg 1 ;; # Old process is still running - *) log_end_msg 1 ;; # Failed to start - esac - ;; - *) - # Failed to stop - log_end_msg 1 - ;; - esac - ;; - *) - echo "Usage: $SCRIPTNAME {start|stop|restart|reload|force-reload}" >&2 - exit 3 - ;; -esac - -: +std_init "$1" -- 1.7.9.5 From db90cbf66302a1eedb81784da3acdf7ea1ff07fd Mon Sep 17 00:00:00 2001 From: Evan Broder Date: Sat, 22 Nov 2008 05:45:43 -0500 Subject: [PATCH 04/16] Use gen-files.sh in invirt-console-server instead of rolling our own svn path=/trunk/packages/invirt-console-server/; revision=1747 --- debian/changelog | 6 ++++++ debian/invirt-console-server.init | 18 ++++++------------ 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/debian/changelog b/debian/changelog index 58c6ef9..d737d23 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +invirt-console-server (0.1.2) unstable; urgency=low + + * Use gen-files.sh instead of rolling out own + + -- Evan Broder Sat, 22 Nov 2008 05:45:25 -0500 + invirt-console-server (0.1.1) unstable; urgency=low * Clean up the init script with some ideas from debathena-pyhesiodfs. diff --git a/debian/invirt-console-server.init b/debian/invirt-console-server.init index f347622..b5482e0 100755 --- a/debian/invirt-console-server.init +++ b/debian/invirt-console-server.init @@ -22,23 +22,17 @@ MOUNTPOINT="/consolefs" DAEMON_ARGS="-f $MOUNTPOINT" PIDFILE=/var/run/$NAME.pid SCRIPTNAME=/etc/init.d/$NAME +GEN_FILES=(/etc/conserver/invirt-hosts.cf + /etc/remctl/acl/invirt-console-server + /etc/issue.net.no_tkt + /etc/nss-pgsql.conf) # Exit if the package is not installed [ -x "$DAEMON" ] || exit 0 +. /lib/init/gen-files.sh . /lib/init/std-init.sh -gen_config() -{ - for i in /etc/conserver/invirt-hosts.cf \ - /etc/remctl/acl/invirt-console-server \ - /etc/issue.net.no_tkt \ - /etc/nss-pgsql.conf \ - ; do - mako-render $i.mako > $i - done -} - # # Function that starts the daemon/service # @@ -56,7 +50,7 @@ do_start() return 1 fi - gen_config + gen_files daemon -r -O daemon.info -E daemon.err -n $NAME -- $DAEMON $DAEMON_ARGS || return 2 } -- 1.7.9.5 From 2c1add646589cf7afd5e4e5d6e6d7a07f9bc96d0 Mon Sep 17 00:00:00 2001 From: Greg Price Date: Sat, 22 Nov 2008 19:29:01 -0500 Subject: [PATCH 05/16] fix gen_config -> gen_files in two initscripts svn path=/trunk/packages/invirt-console-server/; revision=1752 --- debian/changelog | 6 ++++++ debian/invirt-console-server.init | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/debian/changelog b/debian/changelog index d737d23..261c72a 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +invirt-console-server (0.1.3) unstable; urgency=low + + * Fix a gen_config -> gen_files + + -- Greg Price Sat, 22 Nov 2008 19:27:59 -0500 + invirt-console-server (0.1.2) unstable; urgency=low * Use gen-files.sh instead of rolling out own diff --git a/debian/invirt-console-server.init b/debian/invirt-console-server.init index b5482e0..1d083a3 100755 --- a/debian/invirt-console-server.init +++ b/debian/invirt-console-server.init @@ -79,7 +79,7 @@ do_stop() do_reload() { - gen_config + gen_files invoke-rc.d conserver-server reload } -- 1.7.9.5 From 3bba29b440aa05f25e898a22d11db58934ca7924 Mon Sep 17 00:00:00 2001 From: Evan Broder Date: Tue, 25 Nov 2008 08:16:32 -0500 Subject: [PATCH 06/16] Clear out the old sudoers block before re-adding it in invirt-console-host svn path=/trunk/packages/invirt-console-host/; revision=1769 --- debian/changelog | 6 ++++++ debian/invirt-console-host.postinst | 3 +++ 2 files changed, 9 insertions(+) diff --git a/debian/changelog b/debian/changelog index 5cd9a54..d0f3ce7 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +invirt-console-host (0.0.10) unstable; urgency=low + + * Clean up the old sudoers block in the postinst before we add it back + + -- Evan Broder Tue, 25 Nov 2008 08:13:32 -0500 + invirt-console-host (0.0.9) unstable; urgency=low * Add cron dependency diff --git a/debian/invirt-console-host.postinst b/debian/invirt-console-host.postinst index d2c7c08..9f4b5a8 100755 --- a/debian/invirt-console-host.postinst +++ b/debian/invirt-console-host.postinst @@ -20,6 +20,9 @@ set -e case "$1" in configure) + # Clean up the old sudoers line before we add it back + perl -i.bak -ne 's%^### (BEGIN|END) invirt-console-host\s*$%%m && ($skip = ($1 eq "BEGIN")); print unless $skip;' /etc/sudoers + cat >>/etc/sudoers < Date: Sun, 7 Dec 2008 10:21:07 -0500 Subject: [PATCH 07/16] Rename invirt-console-server source package to invirt-console svn path=/trunk/packages/invirt-console/; revision=1813 --- debian/changelog | 7 +++++++ debian/control | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/debian/changelog b/debian/changelog index 261c72a..262bc4b 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +invirt-console (0.2.0) unstable; urgency=low + + * Rename source package in preparation for merging invirt-console-server + with invirt-console-host + + -- Evan Broder Sun, 07 Dec 2008 10:10:36 -0500 + invirt-console-server (0.1.3) unstable; urgency=low * Fix a gen_config -> gen_files diff --git a/debian/control b/debian/control index 3015750..b4767da 100644 --- a/debian/control +++ b/debian/control @@ -1,4 +1,4 @@ -Source: invirt-console-server +Source: invirt-console Section: servers Priority: extra Maintainer: Invirt project -- 1.7.9.5 From 0831546bfd6cbfa9ec41f6e82b28d9a84fcf1cec Mon Sep 17 00:00:00 2001 From: Evan Broder Date: Sun, 7 Dec 2008 10:21:19 -0500 Subject: [PATCH 08/16] Move invirt-console/files to invirt-console/server svn path=/trunk/packages/invirt-console/; revision=1814 --- debian/invirt-console-server.install | 2 +- .../etc/conserver/conserver.cf.invirt | 0 {files => server}/etc/conserver/console.cf | 0 .../etc/conserver/invirt-hosts.cf.mako | 0 {files => server}/etc/issue.net.no_tkt.mako | 0 {files => server}/etc/issue.net.no_user | 0 {files => server}/etc/motd.invirt | 0 {files => server}/etc/nss-pgsql.conf.mako | 0 .../etc/remctl/acl/invirt-console-server.mako | 0 {files => server}/etc/remctl/conf.d/invirt-console | 0 {files => server}/usr/bin/invirt-consolefs | 0 {files => server}/usr/bin/invirt-consolesh | 0 {files => server}/usr/sbin/invirt-console-update | 0 13 files changed, 1 insertion(+), 1 deletion(-) rename {files => server}/etc/conserver/conserver.cf.invirt (100%) rename {files => server}/etc/conserver/console.cf (100%) rename {files => server}/etc/conserver/invirt-hosts.cf.mako (100%) rename {files => server}/etc/issue.net.no_tkt.mako (100%) rename {files => server}/etc/issue.net.no_user (100%) rename {files => server}/etc/motd.invirt (100%) rename {files => server}/etc/nss-pgsql.conf.mako (100%) rename {files => server}/etc/remctl/acl/invirt-console-server.mako (100%) rename {files => server}/etc/remctl/conf.d/invirt-console (100%) rename {files => server}/usr/bin/invirt-consolefs (100%) rename {files => server}/usr/bin/invirt-consolesh (100%) rename {files => server}/usr/sbin/invirt-console-update (100%) diff --git a/debian/invirt-console-server.install b/debian/invirt-console-server.install index 9da31b3..bf66dce 100644 --- a/debian/invirt-console-server.install +++ b/debian/invirt-console-server.install @@ -1 +1 @@ -files/* . +server/* . diff --git a/files/etc/conserver/conserver.cf.invirt b/server/etc/conserver/conserver.cf.invirt similarity index 100% rename from files/etc/conserver/conserver.cf.invirt rename to server/etc/conserver/conserver.cf.invirt diff --git a/files/etc/conserver/console.cf b/server/etc/conserver/console.cf similarity index 100% rename from files/etc/conserver/console.cf rename to server/etc/conserver/console.cf diff --git a/files/etc/conserver/invirt-hosts.cf.mako b/server/etc/conserver/invirt-hosts.cf.mako similarity index 100% rename from files/etc/conserver/invirt-hosts.cf.mako rename to server/etc/conserver/invirt-hosts.cf.mako diff --git a/files/etc/issue.net.no_tkt.mako b/server/etc/issue.net.no_tkt.mako similarity index 100% rename from files/etc/issue.net.no_tkt.mako rename to server/etc/issue.net.no_tkt.mako diff --git a/files/etc/issue.net.no_user b/server/etc/issue.net.no_user similarity index 100% rename from files/etc/issue.net.no_user rename to server/etc/issue.net.no_user diff --git a/files/etc/motd.invirt b/server/etc/motd.invirt similarity index 100% rename from files/etc/motd.invirt rename to server/etc/motd.invirt diff --git a/files/etc/nss-pgsql.conf.mako b/server/etc/nss-pgsql.conf.mako similarity index 100% rename from files/etc/nss-pgsql.conf.mako rename to server/etc/nss-pgsql.conf.mako diff --git a/files/etc/remctl/acl/invirt-console-server.mako b/server/etc/remctl/acl/invirt-console-server.mako similarity index 100% rename from files/etc/remctl/acl/invirt-console-server.mako rename to server/etc/remctl/acl/invirt-console-server.mako diff --git a/files/etc/remctl/conf.d/invirt-console b/server/etc/remctl/conf.d/invirt-console similarity index 100% rename from files/etc/remctl/conf.d/invirt-console rename to server/etc/remctl/conf.d/invirt-console diff --git a/files/usr/bin/invirt-consolefs b/server/usr/bin/invirt-consolefs similarity index 100% rename from files/usr/bin/invirt-consolefs rename to server/usr/bin/invirt-consolefs diff --git a/files/usr/bin/invirt-consolesh b/server/usr/bin/invirt-consolesh similarity index 100% rename from files/usr/bin/invirt-consolesh rename to server/usr/bin/invirt-consolesh diff --git a/files/usr/sbin/invirt-console-update b/server/usr/sbin/invirt-console-update similarity index 100% rename from files/usr/sbin/invirt-console-update rename to server/usr/sbin/invirt-console-update -- 1.7.9.5 From 5450e070e4964814fd3fef48d573a5c0a4e97f0e Mon Sep 17 00:00:00 2001 From: Evan Broder Date: Sun, 7 Dec 2008 10:29:56 -0500 Subject: [PATCH 09/16] Create the empty /etc/conserver/conf.d directory using .dirs Now git-svn won't ignore it! svn path=/trunk/packages/invirt-console/; revision=1820 --- debian/changelog | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/debian/changelog b/debian/changelog index 0d439ce..b1da500 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +invirt-console (0.2.1) unstable; urgency=low + + * Be sure to create the /etc/conserver/conf.d directory + + -- Evan Broder Sun, 07 Dec 2008 10:29:35 -0500 + invirt-console (0.2.0) unstable; urgency=low * Rename source package in preparation for merging invirt-console-server -- 1.7.9.5 From 40cdbc6908e8815ee0a2550a49d2e1388441b333 Mon Sep 17 00:00:00 2001 From: Evan Broder Date: Sun, 7 Dec 2008 10:54:32 -0500 Subject: [PATCH 10/16] Whoops - actually add the .dirs file svn path=/trunk/packages/invirt-console/; revision=1821 --- debian/invirt-console-server.dirs | 1 + 1 file changed, 1 insertion(+) create mode 100644 debian/invirt-console-server.dirs diff --git a/debian/invirt-console-server.dirs b/debian/invirt-console-server.dirs new file mode 100644 index 0000000..c1ba6f4 --- /dev/null +++ b/debian/invirt-console-server.dirs @@ -0,0 +1 @@ +etc/conserver/conf.d -- 1.7.9.5 From c11d49cd44fdbe0ffb8836383db1e3b0af270cfe Mon Sep 17 00:00:00 2001 From: Evan Broder Date: Mon, 8 Dec 2008 09:28:12 -0500 Subject: [PATCH 11/16] Create the /consolefs directory for the console server svn path=/trunk/packages/invirt-console/; revision=1827 --- debian/changelog | 6 ++++++ debian/invirt-console-server.dirs | 1 + 2 files changed, 7 insertions(+) diff --git a/debian/changelog b/debian/changelog index b1da500..4a3bd0c 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +invirt-console (0.2.2) unstable; urgency=low + + * Also create the /consolefs directory + + -- Evan Broder Mon, 08 Dec 2008 09:27:55 -0500 + invirt-console (0.2.1) unstable; urgency=low * Be sure to create the /etc/conserver/conf.d directory diff --git a/debian/invirt-console-server.dirs b/debian/invirt-console-server.dirs index c1ba6f4..039df59 100644 --- a/debian/invirt-console-server.dirs +++ b/debian/invirt-console-server.dirs @@ -1 +1,2 @@ etc/conserver/conf.d +consolefs -- 1.7.9.5 From 8147aa8f68b0a80a8a8519f9f6a79ef9c7094ce4 Mon Sep 17 00:00:00 2001 From: Evan Broder Date: Mon, 8 Dec 2008 09:48:05 -0500 Subject: [PATCH 12/16] And...also create /home/machines svn path=/trunk/packages/invirt-console/; revision=1830 --- debian/changelog | 6 ++++++ debian/invirt-console-server.dirs | 1 + 2 files changed, 7 insertions(+) diff --git a/debian/changelog b/debian/changelog index 4a3bd0c..9d4be73 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +invirt-console (0.2.3) unstable; urgency=low + + * ...and /home/machines + + -- Evan Broder Mon, 08 Dec 2008 09:47:20 -0500 + invirt-console (0.2.2) unstable; urgency=low * Also create the /consolefs directory diff --git a/debian/invirt-console-server.dirs b/debian/invirt-console-server.dirs index 039df59..785b30a 100644 --- a/debian/invirt-console-server.dirs +++ b/debian/invirt-console-server.dirs @@ -1,2 +1,3 @@ etc/conserver/conf.d consolefs +home/machines -- 1.7.9.5 From 8e104cbce063e8768a11671543c0016b873893fb Mon Sep 17 00:00:00 2001 From: Evan Broder Date: Wed, 10 Dec 2008 23:21:24 -0500 Subject: [PATCH 13/16] config.{authn[0] => kerberos}.realm svn path=/trunk/packages/invirt-console/; revision=1836 --- debian/changelog | 6 ++++++ host/usr/sbin/invirt-update-conserver | 2 +- server/etc/remctl/acl/invirt-console-server.mako | 2 +- server/usr/bin/invirt-consolefs | 2 +- 4 files changed, 9 insertions(+), 3 deletions(-) diff --git a/debian/changelog b/debian/changelog index 9d4be73..ab643f5 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +invirt-console (0.2.4) unstable; urgency=low + + * config.{authn[0] => kerberos}.realm + + -- Evan Broder Wed, 10 Dec 2008 23:06:24 -0500 + invirt-console (0.2.3) unstable; urgency=low * ...and /home/machines diff --git a/host/usr/sbin/invirt-update-conserver b/host/usr/sbin/invirt-update-conserver index 9a7fd3c..3d77c8b 100755 --- a/host/usr/sbin/invirt-update-conserver +++ b/host/usr/sbin/invirt-update-conserver @@ -18,7 +18,7 @@ def reload_conserver(): if __name__ == '__main__': hostname = socket.getfqdn().lower() - realm = config.authn[0].realm + realm = config.kerberos.realm principal = 'host/'+hostname+'@'+realm conftext = '\n'.join('console %s { master %s; }' % (vm, hostname) for vm in live_vms()) diff --git a/server/etc/remctl/acl/invirt-console-server.mako b/server/etc/remctl/acl/invirt-console-server.mako index f2fffe3..3443721 100644 --- a/server/etc/remctl/acl/invirt-console-server.mako +++ b/server/etc/remctl/acl/invirt-console-server.mako @@ -1,4 +1,4 @@ <% from invirt.config import structs as cfg %>\ % for h in cfg.hosts: -host/${h.hostname}@${cfg.authn[0].realm} +host/${h.hostname}@${cfg.kerberos.realm} % endfor diff --git a/server/usr/bin/invirt-consolefs b/server/usr/bin/invirt-consolefs index a3f75ec..4fdd9dd 100755 --- a/server/usr/bin/invirt-consolefs +++ b/server/usr/bin/invirt-consolefs @@ -85,7 +85,7 @@ class ConsoleFS(routefs.RouteFS): (princ, realm) = user.split('@') else: princ = user - realm = config.authn[0].realm + realm = config.kerberos.realm return princ.replace('.', '/') + '@' + realm -- 1.7.9.5 From ebd2f97c510d8196e23f02ef6d814c3fa73c7854 Mon Sep 17 00:00:00 2001 From: Greg Price Date: Fri, 19 Dec 2008 23:38:01 -0500 Subject: [PATCH 14/16] invirt-console: update description svn path=/trunk/packages/invirt-console/; revision=1858 --- debian/changelog | 6 ++++++ debian/control | 5 +++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/debian/changelog b/debian/changelog index ab643f5..9a88811 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +invirt-console (0.2.5) unstable; urgency=low + + * update/rewrite description + + -- Greg Price Fri, 19 Dec 2008 22:39:00 -0500 + invirt-console (0.2.4) unstable; urgency=low * config.{authn[0] => kerberos}.realm diff --git a/debian/control b/debian/control index 4969f5c..33d464d 100644 --- a/debian/control +++ b/debian/control @@ -21,5 +21,6 @@ Architecture: all Provides: ${diverted-files} Conflicts: ${diverted-files} Depends: ${shlibs:Depends}, ${misc:Depends}, conserver-server, remctl-client, invirt-base, cron -Description: SIPB Xen serial console server server - This configures the VMM for the server-side of the console server +Description: Invirt serial-console host config + This package sets up an Invirt host to work with the serial-console + proxy server. -- 1.7.9.5 From 62fd79f25050dad617c000c7cc969510b2500982 Mon Sep 17 00:00:00 2001 From: Anders Kaseorg Date: Fri, 6 Feb 2009 04:32:00 -0500 Subject: [PATCH 15/16] Turn off autocompletion of console names. svn path=/trunk/packages/invirt-console/; revision=2099 --- debian/changelog | 6 ++++++ host/etc/conserver/conserver.cf.invirt | 1 + server/etc/conserver/conserver.cf.invirt | 1 + 3 files changed, 8 insertions(+) diff --git a/debian/changelog b/debian/changelog index 9a88811..1260150 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +invirt-console (0.2.6) unstable; urgency=high + + * Turn off autocompletion of console names. (LP: #326075) + + -- Anders Kaseorg Fri, 06 Feb 2009 04:28:36 -0500 + invirt-console (0.2.5) unstable; urgency=low * update/rewrite description diff --git a/host/etc/conserver/conserver.cf.invirt b/host/etc/conserver/conserver.cf.invirt index 1b92380..19d0afe 100644 --- a/host/etc/conserver/conserver.cf.invirt +++ b/host/etc/conserver/conserver.cf.invirt @@ -1,5 +1,6 @@ config * { sslrequired yes; + autocomplete no; } # If no consoles are defined, as is the case when the host first boots diff --git a/server/etc/conserver/conserver.cf.invirt b/server/etc/conserver/conserver.cf.invirt index 6d7130e..11f05a2 100644 --- a/server/etc/conserver/conserver.cf.invirt +++ b/server/etc/conserver/conserver.cf.invirt @@ -1,6 +1,7 @@ # default config for console config * { sslrequired yes; + autocomplete no; } # If no consoles are defined, as is the case when the host first boots # up, conserver will quit. This keeps it running. -- 1.7.9.5 From a2cf90a67c235d1a1d5738d2141480faa09aa93c Mon Sep 17 00:00:00 2001 From: Evan Broder Date: Tue, 17 Feb 2009 04:29:46 -0500 Subject: [PATCH 16/16] Use a simpler query construct in ConsoleFS. svn path=/trunk/packages/invirt-console/; revision=2157 --- debian/changelog | 6 ++++++ server/usr/bin/invirt-consolefs | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/debian/changelog b/debian/changelog index 1260150..16b71fc 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +invirt-console (0.2.7) unstable; urgency=low + + * Use a simpler query construct in ConsoleFS. + + -- Evan Broder Tue, 17 Feb 2009 04:23:05 -0500 + invirt-console (0.2.6) unstable; urgency=high * Turn off autocompletion of console names. (LP: #326075) diff --git a/server/usr/bin/invirt-consolefs b/server/usr/bin/invirt-consolefs index 4fdd9dd..359ad16 100755 --- a/server/usr/bin/invirt-consolefs +++ b/server/usr/bin/invirt-consolefs @@ -46,7 +46,7 @@ class ConsoleFS(routefs.RouteFS): if time() - self.lasttime > 5: self.lasttime = time() database.clear_cache() - self.machines = dict((machine.name, machine) for machine in database.session.query(database.Machine).all()) + self.machines = dict((machine.name, machine) for machine in database.Machine.query.all()) def getMachines(self, **kw): self.recache() -- 1.7.9.5