[Pkg-utopia-commits] r1073 - packages/unstable/avahi/debian
Sebastian Dröge
slomo-guest at costa.debian.org
Thu Oct 19 18:02:04 UTC 2006
Author: slomo-guest
Date: 2006-10-19 18:02:03 +0000 (Thu, 19 Oct 2006)
New Revision: 1073
Added:
packages/unstable/avahi/debian/avahi-autoipd.ifdown
packages/unstable/avahi/debian/avahi-autoipd.ifup
Modified:
packages/unstable/avahi/debian/changelog
packages/unstable/avahi/debian/rules
Log:
* add ifupdown scripts for route adding
Added: packages/unstable/avahi/debian/avahi-autoipd.ifdown
===================================================================
--- packages/unstable/avahi/debian/avahi-autoipd.ifdown (rev 0)
+++ packages/unstable/avahi/debian/avahi-autoipd.ifdown 2006-10-19 18:02:03 UTC (rev 1073)
@@ -0,0 +1,28 @@
+#!/bin/sh -e
+# Description: Remove routes to allow communication between machines which
+# only have an IPv4LL address assigned and those which only
+# have a routable address assigned. These were added by
+# /etc/network/if-up.d/avahi-autoipd.
+#
+# See http://developer.apple.com/qa/qa2004/qa1357.html for
+# more information.
+
+
+[ "$IFACE" != "lo" ] || exit 0
+[ "$ADDRFAM" = "inet" ] || exit 0
+[ "$METHOD" = "static" -o "$METHOD" = "dhcp" ] || exit 0
+
+if [ -x /bin/ip ]; then
+ # route already present?
+ [ "`ip route show dev $IFACE | grep ^169.254.0.0/16`" ] || exit 0
+
+ /bin/ip route del 169.254.0.0/16 dev $IFACE metric 1000 scope link || true
+ /bin/ip route del default dev $IFACE metric 1000 scope link || true
+elif [ -x /sbin/route ]; then
+ # route already present?
+ [ "`/sbin/route -n | grep ^169.254.0.0 | grep $IFACE`" ] || exit 0
+
+ /sbin/route del -net 169.254.0.0 netmask 255.255.0.0 dev $IFACE metric 99 || true
+ /sbin/route del default dev $IFACE metric 99 || true
+fi
+
Property changes on: packages/unstable/avahi/debian/avahi-autoipd.ifdown
___________________________________________________________________
Name: svn:executable
+ *
Added: packages/unstable/avahi/debian/avahi-autoipd.ifup
===================================================================
--- packages/unstable/avahi/debian/avahi-autoipd.ifup (rev 0)
+++ packages/unstable/avahi/debian/avahi-autoipd.ifup 2006-10-19 18:02:03 UTC (rev 1073)
@@ -0,0 +1,27 @@
+#!/bin/sh -e
+# Description: Add routes to allow communication between machines which
+# only have an IPv4LL address assigned and those which only
+# have a routable address assigned.
+#
+# See http://developer.apple.com/qa/qa2004/qa1357.html for
+# more information.
+
+[ "$IFACE" != "lo" ] || exit 0
+[ "$ADDRFAM" = "inet" ] || exit 0
+[ "$METHOD" = "static" -o "$METHOD" = "dhcp" ] || exit 0
+
+
+if [ -x /bin/ip ]; then
+ # route already present?
+ [ "`ip route show dev $IFACE | grep ^169.254.0.0/16`" ] && exit 0
+
+ /bin/ip route add 169.254.0.0/16 dev $IFACE metric 1000 scope link
+ /bin/ip route add default dev $IFACE metric 1000 scope link
+elif [ -x /sbin/route ]; then
+ # route already present?
+ [ "`/sbin/route -n | grep ^169.254.0.0 | grep $IFACE`" ] && exit 0
+
+ /sbin/route add -net 169.254.0.0 netmask 255.255.0.0 dev $IFACE metric 99
+ /sbin/route add default dev $IFACE metric 99
+fi
+
Property changes on: packages/unstable/avahi/debian/avahi-autoipd.ifup
___________________________________________________________________
Name: svn:executable
+ *
Modified: packages/unstable/avahi/debian/changelog
===================================================================
--- packages/unstable/avahi/debian/changelog 2006-10-19 16:10:48 UTC (rev 1072)
+++ packages/unstable/avahi/debian/changelog 2006-10-19 18:02:03 UTC (rev 1073)
@@ -16,6 +16,13 @@
+ Set SCRIPTNAME variable in init scripts (Closes: #386957)
* debian/avahi-daemon.postinst:
+ Add the netdev group unless it's already there (Closes: #385495, #389243)
+ * debian/avahi-autoipd.ifup,
+ debian/avahi-autoipd.ifdown,
+ debian/rules:
+ + Add ifupdown scripts to set routes to allow communication between
+ machines which only have an IPv4LL address assigned and those which
+ only have a routable address assigned.
+ See http://developer.apple.com/qa/qa2004/qa1357.html for more information.
-- Sebastian Dröge <slomo at ubuntu.com> Tue, 17 Oct 2006 18:45:52 +0200
Modified: packages/unstable/avahi/debian/rules
===================================================================
--- packages/unstable/avahi/debian/rules 2006-10-19 16:10:48 UTC (rev 1072)
+++ packages/unstable/avahi/debian/rules 2006-10-19 18:02:03 UTC (rev 1073)
@@ -41,6 +41,12 @@
binary-fixup/avahi-daemon binary-fixup/avahi-dnsconfd::
chmod +x debian/$(cdbs_curpkg)/etc/dbus-1/event.d/*
+install/avahi-autoipd::
+ install -D -o root -g root -m 755 debian/avahi-autoipd.ifup \
+ debian/$(cdbs_curpkg)/etc/network/if-up.d/avahi-autoipd
+ install -D -o root -g root -m 755 debian/avahi-autoipd.ifdown \
+ debian/$(cdbs_curpkg)/etc/network/if-down.d/avahi-autoipd
+
common-install-impl::
mv $(DEB_DESTDIR)/etc/dhcp3/dhclient-exit-hooks.d/avahi-autoipd \
$(DEB_DESTDIR)/etc/dhcp3/dhclient-exit-hooks.d/zzz_avahi-autoipd
More information about the Pkg-utopia-commits
mailing list