[26120] in Source-Commits

home help back first fref pref prev next nref lref last post

/svn/athena r25401 - trunk/debathena/config/reactivate/debian

daemon@ATHENA.MIT.EDU (Geoffrey Thomas)
Mon Sep 19 20:07:20 2011

Date: Mon, 19 Sep 2011 20:07:14 -0400
From: Geoffrey Thomas <geofft@MIT.EDU>
Message-Id: <201109200007.p8K07Evj012342@drugstore.mit.edu>
To: source-commits@mit.edu
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Author: geofft
Date: 2011-09-19 20:07:14 -0400 (Mon, 19 Sep 2011)
New Revision: 25401

Added:
   trunk/debathena/config/reactivate/debian/90debathena-reactivate
   trunk/debathena/config/reactivate/debian/dbus-daemon-launch-helper
   trunk/debathena/config/reactivate/debian/transform_system.conf.debathena
Modified:
   trunk/debathena/config/reactivate/debian/changelog
   trunk/debathena/config/reactivate/debian/control.in
   trunk/debathena/config/reactivate/debian/debathena-reactivate.install
   trunk/debathena/config/reactivate/debian/debathena-reactivate.postinst
   trunk/debathena/config/reactivate/debian/rules
Log:
In reactivate:
  * Run D-Bus-spawned services inside the schroot session, if any.


Added: trunk/debathena/config/reactivate/debian/90debathena-reactivate
===================================================================
--- trunk/debathena/config/reactivate/debian/90debathena-reactivate	                        (rev 0)
+++ trunk/debathena/config/reactivate/debian/90debathena-reactivate	2011-09-20 00:07:14 UTC (rev 25401)
@@ -0,0 +1,18 @@
+#!/bin/sh
+
+set -e
+
+. "$SETUP_DATA_DIR/common-data"
+. "$SETUP_DATA_DIR/common-functions"
+
+if [ -f "$CHROOT_SCRIPT_CONFIG" ]; then
+    . "$CHROOT_SCRIPT_CONFIG"
+elif [ "$STATUS" = "ok" ]; then
+    fatal "script-config file '$CHROOT_SCRIPT_CONFIG' does not exist"
+fi
+
+if [ $STAGE = "setup-start" ]; then
+    info "Adding messagebus to access list for session ${CHROOT_NAME}"
+    sed -i "/^root-users/s/$/,messagebus/" /var/lib/schroot/session/"${CHROOT_NAME}"
+fi
+

Modified: trunk/debathena/config/reactivate/debian/changelog
===================================================================
--- trunk/debathena/config/reactivate/debian/changelog	2011-09-19 23:38:41 UTC (rev 25400)
+++ trunk/debathena/config/reactivate/debian/changelog	2011-09-20 00:07:14 UTC (rev 25401)
@@ -1,3 +1,9 @@
+debathena-reactivate (2.0.26) unstable; urgency=low
+
+  * Run D-Bus-spawned services inside the schroot session, if any.
+
+ -- Geoffrey Thomas <geofft@mit.edu>  Wed, 14 Sep 2011 22:02:58 -0400
+
 debathena-reactivate (2.0.25) unstable; urgency=low
 
   * Stop kexec'ing, because modern distributions are incapable of doing so

Modified: trunk/debathena/config/reactivate/debian/control.in
===================================================================
--- trunk/debathena/config/reactivate/debian/control.in	2011-09-19 23:38:41 UTC (rev 25400)
+++ trunk/debathena/config/reactivate/debian/control.in	2011-09-20 00:07:14 UTC (rev 25401)
@@ -2,7 +2,7 @@
 Section: debathena/net
 Priority: extra
 Maintainer: Debathena Project <debathena@mit.edu>
-Build-Depends: @cdbs@, sudo, schroot
+Build-Depends: @cdbs@, sudo, schroot, dbus
 Standards-Version: 3.8.4
 
 Package: debathena-reactivate

