summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJosiah Mullins <JoMull01@protonmail.com>2024-04-24 17:12:54 -0400
committerPacho Ramos <pacho@gentoo.org>2024-07-30 21:01:42 +0200
commit51487f2d17caf789b2467dbd89804b9cb9a5fdd8 (patch)
treeb92d5e0d6208516f267487ab04b01e1b989c5567 /net-libs
parentnet-libs/tox: Bump to tox-0.2.19 (diff)
downloadgentoo-51487f2d17caf789b2467dbd89804b9cb9a5fdd8.tar.gz
gentoo-51487f2d17caf789b2467dbd89804b9cb9a5fdd8.tar.bz2
gentoo-51487f2d17caf789b2467dbd89804b9cb9a5fdd8.zip
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@protonmail.com> Signed-off-by: Pacho Ramos <pacho@gentoo.org>
Diffstat (limited to 'net-libs')
-rw-r--r--net-libs/tox/files/initd2
-rw-r--r--net-libs/tox/files/tox-bootstrapd.service4
2 files changed, 6 insertions, 0 deletions
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