diff options
Diffstat (limited to 'net/cacti/files/pkg-install.in')
-rw-r--r-- | net/cacti/files/pkg-install.in | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/net/cacti/files/pkg-install.in b/net/cacti/files/pkg-install.in index e33cc5c0bcb9..4a35abeaeb19 100644 --- a/net/cacti/files/pkg-install.in +++ b/net/cacti/files/pkg-install.in @@ -3,10 +3,10 @@ PW=/usr/sbin/pw UID=107 GID=${UID} -CACTIUSER=%%CACTIUSER%% -CACTIGROUP=%%CACTIGROUP%% -CACTIDIR=%%CACTIDIR%% -PREFIX=%%PREFIX%% +CACTIUSER="%%CACTIUSER%%" +CACTIGROUP="%%CACTIGROUP%%" +CACTIDIR="%%CACTIDIR%%" +PREFIX="%%PREFIX%%" case $2 in @@ -39,9 +39,10 @@ PRE-INSTALL) POST-INSTALL) - chown ${CACTIUSER}:${CACTIGROUP} ${PREFIX}/${CACTIDIR}/rra/ - chown -R ${CACTIUSER}:${CACTIGROUP} ${PREFIX}/${CACTIDIR}/log/ - chmod -R a+r ${PREFIX}/${CACTIDIR}/scripts/ + chown ${CACTIUSER}:${CACTIGROUP} "${PREFIX}/${CACTIDIR}/rra/" + [ -d "${PREFIX}/${CACTIDIR}/log/" ] || mkdir -p "${PREFIX}/${CACTIDIR}/log/" + chown -R ${CACTIUSER}:${CACTIGROUP} "${PREFIX}/${CACTIDIR}/log/" + chmod -R a+r "${PREFIX}/${CACTIDIR}/scripts/" ;; *) exit 1 |