Your message dated Sun, 28 Jul 2019 07:49:48 +0000
with message-id <[email protected]>
and subject line Bug#930113: fixed in tor 0.4.1.4-rc-1
has caused the Debian Bug report #930113,
regarding tor: please provide runscript file
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
930113: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=930113
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Source: tor
Version: 0.4.0.5-1
Severity: wishlist
Tags: patch
User: [email protected]
Usertags: runscript

Dear maintainer,

please include native script for runit init system into 'tor'.
Below is diff aganist latest package release (0.4.0.5-1).

Here are some links:

 * http://smarden.org/runit -- more information about 'runit'
 * https://bugs.debian.org/746715 -- technical committe position
   on support of init systems, other then sysvinit.

From d7ca30748d31efaf37dbd37e9cf8f1e7464ed84f Mon Sep 17 00:00:00 2001
From: Dmitry Bogatov <[email protected]>
Date: Thu, 6 Jun 2019 10:00:28 +0000
Subject: [PATCH] Add integration for runit init

---
 debian/control                                |  3 ++-
 debian/rules                                  |  1 +
 debian/tor.install                            |  2 ++
 debian/tor.runit                              |  1 +
 debian/tor.runscript/conf/MAX_FILEDESCRIPTORS |  1 +
 debian/tor.runscript/run                      | 23 +++++++++++++++++++
 6 files changed, 30 insertions(+), 1 deletion(-)
 create mode 100644 debian/tor.runit
 create mode 100644 debian/tor.runscript/conf/MAX_FILEDESCRIPTORS
 create mode 100644 debian/tor.runscript/run

diff --git a/debian/control b/debian/control
index 74ba641..e240b05 100644
--- a/debian/control
+++ b/debian/control
@@ -2,7 +2,7 @@ Source: tor
 Section: net
 Priority: optional
 Maintainer: Peter Palfrader <[email protected]>
-Build-Depends: debhelper (>= 9.20160114), quilt, libssl-dev, zlib1g-dev, 
libevent-dev (>= 1.1), asciidoc (>= 8.2), docbook-xml, docbook-xsl, xmlto, 
dh-apparmor, libseccomp-dev [amd64 i386], dh-systemd [linux-any], 
libsystemd-dev [linux-any], pkg-config [linux-any], libcap-dev [linux-any], 
dh-autoreconf, liblzma-dev, libzstd-dev
+Build-Depends: debhelper (>= 9.20160114), quilt, libssl-dev, zlib1g-dev, 
libevent-dev (>= 1.1), asciidoc (>= 8.2), docbook-xml, docbook-xsl, xmlto, 
dh-apparmor, libseccomp-dev [amd64 i386], dh-systemd [linux-any], 
libsystemd-dev [linux-any], pkg-config [linux-any], libcap-dev [linux-any], 
dh-autoreconf, liblzma-dev, libzstd-dev, dh-runit (>= 2.8.8)
 Build-Conflicts: libnacl-dev, libseccomp-dev [!amd64 !i386]
 Standards-Version: 3.9.8
 Homepage: https://www.torproject.org/
@@ -14,6 +14,7 @@ Architecture: any
 Depends: ${shlibs:Depends}, adduser, ${misc:Depends}, lsb-base
 Pre-Depends: ${misc:Pre-Depends}
 Conflicts: libssl0.9.8 (<< 0.9.8g-9)
+Breaks: ${runit:Breaks}
 Recommends: logrotate, tor-geoipdb, torsocks
 Suggests: mixmaster, torbrowser-launcher, socat, tor-arm, apparmor-utils, 
tor-arm, obfs4proxy
 Description: anonymizing overlay network for TCP
diff --git a/debian/rules b/debian/rules
index 710d166..22c093a 100755
--- a/debian/rules
+++ b/debian/rules
@@ -26,6 +26,7 @@ endif
                $@ \
                --with quilt \
                --with autoreconf \
+               --with runit \
                $(dhoptions) \
                --builddirectory=build \
                --parallel
diff --git a/debian/tor.install b/debian/tor.install
index 97da1ca..566d16a 100644
--- a/debian/tor.install
+++ b/debian/tor.install
@@ -11,3 +11,5 @@ debian/systemd/tor.service lib/systemd/system
 debian/systemd/[email protected] lib/systemd/system
 debian/systemd/[email protected] lib/systemd/system
 debian/systemd/tor-generator lib/systemd/system-generators
