runit

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README

commit 050880edfe7805f1c7f06f9d5062c98cf9906f1c
parent de013385c2b03fe687bc09414575219eb2b42f25
Author: Gerrit Pape <pape@smarden.org>
Date:   Fri, 11 Oct 2002 12:21:34 +0000

  * rework debian packaging to be debian policy compliant.
  * runit: add lintian override: statically-linked-binary; the runit
    programs are knowingly compiled statically with the diet libc.

Diffstat:
Adebian/2 | 8++++++++
Ddebian/README.Debian | 6------
Adebian/changelog | 102+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Mdebian/control | 1+
Mdebian/rules | 5++---
Adebian/runit-run.README.Debian | 17+++++++++++++++++
Adebian/runit-run.changelog | 6++++++
Adebian/runit-run.dirs | 2++
Adebian/runit-run.docs | 0
Adebian/runit-run.links | 9+++++++++
Adebian/runit-run.postinst | 50++++++++++++++++++++++++++++++++++++++++++++++++++
Adebian/runit-run.postrm | 44++++++++++++++++++++++++++++++++++++++++++++
Adebian/runit-run.preinst | 56++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Adebian/runit.dirs | 4++++
Adebian/runit.docs | 2++
Adebian/runit.lintian | 1+
Adebian/runit.preinst | 41+++++++++++++++++++++++++++++++++++++++++
Adebian/runsvctrl.8 | 0
Adebian/runsvstat.8 | 0
Arunit-run/Makefile | 6++++++
Arunit-run/getty-2/run | 3+++
Arunit-run/getty-3/run | 3+++
Arunit-run/getty-4/run | 3+++
23 files changed, 360 insertions(+), 9 deletions(-)

