public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: net-libs/tox/files/
@ 2017-10-27 23:03 Patrice Clement
  0 siblings, 0 replies; 3+ messages in thread
From: Patrice Clement @ 2017-10-27 23:03 UTC (permalink / raw
  To: gentoo-commits

commit:     0a84eca3286f41c523a7aeeeaae35dcf9f40a9ca
Author:     Pavel Frolov <tigrashik <AT> gmail <DOT> com>
AuthorDate: Sat Sep  9 17:11:51 2017 +0000
Commit:     Patrice Clement <monsieurp <AT> gentoo <DOT> org>
CommitDate: Fri Oct 27 23:00:32 2017 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0a84eca3

net-libs/tox: fix init scripts syntax.

Closes: https://bugs.gentoo.org/628706
Closes: https://bugs.gentoo.org/622344
Closes: https://github.com/gentoo/gentoo/pull/5674

 net-libs/tox/files/initd                  | 2 +-
 net-libs/tox/files/tox-bootstrapd.service | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/net-libs/tox/files/initd b/net-libs/tox/files/initd
index f08c59457e5..101d3297056 100644
--- a/net-libs/tox/files/initd
+++ b/net-libs/tox/files/initd
@@ -15,7 +15,7 @@ start() {
 	start-stop-daemon --start \
 		--pidfile "${PIDFILE}" \
 		--user="${TOX_USER}" --group="${TOX_GROUP}" \
-		--exec /usr/bin/tox-bootstrapd -- /etc/tox-bootstrapd.conf
+		--exec /usr/bin/tox-bootstrapd -- --config /etc/tox-bootstrapd.conf
 
 	eend $?
 }

diff --git a/net-libs/tox/files/tox-bootstrapd.service b/net-libs/tox/files/tox-bootstrapd.service
index c841b3c2cd9..ae2f238cd60 100644
--- a/net-libs/tox/files/tox-bootstrapd.service
+++ b/net-libs/tox/files/tox-bootstrapd.service
@@ -8,7 +8,7 @@ Group=tox
 RuntimeDirectory=tox-bootstrapd
 PIDFile=/run/tox-bootstrapd/tox-bootstrapd.pid
 WorkingDirectory=/var/lib/tox-bootstrapd
-ExecStart=/usr/bin/tox-bootstrapd /etc/tox-bootstrapd.conf
+ExecStart=/usr/bin/tox-bootstrapd --config /etc/tox-bootstrapd.conf
 #CapabilityBoundingSet=CAP_NET_BIND_SERVICE
 
 [Install]


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/tox/files/
@ 2020-01-13  6:10 Joonas Niilola
  0 siblings, 0 replies; 3+ messages in thread
From: Joonas Niilola @ 2020-01-13  6:10 UTC (permalink / raw
  To: gentoo-commits

commit:     606a78b496eff09146c70ba53059d5a5c755216c
Author:     Josiah Mullins <jomull01 <AT> protonmail <DOT> com>
AuthorDate: Thu Jan  9 17:31:44 2020 +0000
Commit:     Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Mon Jan 13 06:09:43 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=606a78b4

net-libs/tox: fix to openrc init script.

This commit unifies the location of the PID file for
the daemon in both the openrc script and the daemon's
config file. In addition,the script now checks the keys
directory for existence and correct permissions.

Signed-off-by: Josiah M. Mullins <JoMull01 <AT> protonmail.com>

Closes: https://bugs.gentoo.org/691772
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>

 net-libs/tox/files/initd               |  6 +++++-
 net-libs/tox/files/tox-bootstrapd.conf | 11 +++++++----
 2 files changed, 12 insertions(+), 5 deletions(-)

diff --git a/net-libs/tox/files/initd b/net-libs/tox/files/initd
index 101d3297056..49880897a1a 100644
--- a/net-libs/tox/files/initd
+++ b/net-libs/tox/files/initd
@@ -1,7 +1,10 @@
 #!/sbin/openrc-run
 
 PIDDIR=/run/tox-bootstrapd
-PIDFILE="${PIDDIR}"/tox-bootstrap.pid
+PIDFILE="${PIDDIR}"/tox-bootstrapd.pid
+KEYSDIR=/var/lib/tox-bootstrapd
+TOX_USER=tox
+TOX_GROUP=tox
 
 depend() {
 	need net
@@ -11,6 +14,7 @@ start() {
 	ebegin "Starting tox-dht-bootstrap daemon"
 
 	checkpath -d -q -o "${TOX_USER}":"${TOX_GROUP}" "${PIDDIR}"
+	checkpath -d -q -o "${TOX_USER}":"${TOX_GROUP}" "${KEYSDIR}"
 
 	start-stop-daemon --start \
 		--pidfile "${PIDFILE}" \

diff --git a/net-libs/tox/files/tox-bootstrapd.conf b/net-libs/tox/files/tox-bootstrapd.conf
index 3413f5907d4..34836de6287 100644
--- a/net-libs/tox/files/tox-bootstrapd.conf
+++ b/net-libs/tox/files/tox-bootstrapd.conf
@@ -5,13 +5,16 @@ port = 33445
 
 // A key file is like a password, so keep it where no one can read it.
 // If there is no key file, a new one will be generated.
-// The daemon should have permission to read/write it.
+// If you change this directory, either change the keys directory
+// in the /etc/init.d/tox-dht-daemon script or manually set the
+// new directory to have user "tox" and group "tox".
 keys_file_path = "/var/lib/tox-bootstrapd/keys"
 
 // The PID file written to by the daemon.
-// Make sure that the user that daemon runs as has permissions to write to the
-// PID file.
-pid_file_path = "/var/run/tox-bootstrapd/tox-bootstrapd.pid"
+// Make sure that the user that daemon runs as has permissions to 
+// write to the PID file. If you change this file, please edit the 
+// etc/init.d/tox-dht-daemon script to reflect the change.
+pid_file_path = "/run/tox-bootstrapd/tox-bootstrapd.pid"
 
 // Enable IPv6.
 enable_ipv6 = true


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/tox/files/
@ 2024-07-30 19:09 Pacho Ramos
  0 siblings, 0 replies; 3+ messages in thread
From: Pacho Ramos @ 2024-07-30 19:09 UTC (permalink / raw
  To: gentoo-commits

commit:     51487f2d17caf789b2467dbd89804b9cb9a5fdd8
Author:     Josiah Mullins <JoMull01 <AT> protonmail <DOT> com>
AuthorDate: Wed Apr 24 21:12:54 2024 +0000
Commit:     Pacho Ramos <pacho <AT> gentoo <DOT> org>
CommitDate: Tue Jul 30 19:01:42 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=51487f2d

net-libs/tox: Updated initd and tox-bootstrapd.service

Added some features from the tox main git tree. The
primary change is to increase the maximum number
of files that can be open. This is desired because
the tox dht daemon has around 600 files open; which
is near the default limit of 1024 (on some systems).

Signed-off-by: Josiah Mullins <JoMull01 <AT> protonmail.com>
Signed-off-by: Pacho Ramos <pacho <AT> gentoo.org>

 net-libs/tox/files/initd                  | 2 ++
 net-libs/tox/files/tox-bootstrapd.service | 4 ++++
 2 files changed, 6 insertions(+)

diff --git a/net-libs/tox/files/initd b/net-libs/tox/files/initd
index 49880897a1a0..b5ef4cd4db41 100644
--- a/net-libs/tox/files/initd
+++ b/net-libs/tox/files/initd
@@ -16,6 +16,8 @@ start() {
 	checkpath -d -q -o "${TOX_USER}":"${TOX_GROUP}" "${PIDDIR}"
 	checkpath -d -q -o "${TOX_USER}":"${TOX_GROUP}" "${KEYSDIR}"
 
+	set rc_ulimts 4096
+
 	start-stop-daemon --start \
 		--pidfile "${PIDFILE}" \
 		--user="${TOX_USER}" --group="${TOX_GROUP}" \

diff --git a/net-libs/tox/files/tox-bootstrapd.service b/net-libs/tox/files/tox-bootstrapd.service
index ae2f238cd60c..aec928c7054e 100644
--- a/net-libs/tox/files/tox-bootstrapd.service
+++ b/net-libs/tox/files/tox-bootstrapd.service
@@ -5,7 +5,11 @@ After=network.target
 [Service]
 User=tox
 Group=tox
+#Since the daemon can use around 600 tcp sockets,
+#increase the soft limit on open files to 4096
+LimitNOFILE=4096
 RuntimeDirectory=tox-bootstrapd
+RuntimeDirectoryMode=750
 PIDFile=/run/tox-bootstrapd/tox-bootstrapd.pid
 WorkingDirectory=/var/lib/tox-bootstrapd
 ExecStart=/usr/bin/tox-bootstrapd --config /etc/tox-bootstrapd.conf


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2024-07-30 19:09 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-07-30 19:09 [gentoo-commits] repo/gentoo:master commit in: net-libs/tox/files/ Pacho Ramos
  -- strict thread matches above, loose matches on Subject: below --
2020-01-13  6:10 Joonas Niilola
2017-10-27 23:03 Patrice Clement

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox