Adding Raspberry Pi OS specific dependencies discovered during first installation attempt
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
|
||||
toolName=synapse
|
||||
toolDeps="build-essential python3-dev libffi-dev python3-pip python3-setuptools postgresql libssl-dev virtualenv libjpeg-dev libxslt1-dev libpq5 libpq-dev"
|
||||
toolDepsRaspi="ilibopenjp2-7 libtiff5"
|
||||
toolUser="synapse"
|
||||
toolGroup="synapse"
|
||||
synapseHashTool="env/bin/hash_password"
|
||||
@@ -23,6 +24,21 @@ CONFIG_FILE_NAME="matrix.cfg"
|
||||
CONFIG_FILE_TEMPLATE="$WDIR/${CONFIG_FILE_NAME}.example"
|
||||
|
||||
step_config() {
|
||||
if [ "$(which lsb_release)" == "" ] ; then
|
||||
echoerr " [W] Cannot detect OS. Assuming Raspberry Pi OS"
|
||||
osName="Raspbian"
|
||||
else
|
||||
osName=$(lsb_release -is)
|
||||
distName=$(lsb_release -cs)
|
||||
fi
|
||||
|
||||
if [ "$osName" == "" ] ; then
|
||||
echoerr " [W] Error dedecting OS. Assuming Raspberry Pi OS"
|
||||
osName="Raspbian"
|
||||
fi
|
||||
|
||||
echo " [I] Detected OS: $osName $distName"
|
||||
|
||||
initSeqConfig "$CONFIG_FILE_NAME" "$CONFIG_FILE_TEMPLATE"
|
||||
if [ $? -eq 0 ] ; then
|
||||
CONFIG=1
|
||||
@@ -48,7 +64,10 @@ step_1() {
|
||||
aptOption=""
|
||||
fi
|
||||
|
||||
exe apt install $toolDeps $aptOption
|
||||
if [ "$osName" != "Raspbian" ] ; then
|
||||
toolDepsRaspi=""
|
||||
fi
|
||||
exe apt install $toolDeps $toolDepsRaspi $aptOption
|
||||
}
|
||||
|
||||
step_2_info() { echo "Create postgres database for $toolName"; }
|
||||
|
Reference in New Issue
Block a user