Added: trunk/debathena/config/reactivate/debian/dbus-daemon-launch-helper
===================================================================
--- trunk/debathena/config/reactivate/debian/dbus-daemon-launch-helper	                        (rev 0)
+++ trunk/debathena/config/reactivate/debian/dbus-daemon-launch-helper	2011-09-20 00:07:14 UTC (rev 25401)
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+if hash schroot >/dev/null 2>&1; then
+    session=$(schroot -l --all-sessions)
+fi
+
+if [ -n "$session" ] && [ "$(echo "$session" | wc -l)" -eq 1 ]; then
+    exec schroot -r -c "$session" /lib/dbus-1.0/dbus-daemon-launch-helper "$@"
+else
+    exec /lib/dbus-1.0/dbus-daemon-launch-helper "$@"
+fi

Modified: trunk/debathena/config/reactivate/debian/debathena-reactivate.install
===================================================================
--- trunk/debathena/config/reactivate/debian/debathena-reactivate.install	2011-09-19 23:38:41 UTC (rev 25400)
+++ trunk/debathena/config/reactivate/debian/debathena-reactivate.install	2011-09-20 00:07:14 UTC (rev 25401)
@@ -12,3 +12,5 @@
 debian/mount-athena etc/schroot
 debian/snapshot-run usr/lib/debathena-reactivate
 debian/reactivate usr/lib/debathena-reactivate
+debian/dbus-daemon-launch-helper lib/debathena-reactivate
+debian/90debathena-reactivate etc/schroot/setup.d

Modified: trunk/debathena/config/reactivate/debian/debathena-reactivate.postinst
===================================================================
--- trunk/debathena/config/reactivate/debian/debathena-reactivate.postinst	2011-09-19 23:38:41 UTC (rev 25400)
+++ trunk/debathena/config/reactivate/debian/debathena-reactivate.postinst	2011-09-20 00:07:14 UTC (rev 25401)
@@ -91,7 +91,7 @@
 	cleanup_old_diversion /etc/gdm/PreSession/Default
 	cleanup_old_diversion /etc/gdm/PostSession/Default
 
-	if dpkg --compare-versions "$2" lt 2.0.9~ && \
+	if dpkg --compare-versions "$2" lt 2.0.26~ && \
 	    [ -x /usr/share/update-notifier/notify-reboot-required ]; then
 	    /usr/share/update-notifier/notify-reboot-required
 	fi

Modified: trunk/debathena/config/reactivate/debian/rules
===================================================================
--- trunk/debathena/config/reactivate/debian/rules	2011-09-19 23:38:41 UTC (rev 25400)
+++ trunk/debathena/config/reactivate/debian/rules	2011-09-20 00:07:14 UTC (rev 25401)
@@ -6,7 +6,8 @@
 DEB_TRANSFORM_FILES_debathena-reactivate += \
 	/etc/pam.d/su.debathena \
 	/etc/default/schroot.debathena \
-	/etc/pam.d/schroot.debathena
+	/etc/pam.d/schroot.debathena \
+	/etc/dbus-1/system.conf.debathena
 DEB_REMOVE_FILES_debathena-reactivate += \
 	/etc/xdg/autostart/jockey-gtk.desktop \
 	/etc/xdg/autostart/update-notifier.desktop \

Added: trunk/debathena/config/reactivate/debian/transform_system.conf.debathena
===================================================================
--- trunk/debathena/config/reactivate/debian/transform_system.conf.debathena	                        (rev 0)
+++ trunk/debathena/config/reactivate/debian/transform_system.conf.debathena	2011-09-20 00:07:14 UTC (rev 25401)
@@ -0,0 +1,2 @@
+#!/usr/bin/perl -0p
+s|.*<servicehelper>.*</servicehelper>.*|  <servicehelper>/lib/debathena-reactivate/dbus-daemon-launch-helper</servicehelper>|m or die;


home help back first fref pref prev next nref lref last post