summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAmadeusz Żołnowski <aidecoe@gentoo.org>2017-05-28 14:08:41 +0100
committerAmadeusz Żołnowski <aidecoe@gentoo.org>2017-05-28 14:08:41 +0100
commit3f1724d261577a5eebdd7cc64605c41baa7a4f48 (patch)
treed57c920881bfb578f3e986e943904351bb1d75ed /net-im/ejabberd/files
parentdev-db/pgbadger: Use Unique Archive Name (diff)
downloadgentoo-3f1724d261577a5eebdd7cc64605c41baa7a4f48.tar.gz
gentoo-3f1724d261577a5eebdd7cc64605c41baa7a4f48.tar.bz2
gentoo-3f1724d261577a5eebdd7cc64605c41baa7a4f48.zip
net-im/ejabberd: Bump version
Package-Manager: Portage-2.3.5, Repoman-2.3.2
Diffstat (limited to 'net-im/ejabberd/files')
-rw-r--r--net-im/ejabberd/files/ejabberd-17.04-ejabberdctl.patch62
1 files changed, 62 insertions, 0 deletions
diff --git a/net-im/ejabberd/files/ejabberd-17.04-ejabberdctl.patch b/net-im/ejabberd/files/ejabberd-17.04-ejabberdctl.patch
new file mode 100644
index 000000000000..6001c651f5d6
--- /dev/null
+++ b/net-im/ejabberd/files/ejabberd-17.04-ejabberdctl.patch
@@ -0,0 +1,62 @@
+From 185923a3c5f11c2d29599416a52b6594bc94d8c9 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Amadeusz=20=C5=BBo=C5=82nowski?= <aidecoe@aidecoe.name>
+Date: Mon, 29 Aug 2016 22:29:41 +0100
+Subject: [PATCH] Adjust ejabberdctl for Gentoo jabberbase setup
+
+Set SHELL since the generic jabber user used on Gentoo for jabber
+servers doesn't have a valid shell set by default and fix EXEC_CMD
+otherwise it fails with "This account is currently not available" again
+due to jabber not having a valid shell.
+
+Also, workaround the assumption that jabber's $HOME is a directory when
+instead it defaults to /dev/null on Gentoo.
+---
+ ejabberdctl.template | 8 ++++++--
+ 1 file changed, 6 insertions(+), 2 deletions(-)
+
+diff --git a/ejabberdctl.template b/ejabberdctl.template
+index 5b34ebe..3c080fd 100755
+--- a/ejabberdctl.template
++++ b/ejabberdctl.template
+@@ -16,6 +16,7 @@ IEX={{bindir}}/iex
+ EPMD={{epmd}}
+ INSTALLUSER={{installuser}}
+ ERL_LIBS={{libdir}}
++SHELL=/bin/sh
+
+ # check the proper system user is used if defined
+ if [ "$INSTALLUSER" != "" ] ; then
+@@ -23,11 +24,11 @@ if [ "$INSTALLUSER" != "" ] ; then
+ for GID in `id -G`; do
+ if [ $GID -eq 0 ] ; then
+ INSTALLUSER_HOME=$(getent passwd "$INSTALLUSER" | cut -d: -f6)
+- if [ -n "$INSTALLUSER_HOME" ] && [ ! -d "$INSTALLUSER_HOME" ] ; then
++ if [ -n "$INSTALLUSER_HOME" ] && [ ! -e "$INSTALLUSER_HOME" ] ; then
+ mkdir -p "$INSTALLUSER_HOME"
+ chown "$INSTALLUSER" "$INSTALLUSER_HOME"
+ fi
+- EXEC_CMD="su $INSTALLUSER -c"
++ EXEC_CMD="su $INSTALLUSER -p -c"
+ fi
+ done
+ if [ `id -g` -eq `id -g $INSTALLUSER` ] ; then
+@@ -91,6 +92,7 @@ EJABBERD_LOG_PATH=$LOGS_DIR/ejabberd.log
+ DATETIME=`date "+%Y%m%d-%H%M%S"`
+ ERL_CRASH_DUMP=$LOGS_DIR/erl_crash_$DATETIME.dump
+ ERL_INETRC=$ETC_DIR/inetrc
++HOME=$SPOOL_DIR
+
+ # define mnesia options
+ MNESIA_OPTS="-mnesia dir \"\\\"$SPOOL_DIR\\\"\" $MNESIA_OPTIONS"
+@@ -149,6 +151,8 @@ export ERL_MAX_ETS_TABLES
+ export CONTRIB_MODULES_PATH
+ export CONTRIB_MODULES_CONF_DIR
+ export ERL_LIBS
++export HOME
++export SHELL
+
+ shell_escape_str()
+ {
+--
+2.9.2
+