Skip to content
This repository has been archived by the owner on Oct 30, 2019. It is now read-only.

Commit

Permalink
Merge pull request #157 from ludeeus/appdaemon-newewst-python
Browse files Browse the repository at this point in the history
Appdaemon: Use newest python version when installing.
  • Loading branch information
Landrash committed Apr 6, 2018
2 parents 7bed98a + 2fc2c4a commit 7963b1b
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion package/opt/hassbian/suites/appdaemon.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,10 @@ else
HOMEASSISTANT_PASSWORD=""
fi

echo "Checking python version to use..."
PYTHONVER=$(echo /usr/local/lib/*python* | awk -F/ '{print $NF}')
echo "Using $PYTHONVER..."

echo "Creating directory for AppDaemon Venv"
sudo mkdir /srv/appdaemon
sudo chown -R homeassistant:homeassistant /srv/appdaemon
Expand All @@ -32,7 +36,7 @@ echo "Changing to the homeassistant user"
sudo -u homeassistant -H /bin/bash << EOF
echo "Creating AppDaemon venv"
python3 -m venv /srv/appdaemon
$PYTHONVER -m venv /srv/appdaemon
echo "Changing to AppDaemon venv"
source /srv/appdaemon/bin/activate
Expand Down

0 comments on commit 7963b1b

Please sign in to comment.