diff --git a/debian/2 b/debian/2 @@ -0,0 +1,8 @@ +#!/bin/sh + +PATH=/usr/local/bin:/usr/local/sbin:/bin:/sbin:/usr/bin:/usr/sbin:/usr/X11R6/bin + +runsvchdir default >/dev/null + +exec env - PATH=$PATH \ +runsvdir /var/service 'log: ...........................................................................................................................................................................................................................................................................................................................................................................................................' diff --git a/debian/README.Debian b/debian/README.Debian @@ -1,6 +0,0 @@ -runit for Debian ----------------- - -<possible notes regarding this package - if none, delete this file> - - -- Gerrit Pape <pape@smarden.org>, Fri, 11 Oct 2002 10:13:39 +0200 diff --git a/debian/changelog b/debian/changelog @@ -0,0 +1,102 @@ +runit (0.7.0-2) unstable; urgency=low + + * rework debian packaging to be debian policy compliant. + * runit: add lintian override: statically-linked-binary; the runit + programs are knowingly compiled statically with the diet libc. + + -- Gerrit Pape <pape@smarden.org> Fri, 11 Oct 2002 13:59:57 +0200 + +runit (0.7.0-1) sarge; urgency=low + + * See /package/admin/runit/package/CHANGES. + * preinst: new; create hardlink /sbin/runit.old -> /sbin/runit on + upgrade. + + -- Gerrit Pape <pape@smarden.org> Mon, 7 Oct 2002 11:25:47 +0200 + +runit (0.6.0-1) sarge; urgency=low + + * See /package/admin/runit/package/CHANGES. + + -- Gerrit Pape <pape@smarden.org> Fri, 27 Sep 2002 16:35:53 +0200 + +runit (0.5.2-1) sarge; urgency=low + + * See /package/admin/runit/package/CHANGES. + + -- Gerrit Pape <pape@smarden.org> Mon, 23 Sep 2002 12:06:09 +0200 + +runit (0.5.0-1) sarge; urgency=low + + * See /package/admin/runit/package/CHANGES. + + -- Gerrit Pape <pape@smarden.org> Wed, 28 Aug 2002 13:23:11 +0200 + +runit (0.4.1-1) woody; urgency=low + + * See /package/admin/runit/package/CHANGES. + + -- Gerrit Pape <pape@smarden.org> Mon, 24 Jun 2002 16:07:53 +0200 + +runit (0.4.0-1) woody; urgency=low + + * See /package/admin/runit/package/CHANGES. + * build and install the utmpset program. + + -- Gerrit Pape <pape@smarden.org> Sun, 19 May 2002 12:31:09 +0200 + +runit (0.3.2-2) woody; urgency=low + + * getty service directory /etc/runit/getty-tty5 moved to + /etc/runit/getty-5 according to updated doc/replaceinit.html. + * compiled with dietlibc 0.16. + + -- Gerrit Pape <pape@smarden.org> Sat, 30 Mar 2002 13:05:28 +0100 + +runit (0.3.2-1) woody; urgency=low + + * See /package/admin/runit/package/CHANGES. + + -- Gerrit Pape <pape@smarden.org> Wed, 13 Feb 2002 10:56:17 +0100 + +runit (0.3.1-1) woody; urgency=low + + * See /package/admin/runit/package/CHANGES. + + -- Gerrit Pape <pape@smarden.org> Sun, 3 Feb 2002 16:30:55 +0100 + +runit (0.3.0-1) woody; urgency=low + + * See /package/admin/runit/package/CHANGES. + + -- Gerrit Pape <pape@smarden.org> Tue, 29 Jan 2002 19:54:06 +0100 + +runit (0.2.7-1) woody; urgency=low + + * See /package/admin/runit/package/CHANGES. + + -- Gerrit Pape <pape@smarden.org> Tue, 1 Jan 2002 16:20:14 +0100 + +runit (0.2.6-1) woody; urgency=low + + * See /package/admin/runit/package/CHANGES. + * manpages svwait*.8 installed. + + -- Gerrit Pape <pape@smarden.org> Sun, 30 Dec 2001 17:29:29 +0100 + +runit (0.2.3-1) woody; urgency=low + + * See /package/admin/runit/package/CHANGES. + * Build-Depends on dietlibc, uses diet to compile programs. + + -- Gerrit Pape <pape@smarden.org> Sat, 22 Dec 2001 20:37:03 +0100 + +runit (0.1.1-1) woody; urgency=low + + * Initial Release. + + -- Gerrit Pape <pape@smarden.org> Tue, 20 Nov 2001 11:56:58 +0100 + +Local variables: +mode: debian-changelog +End: diff --git a/debian/control b/debian/control @@ -25,6 +25,7 @@ Description: a UNIX init scheme with service supervision Package: runit-run Architecture: all Depends: runit, sysvinit (>> 2.84-0) +Replaces: daemontools-run Description: a UNIX init scheme with service supervision runit is a daemontools alike replacement for SysV-init and other init schemes. runit currently runs on Debian GNU/Linux, OpenBSD, FreeBSD, diff --git a/debian/rules b/debian/rules @@ -97,9 +97,8 @@ install: build install -m0700 admin/runit/etc/debian/1 \ $(CURDIR)/debian/runit/etc/runit/1 - sed -e 's}^PATH=/command:}PATH=}g;\ - s}^runsvdir /service}runsvdir /var/service}g' \ - <admin/runit/etc/debian/2 >$(CURDIR)/debian/runit/etc/runit/2 + install -m0700 debian/2 \ + $(CURDIR)/debian/runit/etc/runit/2 chmod 0700 $(CURDIR)/debian/runit/etc/runit/2 sed -e 's}^PATH=.*}PATH=/sbin:/bin:/usr/sbin:/usr/bin}g' \ <admin/runit/etc/debian/3 >$(CURDIR)/debian/runit/etc/runit/3 diff --git a/debian/runit-run.README.Debian b/debian/runit-run.README.Debian @@ -0,0 +1,17 @@ +runit-run for Debian +-------------------- + +This package diverts sysvinit's /sbin/init binary. Use + + # /sbin/init.sysv 6 + +to reboot the system with runit as process no 1 after the first +installation of runit-run. + +This package also sets up the runit package to support runlevels, see +http://smarden.org/runit/runlevels.html . + +For service migration from sysvinit to runit, please see +http://smarden.org/runit/replaceinit.html step 5. + + -- Gerrit Pape <pape@smarden.org>, Fri, 11 Oct 2002 14:14:06 +0200 diff --git a/debian/runit-run.changelog b/debian/runit-run.changelog @@ -0,0 +1,6 @@ +runit (0.1.0) unstable; urgency=low + + * Initial Release. + + -- Gerrit Pape <pape@smarden.org> Fri, 11 Oct 2002 10:13:39 +0200 + diff --git a/debian/runit-run.dirs b/debian/runit-run.dirs @@ -0,0 +1,2 @@ +etc/runit/runsvdir/default +etc/runit/runsvdir/single diff --git a/debian/runit-run.docs b/debian/runit-run.docs diff --git a/debian/runit-run.links b/debian/runit-run.links @@ -0,0 +1,9 @@ +/sbin/runit-init /sbin/init +/usr/share/man/man8/runit-init.8.gz /usr/share/man/man8/init.8.gz +/etc/runit/runsvdir/default /etc/runit/runsvdir/current +/etc/runit/runsvdir/current /var/service +/etc/runit/getty-5 /etc/runit/runsvdir/single/getty-5 +/etc/runit/getty-2 /etc/runit/runsvdir/default/getty-2 +/etc/runit/getty-3 /etc/runit/runsvdir/default/getty-3 +/etc/runit/getty-4 /etc/runit/runsvdir/default/getty-4 +/etc/runit/getty-5 /etc/runit/runsvdir/default/getty-5 diff --git a/debian/runit-run.postinst b/debian/runit-run.postinst @@ -0,0 +1,50 @@ +#! /bin/sh +# postinst script for runit-run +# +# see: dh_installdeb(1) + +set -e + +# summary of how this script can be called: +# * <postinst> `configure' <most-recently-configured-version> +# * <old-postinst> `abort-upgrade' <new version> +# * <conflictor's-postinst> `abort-remove' `in-favour' <package> +# <new-version> +# * <deconfigured's-postinst> `abort-deconfigure' `in-favour' +# <failed-install-package> <version> `removing' +# <conflicting-package> <version> +# for details, see http://www.debian.org/doc/debian-policy/ or +# the debian-policy package +# +# quoting from the policy: +# Any necessary prompting should almost always be confined to the +# post-installation script, and should be protected with a conditional +# so that unnecessary prompting doesn't happen if a package's +# installation fails and the `postinst' is called with `abort-upgrade', +# `abort-remove' or `abort-deconfigure'. + +case "$1" in + configure) + if test -d /var/service && ! test -h /var/service; then + cp -a /var/service/* /etc/runit/runsvdir/default/ + mv /var/service /var/service.old && \ + ln -s /etc/runit/runsvdir/current /var/service + fi + if ! test -e /var/service/getty-5; then + ln -s /etc/runit/getty-5 /var/service/getty-5 + fi + ;; + abort-upgrade|abort-remove|abort-deconfigure) + ;; + *) + echo "postinst called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 diff --git a/debian/runit-run.postrm b/debian/runit-run.postrm @@ -0,0 +1,44 @@ +#! /bin/sh +# postrm script for runit-run +# +# see: dh_installdeb(1) + +set -e + +# summary of how this script can be called: +# * <postrm> `remove' +# * <postrm> `purge' +# * <old-postrm> `upgrade' <new-version> +# * <new-postrm> `failed-upgrade' <old-version> +# * <new-postrm> `abort-install' +# * <new-postrm> `abort-install' <old-version> +# * <new-postrm> `abort-upgrade' <old-version> +# * <disappearer's-postrm> `disappear' <r>overwrit>r> <new-version> +# for details, see http://www.debian.org/doc/debian-policy/ or +# the debian-policy package + +remove_diversion() { + dpkg-divert --package runit-run --remove --rename \ + --divert /sbin/init.sysv /sbin/init + dpkg-divert --package runit-run --remove --rename \ + --divert /usr/share/man/man8/init.sysv.8.gz /usr/share/man/man8/init.8.gz +} + +case "$1" in + remove) + remove_diversion + ;; + purge|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear) + ;; + *) + echo "postrm called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 diff --git a/debian/runit-run.preinst b/debian/runit-run.preinst @@ -0,0 +1,56 @@ +#! /bin/sh +# preinst script for runit-run +# +# see: dh_installdeb(1) + +set -e + +# summary of how this script can be called: +# * <new-preinst> `install' +# * <new-preinst> `install' <old-version> +# * <new-preinst> `upgrade' <old-version> +# * <old-preinst> `abort-upgrade' <new-version> +# +# for details, see http://www.debian.org/doc/debian-policy/ or +# the debian-policy package + +add_diversion() { + dpkg-divert --package runit-run --add --rename \ + --divert /sbin/init.sysv /sbin/init + dpkg-divert --package runit-run --add --rename \ + --divert /usr/share/man/man8/init.sysv.8.gz /usr/share/man/man8/init.8.gz +} + +case "$1" in + install|upgrade) + if [ "$1" = "install" ] ; then + cat <<EOT + +This package diverts sysvinit's /sbin/init binary. Use + + # /sbin/init.sysv 6 + +to reboot the system with runit as process no 1 after installing this +package. + +EOT + echo -n "Will proceed in 10 seconds, press Ctrl-C to abort... " + sleep 10s + echo; echo + add_diversion + fi + ;; + abort-upgrade) + ;; + *) + echo "preinst called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 diff --git a/debian/runit.dirs b/debian/runit.dirs @@ -0,0 +1,4 @@ +sbin +usr/sbin +usr/bin +etc/runit/getty-5 diff --git a/debian/runit.docs b/debian/runit.docs @@ -0,0 +1,2 @@ +admin/runit/package/README +admin/runit/package/THANKS diff --git a/debian/runit.lintian b/debian/runit.lintian @@ -0,0 +1 @@ +runit: statically-linked-binary diff --git a/debian/runit.preinst b/debian/runit.preinst @@ -0,0 +1,41 @@ +#! /bin/sh +# preinst script for runit +# +# see: dh_installdeb(1) + +set -e + +# summary of how this script can be called: +# * <new-preinst> `install' +# * <new-preinst> `install' <old-version> +# * <new-preinst> `upgrade' <old-version> +# * <old-preinst> `abort-upgrade' <new-version> +# +# for details, see http://www.debian.org/doc/debian-policy/ or +# the debian-policy package + + +case "$1" in + install|upgrade) + if [ -n "$2" ]; then + # upgrading + if [ -x /sbin/runit ]; then + rm -f /sbin/runit.old + ln /sbin/runit /sbin/runit.old + fi + fi + ;; + abort-upgrade) + ;; + *) + echo "preinst called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 diff --git a/debian/runsvctrl.8 b/debian/runsvctrl.8 diff --git a/debian/runsvstat.8 b/debian/runsvstat.8 diff --git a/runit-run/Makefile b/runit-run/Makefile @@ -0,0 +1,6 @@ +DESTDIR= + +install: + for i in 2 3 4; do install -d $(DESTDIR)/etc/runit/getty-$$i; done + for i in 2 3 4; do install -m0755 getty-$$i/run \ + $(DESTDIR)/etc/runit/getty-$$i/run; done diff --git a/runit-run/getty-2/run b/runit-run/getty-2/run @@ -0,0 +1,3 @@ +#!/bin/sh +utmpset -w tty2 +exec getty 38400 tty2 linux diff --git a/runit-run/getty-3/run b/runit-run/getty-3/run @@ -0,0 +1,3 @@ +#!/bin/sh +utmpset -w tty3 +exec getty 38400 tty3 linux diff --git a/runit-run/getty-4/run b/runit-run/getty-4/run @@ -0,0 +1,3 @@ +#!/bin/sh +utmpset -w tty4 +exec getty 38400 tty4 linux