Can anyone say why when creating the new manticore
user when installing from RPM, the default shell for it was set to /bin/bash
instead of /sbin/nologin
or /bin/false
?
# create user/group, and update permissions
groupadd -r %{manticore_group} 2>/dev/null || true
useradd -M -r -d /var/lib/sphinx -s /bin/bash -c "Manticore server" -g %{manticore_group} %{manticore_user} 2>/dev/null || true
usermod -g %{manticore_group} %{manticore_user} 2>/dev/null || true
chown -R %{manticore_user}:%{manticore_group} /var/lib/manticore /var/log/manticore /var/run/manticore
if [ $1 == 1 ]; then
/sbin/chkconfig --add manticore
fi
if [ $1 == 2 ]; then
if [ -f @SYSCONFDIR@/sphinx/sphinx.conf ]; then
echo "Moving existing configuration to new location..."
From manticoresearch/dist/rpm/manticore.post.in
:
useradd -M -r -d /var/lib/sphinx -s /bin/bash -c "Manticore server" -g %{manticore_group} %{manticore_user} 2>/dev/null || true
adrian
June 29, 2020, 12:26pm
2
It should be /bin/false
. Seems we overlooked this 3 years ago when we create the spec for rpm.
Will be fixed.