[gentoo-commits] repo/gentoo:master commit in: net-irc/unrealircd/files/

2022-03-12 Thread Sam James
commit: 80a2e6933dfd396112c8283e9fd9a1902ca2c4ea
Author: Sam James  gentoo  org>
AuthorDate: Sat Mar 12 03:39:24 2022 +
Commit: Sam James  gentoo  org>
CommitDate: Sat Mar 12 13:44:53 2022 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=80a2e693

net-irc/unrealircd: only run configtest for main instance

We can't, right now, specify a config file for the configtest
part so just skip it.

Signed-off-by: Sam James  gentoo.org>

 net-irc/unrealircd/files/unrealircd.initd-r3 | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/net-irc/unrealircd/files/unrealircd.initd-r3 
b/net-irc/unrealircd/files/unrealircd.initd-r3
index d2ff1a64c969..5bc03001e87f 100644
--- a/net-irc/unrealircd/files/unrealircd.initd-r3
+++ b/net-irc/unrealircd/files/unrealircd.initd-r3
@@ -32,8 +32,9 @@ else
 fi
 
 checkconfig() {
-   # command_args weirdness because We want to preserve the chroot 
arguments if it's set
-   su -s /bin/sh ${command_user:=root} -c "${command} 
${command_args%${UNREALIRCD_COMMAND_ARGS}}" configtest
+   # command_args weirdness because we want to preserve the chroot 
arguments if it's set
+   # Only run the configtest for the main instance; it can't work right 
now for others (no way to specify config file)
+   [ ${SVCNAME} = unrealircd ] && su -s /bin/sh ${command_user:=root} -c 
"${command} ${command_args%${UNREALIRCD_COMMAND_ARGS}}" configtest
 }
 
 depend() {



[gentoo-commits] repo/gentoo:master commit in: net-irc/unrealircd/files/

2022-03-01 Thread Sam James
commit: 4b2a836a9baf6be8544fcd67b7fca629a6d8e614
Author: Michael Mair-Keimberger  levelnine  at>
AuthorDate: Mon Feb 28 07:14:52 2022 +
Commit: Sam James  gentoo  org>
CommitDate: Wed Mar  2 03:09:05 2022 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4b2a836a

net-irc/unrealircd: remove unused files

Package-Manager: Portage-3.0.30, Repoman-3.0.3
Signed-off-by: Michael Mair-Keimberger  levelnine.at>
Closes: https://github.com/gentoo/gentoo/pull/24379
Signed-off-by: Sam James  gentoo.org>

 net-irc/unrealircd/files/unrealircd.confd-r3 | 32 ---
 net-irc/unrealircd/files/unrealircd.initd-r2 | 38 
 2 files changed, 70 deletions(-)

diff --git a/net-irc/unrealircd/files/unrealircd.confd-r3 
b/net-irc/unrealircd/files/unrealircd.confd-r3
deleted file mode 100644
index 66d9878f014c..
--- a/net-irc/unrealircd/files/unrealircd.confd-r3
+++ /dev/null
@@ -1,32 +0,0 @@
-# Copyright 1999-2018 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-# Which configuration file to load instead of unrealircd.conf. If you
-# want to run multiple instances of unrealircd, you must edit
-# files::pidfile to match UNREALIRCD_PIDFILE. You should also ensure
-# that files::tunefile is different for each unrealircd instance. See
-# https://www.unrealircd.org/docs/Configuration#Files_block
-#
-# To support multiple instances of unrealircd, you may create symlinks
-# in /etc/init.d pointing to /etc/init.d/unrealircd. It is recommended
-# that the scheme unrealircd.${instance_name} be used. For each
-# instance, you may make a copy of this file with the appropriate name
-# to override default options specific to that instance.
-UNREALIRCD_CONF="/etc/unrealircd/${SVCNAME}.conf"
-
-# The path where unrealircd is configured to create its pidfile.
-UNREALIRCD_PIDFILE="/run/unrealircd/${SVCNAME#unreal}.pid"
-
-# extra options to pass to unrealircd ...
-# You should not specify the -f option here; use
-# UNREALIRCD_CONF instead.
-#
-# [-h servername]
-# [-p portnumber]
-# [-x loglevel]
-# [-t] (to enable debug output)
-UNREALIRCD_OPTS=""
-
-# Extra flags to pass to start-stop-daemon. When initially
-# debugging, removing --quiet may help.
-UNREALIRCD_SSD_OPTS="--quiet"

diff --git a/net-irc/unrealircd/files/unrealircd.initd-r2 
b/net-irc/unrealircd/files/unrealircd.initd-r2
deleted file mode 100644
index 7d733a6e185a..
--- a/net-irc/unrealircd/files/unrealircd.initd-r2
+++ /dev/null
@@ -1,38 +0,0 @@
-#!/sbin/openrc-run
-# Copyright 1999-2018 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-# Defaults
-: ${UNREALIRCD_CONF:=/etc/unrealircd/${SVCNAME}.conf}
-: ${UNREALIRCD_PIDFILE:=/run/unrealircd/${SVCNAME#unreal}.pid}
-
-command="/usr/bin/unrealircd"
-# Run the daemon in the foreground and let OpenRC background it.
-# This way the PID file is created securely, as root.
-command_args="-F -f ${UNREALIRCD_CONF} ${UNREALIRCD_OPTS}"
-command_user=unrealircd
-command_background=true
-pidfile="${UNREALIRCD_PIDFILE}"
-start_stop_daemon_args="${UNREALIRCD_SSD_OPTS}"
-extra_started_commands="reload"
-
-depend() {
-   use dns net
-   provide ircd
-}
-
-# It is unsafe for the unrealircd user to be able to write to its own
-# PID file, since root will be sending e.g. kill signals to the PID
-# listed in that file. Ensure that we overwrite the ownership and
-# permissions on /run/unrealircd from previous init scripts.
-start_pre() {
-   checkpath --directory --owner root:root --mode 0700 /run/unrealircd
-}
-
-reload() {
-   ebegin "Reloading ${RC_SVCNAME}"
-   start-stop-daemon --signal HUP \
- --pidfile "${pidfile}" \
- ${UNREALIRCD_SSD_OPTS}
-   eend $?
-}



[gentoo-commits] repo/gentoo:master commit in: net-irc/unrealircd/files/, net-irc/unrealircd/

2022-01-02 Thread Sam James
commit: 03f7fc88d9fd3fa086db52056a66014ef16fb1d4
Author: Sam James  gentoo  org>
AuthorDate: Fri Dec 31 07:51:06 2021 +
Commit: Sam James  gentoo  org>
CommitDate: Mon Jan  3 07:40:48 2022 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=03f7fc88

net-irc/unrealircd: add 5.2.3

- Add 5.2.3
- Add chroot support to init script
- Add checkconfig support to init script

Signed-off-by: Sam James  gentoo.org>

 net-irc/unrealircd/Manifest  |   1 +
 net-irc/unrealircd/files/unrealircd.confd-r4 |  37 ++
 net-irc/unrealircd/files/unrealircd.initd-r3 |  62 ++
 net-irc/unrealircd/unrealircd-5.2.3.ebuild   | 175 +++
 4 files changed, 275 insertions(+)

diff --git a/net-irc/unrealircd/Manifest b/net-irc/unrealircd/Manifest
index 5e1d7316cb20..b604a53bfb0f 100644
--- a/net-irc/unrealircd/Manifest
+++ b/net-irc/unrealircd/Manifest
@@ -1 +1,2 @@
 DIST unrealircd-5.2.2.tar.gz 7192024 BLAKE2B 
aa700c943cbab1dcc751e32c6cc0608cd27936b0910bbc62987dd2fe87ee5261e7a5eb2aa67dd77ed5ecb39d1d4f149c8810159e2c6f752ee65ce34e46548f60
 SHA512 
9d36eb1567431bc4a5420bc830bfc8dc89daa08ed1746efd6102e5ef161f67baf52e75e373454df7df6a443c4f575fb300d3c289d4dd99239a6de7d2b2a555a0
+DIST unrealircd-5.2.3.tar.gz 7200834 BLAKE2B 
af15b97219d5552a8fe6ecd77b4d0d0b8bcbe8c2f65ab531a7322471c05af3001000cc3799db68291b9abe8c3a5ea7d04559f858774d1b12a764a20fb4ab2bd0
 SHA512 
c92c631340cb81b030006646a047fde4ee738edc8362870ba4eb979133d851806c7d4764848a35cbd48c787708eab9f051f257008798a494673d9986d16b2405

diff --git a/net-irc/unrealircd/files/unrealircd.confd-r4 
b/net-irc/unrealircd/files/unrealircd.confd-r4
new file mode 100644
index ..934ac0e3f59f
--- /dev/null
+++ b/net-irc/unrealircd/files/unrealircd.confd-r4
@@ -0,0 +1,37 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+# Where to chroot to
+# Uncomment this line for chrooting
+#UNREALIRCD_CHROOT="/var/chroot/ircd"
+UNREALIRCD_CHROOT=""
+
+# Which configuration file to load instead of unrealircd.conf. If you
+# want to run multiple instances of unrealircd, you must edit
+# files::pidfile to match UNREALIRCD_PIDFILE. You should also ensure
+# that files::tunefile is different for each unrealircd instance. See
+# https://www.unrealircd.org/docs/Configuration#Files_block
+#
+# To support multiple instances of unrealircd, you may create symlinks
+# in /etc/init.d pointing to /etc/init.d/unrealircd. It is recommended
+# that the scheme unrealircd.${instance_name} be used. For each
+# instance, you may make a copy of this file with the appropriate name
+# to override default options specific to that instance.
+UNREALIRCD_CONF="${UNREALIRCD_CHROOT}/etc/unrealircd/${SVCNAME}.conf"
+
+# The path where unrealircd is configured to create its pidfile.
+UNREALIRCD_PIDFILE="${UNREALIRCD_CHROOT}/run/unrealircd/${SVCNAME#unreal}.pid"
+
+# extra options to pass to unrealircd ...
+# You should not specify the -f option here; use
+# UNREALIRCD_CONF instead.
+#
+# [-h servername]
+# [-p portnumber]
+# [-x loglevel]
+# [-t] (to enable debug output)
+UNREALIRCD_OPTS=""
+
+# Extra flags to pass to start-stop-daemon. When initially
+# debugging, removing --quiet may help.
+UNREALIRCD_SSD_OPTS="--quiet"

diff --git a/net-irc/unrealircd/files/unrealircd.initd-r3 
b/net-irc/unrealircd/files/unrealircd.initd-r3
new file mode 100644
index ..d2ff1a64c969
--- /dev/null
+++ b/net-irc/unrealircd/files/unrealircd.initd-r3
@@ -0,0 +1,62 @@
+#!/sbin/openrc-run
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+# Defaults
+: ${UNREALIRCD_CONF:=/etc/unrealircd/${SVCNAME}.conf}
+: ${UNREALIRCD_PIDFILE:=/run/unrealircd/${SVCNAME#unreal}.pid}
+
+# Convenience variable for the chroot bits, not actually user-controllable via 
conf.d
+UNREALIRCD_USER="unrealircd"
+UNREALIRCD_BIN="/usr/bin/unrealircd"
+UNREALIRCD_COMMAND_ARGS="-F -f ${UNREALIRCD_CONF} ${UNREALIRCD_OPTS}"
+
+# Run the daemon in the foreground and let OpenRC background it.
+# This way the PID file is created securely, as root.
+# https://bugs.unrealircd.org/view.php?id=4990
+# https://bugs.gentoo.org/628434
+command_args="${UNREALIRCD_COMMAND_ARGS}"
+command_background=true
+pidfile="${UNREALIRCD_PIDFILE}"
+
+start_stop_daemon_args="${UNREALIRCD_SSD_OPTS}"
+extra_started_commands="checkconfig reload"
+
+if [ -n "${UNREALIRCD_CHROOT}" ]; then
+   command=/usr/bin/chroot
+   command_args="--userspec ${UNREALIRCD_USER}:${UNREALIRCD_USER} 
${UNREALIRCD_CHROOT} ${UNREALIRCD_BIN} ${UNREALIRCD_COMMAND_ARGS}"
+else
+   # We're running it directly so no need for anything special.
+   command="${UNREALIRCD_BIN}"
+   command_user=${UNREALIRCD_USER}
+fi
+
+checkconfig() {
+   # command_args weirdness because We want to preserve the chroot 
arguments if it's set
+   su -s /bin/sh ${command_user:=root} -c "${command} 

[gentoo-commits] repo/gentoo:master commit in: net-irc/unrealircd/files/, net-irc/unrealircd/

2016-08-20 Thread Nathan Phillip Brink
commit: 857a5ec86c3a12a7285501e795af53b1d70340b8
Author: Nathan Phillip Brink  gentoo  org>
AuthorDate: Sat Aug 20 19:35:18 2016 +
Commit: Nathan Phillip Brink  gentoo  org>
CommitDate: Sat Aug 20 19:35:18 2016 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=857a5ec8

net-irc/unrealircd: Major version bump to unrealircd-4.0.5.

Package-Manager: portage-2.2.28

 net-irc/unrealircd/Manifest  |   1 +
 net-irc/unrealircd/files/unrealircd.confd-r2 |  36 +
 net-irc/unrealircd/files/unrealircd.initd-r1 |  44 ++
 net-irc/unrealircd/unrealircd-4.0.5.ebuild   | 222 +++
 4 files changed, 303 insertions(+)

diff --git a/net-irc/unrealircd/Manifest b/net-irc/unrealircd/Manifest
index 36f258f..89dbdc1 100644
--- a/net-irc/unrealircd/Manifest
+++ b/net-irc/unrealircd/Manifest
@@ -1 +1,2 @@
 DIST Unreal3.2.10.4.tar.gz 3540227 SHA256 
5041b67745d0bd2072cf9b74c07853085b8b5b07330263f0986bdc56eda98aa8 SHA512 
eeecefe79cadf3efa1b9379d4b675c0b86a2dd91e703f9e4b3998331f56b923d3719c67482f464f9b1699f801e0a83d677ada642ea7037c52a9d5db63abe6a5c
 WHIRLPOOL 
e52949bb6b20076d382825a841c8f643f1f64ac265d7f58898a6417c4853b569b8f561d5dccf198b4f006725e4be0636a2edb580023e8db62dadab8397d11975
+DIST unrealircd-4.0.5.tar.gz 4877444 SHA256 
5b69bbeb3487e98df2f6506d0455ce62f069281c88b937caf4e32f4f92a42717 SHA512 
503c55b901531bb984c6cfbeaaf560da714248ff716717671e09442f5a9fa245cd872ae69d08533419fb94efab98e9f80ae4f33c62522c246da6e877971b2a38
 WHIRLPOOL 
1fc4e16e4c12035758c673b88effd660766ab2bff56999ebaced6be1acb0b4a6c69efd3cd90ffaa63ee6479adda6e16cc415640322a4a66346e5bb182b795178

diff --git a/net-irc/unrealircd/files/unrealircd.confd-r2 
b/net-irc/unrealircd/files/unrealircd.confd-r2
new file mode 100644
index 000..dd7e7b4
--- /dev/null
+++ b/net-irc/unrealircd/files/unrealircd.confd-r2
@@ -0,0 +1,36 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+# user to run unrealircd as
+UNREALIRCD_USER="unrealircd"
+
+# Which configuration file to load instead of unrealircd.conf. If you
+# want to run multiple instances of unrealircd, you must edit
+# files::pidfile to match UNREALIRCD_PIDFILE. You should also ensure
+# that files::tunefile is different for each unrealircd instance. See
+# https://www.unrealircd.org/docs/Configuration#Files_block
+#
+# To support multiple instances of unrealircd, you may create symlinks
+# in /etc/init.d pointing to /etc/init.d/unrealircd. It is recommended
+# that the scheme unrealircd.${instance_name} be used. For each
+# instance, you may make a copy of this file with the appropriate name
+# to override default options specific to that instance.
+UNREALIRCD_CONF="/etc/unrealircd/${SVCNAME}.conf"
+
+# The path where unrealircd is configured to create its pidfile.
+UNREALIRCD_PIDFILE="/var/run/unrealircd/${SVCNAME#unreal}.pid"
+
+# extra options to pass to unrealircd ...
+# You should not specify the -f option here; use
+# UNREALIRCD_CONF instead.
+#
+# [-h servername]
+# [-p portnumber]
+# [-x loglevel]
+# [-t] (to enable debug output)
+UNREALIRCD_OPTS=""
+
+# Extra flags to pass to start-stop-daemon. When initially
+# debugging, removing --quiet may help.
+UNREALIRCD_SSD_OPTS="--quiet"

diff --git a/net-irc/unrealircd/files/unrealircd.initd-r1 
b/net-irc/unrealircd/files/unrealircd.initd-r1
new file mode 100644
index 000..381723f
--- /dev/null
+++ b/net-irc/unrealircd/files/unrealircd.initd-r1
@@ -0,0 +1,44 @@
+#!/sbin/openrc-run
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+extra_started_commands="reload"
+
+# Defaults
+: ${UNREALIRCD_USER:=unrealircd}
+: ${UNREALIRCD_CONF:=/etc/unrealircd/${SVCNAME}.conf}
+: ${UNREALIRCD_PIDFILE:=/run/unrealircd/${SVCNAME#unreal}.pid}
+
+depend() {
+   use dns net
+   provide ircd
+}
+
+start() {
+   UNREALIRCD_PIDFILEDIR=${UNREALIRCD_PIDFILE%/*}
+   if ! [ -d "${UNREALIRCD_PIDFILEDIR}" ]; then
+   ebegin "Creating ${UNREALIRCD_PIDFILEDIR} for ${SVCNAME}"
+   mkdir "${UNREALIRCD_PIDFILEDIR}" \
+   && chown :unrealircd "${UNREALIRCD_PIDFILEDIR}" \
+   && chmod 770 "${UNREALIRCD_PIDFILEDIR}"
+   eend $?
+   fi
+
+   ebegin "Starting ${SVCNAME}"
+   start-stop-daemon --start ${UNREALIRCD_SSD_OPTS} --exec 
/usr/bin/unrealircd \
+   --user ${UNREALIRCD_USER} --pidfile "${UNREALIRCD_PIDFILE}" -- 
-f "${UNREALIRCD_CONF}" ${UNREALIRCD_OPTS}
+   eend $?
+}
+
+stop() {
+   ebegin "Stopping ${SVCNAME}"
+   start-stop-daemon --stop ${UNREALIRCD_SSD_OPTS} --pidfile 
"${UNREALIRCD_PIDFILE}"
+   eend $?
+}
+
+reload() {
+   ebegin "Reloading ${SVCNAME}"
+   start-stop-daemon --signal HUP ${UNREALIRCD_SSD_OPTS} --pidfile 
"${UNREALIRCD_PIDFILE}"
+   eend $?
+}

diff --git a/net-irc/unrealircd/unrealircd-4.0.5.ebuild