1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/homeassistant_ynh.git synced 2024-09-03 19:26:16 +02:00
homeassistant_ynh/conf/homeassistant_conf_files/bin/upgrade_homeassistant.sh

24 lines
522 B
Bash
Raw Normal View History

2019-06-09 18:30:25 +02:00
#!/bin/bash
# define usefull variables
app="homeassistant"
final_path="/opt/yunohost/$app"
# stop homeassistant systemd service
#sudo systemctl stop $app@$app.service
# create the virtual environment
python3 -m venv "$final_path"
# activate the virtual environment
. "$final_path/bin/activate"
# upgrade required python package
2020-08-27 20:58:38 +02:00
python3 -m pip install --upgrade wheel
2019-06-09 18:30:25 +02:00
# upgrade homeassistant python package
2020-08-27 20:58:38 +02:00
pip3 install --upgrade $app
2019-06-09 18:30:25 +02:00
# restart homeassistant systemd service
sudo systemctl restart $app@$app.service