mirror of
https://github.com/YunoHost-Apps/homeassistant_ynh.git
synced 2024-09-03 19:26:16 +02:00
Fix restore in case on restore on new system (#132)
This commit is contained in:
parent
1a7ebd7bec
commit
f204b62991
1 changed files with 11 additions and 0 deletions
|
@ -124,6 +124,17 @@ ynh_script_progression --message="Restoring the logrotate configuration..."
|
|||
|
||||
ynh_restore_file --origin_path="/etc/logrotate.d/$app"
|
||||
|
||||
#=================================================
|
||||
# IF NEEDED UPDATE THE PYHTON LINK IN THE VIRUTAL ENV.
|
||||
#=================================================
|
||||
ynh_script_progression --message="Updating the pyhton link in the pyhton virtual environment..."
|
||||
|
||||
hass_python_link=$(head -1 /var/www/homeassistant/bin/hass | sed 's/#!//')
|
||||
if [ ! -e "$hass_python_link" ] ; then
|
||||
hass_python_new_dest=$(which `basename "$hass_python_link"`)
|
||||
ln -sfn "$hass_python_new_dest" "$hass_python_link"
|
||||
fi
|
||||
|
||||
#=================================================
|
||||
# SET FILE OWNERSHIP / PERMISSIONS
|
||||
#=================================================
|
||||
|
|
Loading…
Add table
Reference in a new issue