+
+debian/tor.runscript/conf/* /etc/tor/conf
diff --git a/debian/tor.runit b/debian/tor.runit
new file mode 100644
index 0000000..5ca5bca
--- /dev/null
+++ b/debian/tor.runit
@@ -0,0 +1 @@
+debian/tor.runscript name=tor,logscript,since=0.3.5.8-1+runit
diff --git a/debian/tor.runscript/conf/MAX_FILEDESCRIPTORS 
b/debian/tor.runscript/conf/MAX_FILEDESCRIPTORS
new file mode 100644
index 0000000..252cb66
--- /dev/null
+++ b/debian/tor.runscript/conf/MAX_FILEDESCRIPTORS
@@ -0,0 +1 @@
+8192
diff --git a/debian/tor.runscript/run b/debian/tor.runscript/run
new file mode 100644
index 0000000..b6854c6
--- /dev/null
+++ b/debian/tor.runscript/run
@@ -0,0 +1,23 @@
+#!/usr/bin/env /lib/runit/invoke-run
+readonly daemon=/usr/bin/tor
+exec 2>&1
+
+ulimit -n "${MAX_FILEDESCRIPTORS}"
+
+# default invocation
+set -- "${daemon}"                                             \
+       --defaults-torrc /usr/share/tor/tor-service-defaults-torrc \
+       -f /etc/tor/torrc                                          \
+       --Log 'notice stdout'                                      \
+       --RunAsDaemon 0
+
+if ! "$@" --verify-config ; then
+       echo "persistent error: Tor configuration is not valid"
+       exec sv down tor
+fi
+
+if aa-status --enabled ; then
+       set -- aa-exec --profile=system_tor -- "$@"
+fi
+
+exec "$@"

--- End Message ---
--- Begin Message ---
Source: tor
Source-Version: 0.4.1.4-rc-1

We believe that the bug you reported is fixed in the latest version of
tor, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Peter Palfrader <[email protected]> (supplier of updated tor package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Format: 1.8
Date: Fri, 26 Jul 2019 09:32:22 +0200
Source: tor
Architecture: source
Version: 0.4.1.4-rc-1
Distribution: experimental
Urgency: medium
Maintainer: Peter Palfrader <[email protected]>
Changed-By: Peter Palfrader <[email protected]>
Closes: 930113 932125
Changes:
 tor (0.4.1.4-rc-1) experimental; urgency=medium
 .
   * New upstream version.
   * Use start-stop-daemon in the init script instead of ps.  Using
     ps would require us to depend on procps when all we want is to
     check if a process exists (closes: #932125).
   * Add untested/unsupported runit support (closes: #930113).
     Use the patch provided there, except also fix the backporting scripts,
     change the somewhat low number of FDs to 65536, change a variable
     name as to not suggest this has anything to do with tor authority
     directory servers.
Checksums-Sha1:
 96d1b747d0891fcba501d596c8b6b6a5a7c5c196 2003 tor_0.4.1.4-rc-1.dsc
 8d8c92a3ae4d5d29c86353f917f2e471cd4aba3e 7369948 tor_0.4.1.4-rc.orig.tar.gz
 c9ed78cdc7c93a51a1cfe74bd8091ce3776d145b 51531 tor_0.4.1.4-rc-1.diff.gz
Checksums-Sha256:
 bad6ded659cca174ecbdf374c84037fcebe2d04fd5addc93fa9e4cc27d019064 2003 
tor_0.4.1.4-rc-1.dsc
 1e92b655a19062209c747c2f328f2b52009d8256a9514705bb8a6cfebb21b3ae 7369948 
tor_0.4.1.4-rc.orig.tar.gz
 c77d7f90a770230d824bd69ae8c26751b369781d5825faac28771b57cad368e7 51531 
tor_0.4.1.4-rc-1.diff.gz
Files:
 0a33bb3236621dcca1c3e4c732813d92 2003 net optional tor_0.4.1.4-rc-1.dsc
 7a7b414dca81b87d3c51569fe5dce376 7369948 net optional 
tor_0.4.1.4-rc.orig.tar.gz
 cd042acf00c14a8ae9f47f2ef1075951 51531 net optional tor_0.4.1.4-rc-1.diff.gz

-----BEGIN PGP SIGNATURE-----

iQEzBAEBCAAdFiEEs4PXhajJL968BgN2hgLIIDhyMx8FAl09TyEACgkQhgLIIDhy
Mx8NGAf/VYSoh9uDauRjQg/i/CN0KwZVYHMBlltas7Fyun0ntakyv71Le184/qnb
wfKXB52rXEMN39xiFqpkat33BxbdE6Rg09/g13sZfxo8e6VoZih8RpQAlK9m70dn
kjEKHDm9RXfKx/4RI/ZM7xYivRgdZHjAWg/zSJPiKQbMYsFmr4PrwOjA1DZazGcn
+sUebmXsfa/zWKF5fn3gsAroXWpsWG/BxGdRfAj/W1KxGY5XdV+cSJtsJd0NJq1h
xOwcqAt1ixvUTDPbChqn3WEW/wz8RrX40O69uZIIofrWX+hAWQvlgYJpvk7Gkwc6
bF3x8I8h6Wv3NtVSEhvtD5IbicUKuw==
=DdmC
-----END PGP SIGNATURE-----

--- End Message ---

Reply via email to