Skip to content
Snippets Groups Projects
Commit 8d76e10f authored by Piotr Gawron's avatar Piotr Gawron
Browse files

when pip install fails show message how to proceed

parent 52dc201f
No related branches found
No related tags found
1 merge request!264Resolve "prepare installable debian package"
......@@ -10,7 +10,7 @@ if [ "$1" = "configure" ] && [ -z "$2" ]; then
addgroup --quiet --system smasch
fi
ln -s /etc/smasch/smasch.py /usr/lib/smasch/smash/local_settings.py
ln -sf /etc/smasch/smasch.py /usr/lib/smasch/smash/local_settings.py
virtualenv --python=python3 /usr/lib/smasch/env
......@@ -24,9 +24,17 @@ if [ "$1" = "configure" ] && [ -z "$2" ]; then
fi
echo "Instal python dependencies"
source /usr/lib/smasch/env/bin/activate && pip install -r /usr/lib/smasch/requirements.txt --log $LOG_FILE
source /usr/lib/smasch/env/bin/activate && pip install -r /usr/lib/smasch/requirements-dev.txt --log $LOG_FILE
echo "Installing python dependencies"
{
source /usr/lib/smasch/env/bin/activate && pip install -r /usr/lib/smasch/requirements.txt --log $LOG_FILE
source /usr/lib/smasch/env/bin/activate && pip install -r /usr/lib/smasch/requirements-dev.txt --log $LOG_FILE
} || {
echo "There was an issue when installing python dependencies." >> $LOG_FILE
echo "There was an issue when installing python dependencies. Reinstall of smasch could help (in case you are upgrading smasch the data should not be lost in the process): "
echo "apt-get remove smasch"
echo "apt-get install smasch"
exit 1
}
echo "Collecting static files"
source /usr/lib/smasch/env/bin/activate && /usr/lib/smasch/manage.py collectstatic --no-input >> $LOG_FILE 2>&1
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment