HEX
Server: Apache/2.4.41 (Ubuntu)
System: Linux vmi1674223.contaboserver.net 5.4.0-182-generic #202-Ubuntu SMP Fri Apr 26 12:29:36 UTC 2024 x86_64
User: root (0)
PHP: 7.4.3-4ubuntu2.22
Disabled: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
Upload Files
File: /var/lib/dpkg/info/openproject.postinst
#!/bin/bash

set -e

export APP_NAME="openproject"
export APP_USER="openproject"
export APP_GROUP="openproject"
export APP_HOME="/opt/openproject"

HOME_LOGS="${APP_HOME}/log"
LOGS="/var/log/${APP_NAME}"

chown -R ${APP_USER}.${APP_GROUP} ${APP_HOME}

# link app log directory to /var/log/NAME
mkdir -p ${LOGS}
rm -rf ${HOME_LOGS}
ln -fs ${LOGS} ${HOME_LOGS}
chown -R ${APP_USER}.${APP_GROUP} ${LOGS}

# Add default conf.d file
[ -f /etc/${APP_NAME}/conf.d/other ] || touch /etc/${APP_NAME}/conf.d/other

chown -R ${APP_USER}.${APP_GROUP} /etc/${APP_NAME}
chown ${APP_USER}.${APP_GROUP} /var/db/${APP_NAME}

chmod 0750 /etc/${APP_NAME} /etc/${APP_NAME}/conf.d
find /etc/${APP_NAME} -type f -exec chmod 0640 {} +




echo "=============="
echo "The ${APP_NAME} package provides an installer. Please run the following command to finish the installation:"
echo "sudo ${APP_NAME} configure"
echo "=============="