mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-10 09:32:06 +00:00
Moved chown to correct place [#CLICKHOUSE-2].
This commit is contained in:
parent
bbc5120c23
commit
041623dee1
7
debian/clickhouse-server-base.postinst
vendored
7
debian/clickhouse-server-base.postinst
vendored
@ -5,7 +5,6 @@ CLICKHOUSE_USER=clickhouse
|
||||
CLICKHOUSE_GROUP=${CLICKHOUSE_USER}
|
||||
CLICKHOUSE_DATADIR=/var/lib/clickhouse
|
||||
CLICKHOUSE_LOGDIR=/var/log/clickhouse-server
|
||||
CLICKHOUSE_SERVER_ETCDIR=/etc/clickhouse-server
|
||||
|
||||
|
||||
if [ "$1" = configure ]; then
|
||||
@ -63,12 +62,6 @@ Please fix this and reinstall this package." >&2
|
||||
fi
|
||||
|
||||
|
||||
if [ -d ${CLICKHOUSE_SERVER_ETCDIR} ]; then
|
||||
# -R only for compatibility for old metrika user, remove -R after 2017-06-01
|
||||
su -s /bin/sh ${CLICKHOUSE_USER} -c "test -w ${CLICKHOUSE_SERVER_ETCDIR}" || chown -R ${CLICKHOUSE_USER}:${CLICKHOUSE_GROUP} ${CLICKHOUSE_SERVER_ETCDIR}
|
||||
fi
|
||||
|
||||
|
||||
# Clean old dynamic compilation results
|
||||
if [ -d "${CLICKHOUSE_DATADIR}/build" ]; then
|
||||
rm -f ${CLICKHOUSE_DATADIR}/build/*.cpp ${CLICKHOUSE_DATADIR}/build/*.so ||:
|
||||
|
4
debian/clickhouse-server.init
vendored
4
debian/clickhouse-server.init
vendored
@ -95,6 +95,10 @@ check_config()
|
||||
|
||||
initdb()
|
||||
{
|
||||
if [ -d ${SYSCONFDIR} ]; then
|
||||
su -s /bin/sh ${CLICKHOUSE_USER} -c "test -w ${SYSCONFDIR}" || chown ${CLICKHOUSE_USER}:${CLICKHOUSE_GROUP} ${SYSCONFDIR}
|
||||
fi
|
||||
|
||||
if [ -x "$BINDIR/$GENERIC_PROGRAM" ]; then
|
||||
CLICKHOUSE_DATADIR_FROM_CONFIG=$(su -s $SHELL ${CLICKHOUSE_USER} -c "$BINDIR/$GENERIC_PROGRAM extract-from-config --config-file=\"$CLICKHOUSE_CONFIG\" --key=path")
|
||||
if [ "(" "$?" -ne "0" ")" -o "(" -z "${CLICKHOUSE_DATADIR_FROM_CONFIG}" ")" ]; then
|
||||
|
Loading…
Reference in New Issue
Block a user