mirror of
https://github.com/YunoHost-Apps/domoticz_ynh.git
synced 2024-09-03 18:26:17 +02:00
convert v2
This commit is contained in:
parent
ffc8dab4a4
commit
4d27c23344
4 changed files with 14 additions and 10 deletions
|
@ -54,7 +54,6 @@ ram.runtime = "50M"
|
||||||
[resources.system_user]
|
[resources.system_user]
|
||||||
|
|
||||||
[resources.install_dir]
|
[resources.install_dir]
|
||||||
dir = /opt/yunohost/__APP__
|
|
||||||
|
|
||||||
[resources.permissions]
|
[resources.permissions]
|
||||||
main.url = "/"
|
main.url = "/"
|
||||||
|
|
|
@ -13,8 +13,8 @@ source /usr/share/yunohost/helpers
|
||||||
#Have to reload them as otherwise they are all the same
|
#Have to reload them as otherwise they are all the same
|
||||||
backup_OS=$(ynh_app_setting_get --app="$app" --key=OS)
|
backup_OS=$(ynh_app_setting_get --app="$app" --key=OS)
|
||||||
backup_mach=$(ynh_app_setting_get --app="$app" --key=mach)
|
backup_mach=$(ynh_app_setting_get --app="$app" --key=mach)
|
||||||
os=`lowercase \`uname -s\``
|
current_os=`lowercase \`uname -s\``
|
||||||
mach=`uname -m`
|
current_mach=`uname -m`
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# CHECK IF THE APP CAN BE RESTORED
|
# CHECK IF THE APP CAN BE RESTORED
|
||||||
|
@ -22,10 +22,10 @@ mach=`uname -m`
|
||||||
#As we are downloading compiled binaries for each system, we have to check if the restore occurs
|
#As we are downloading compiled binaries for each system, we have to check if the restore occurs
|
||||||
#on the same system type. If we are restoring on another system type it won't work and in that
|
#on the same system type. If we are restoring on another system type it won't work and in that
|
||||||
#case we must go through a reinstall process.
|
#case we must go through a reinstall process.
|
||||||
test "$backup_OS" = "$os" \
|
test "$backup_OS" = "$current_os" \
|
||||||
|| ynh_die --message="Cannot restore : previous OS is $backup_OS, current OS is $OS, please reinstall"
|
|| ynh_die --message="Cannot restore : previous OS is $backup_OS, current OS is $current_os, please reinstall"
|
||||||
test "$backup_mach" = "$mach" \
|
test "$backup_mach" = "$current_mach" \
|
||||||
|| ynh_die --message="Cannot restore : previous machine type is $backup_mach, current machine type is $MACH, please reinstall"
|
|| ynh_die --message="Cannot restore : previous machine type is $backup_mach, current machine type is $current_mach, please reinstall"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# STANDARD RESTORATION STEPS
|
# STANDARD RESTORATION STEPS
|
||||||
|
|
|
@ -13,8 +13,8 @@ version_gt() {
|
||||||
source _common.sh
|
source _common.sh
|
||||||
source /usr/share/yunohost/helpers
|
source /usr/share/yunohost/helpers
|
||||||
|
|
||||||
#REMOVEME? current_OS=$(ynh_app_setting_get --app="$app" --key=OS)
|
current_OS=$(ynh_app_setting_get --app="$app" --key=OS)
|
||||||
#REMOVEME? current_mach=$(ynh_app_setting_get --app="$app" --key=mach)
|
current_mach=$(ynh_app_setting_get --app="$app" --key=mach)
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# CHECK VERSION
|
# CHECK VERSION
|
||||||
|
|
|
@ -19,6 +19,8 @@ test_format = 1.0
|
||||||
|
|
||||||
args.mqtt_domain="mqtt.domain.tld"
|
args.mqtt_domain="mqtt.domain.tld"
|
||||||
|
|
||||||
|
exclude = ["package_linter"]
|
||||||
|
|
||||||
test_upgrade_from.27311ad.name = "2022.2 with mosquitto"
|
test_upgrade_from.27311ad.name = "2022.2 with mosquitto"
|
||||||
test_upgrade_from.27311ad.args.mqtt_domain="mqtt.domain.tld"
|
test_upgrade_from.27311ad.args.mqtt_domain="mqtt.domain.tld"
|
||||||
|
|
||||||
|
@ -33,6 +35,9 @@ test_format = 1.0
|
||||||
set -euxo pipefail
|
set -euxo pipefail
|
||||||
yunohost app setting domoticz mqtt_domain -v mqtt.domain.tld
|
yunohost app setting domoticz mqtt_domain -v mqtt.domain.tld
|
||||||
"""
|
"""
|
||||||
exclude = ["install.private", "install.multi", "backup", "change_url"]
|
args.mqtt_domain="mqtt.domain.tld"
|
||||||
|
|
||||||
|
exclude = ["package_linter", "install.private", "install.multi", "backup_restore", "change_url"]
|
||||||
|
|
||||||
test_upgrade_from.27311ad.name = "2022.2 without mosquitto"
|
test_upgrade_from.27311ad.name = "2022.2 without mosquitto"
|
||||||
test_upgrade_from.27311ad.args.mqtt_domain="sub.domain.tld"
|
test_upgrade_from.27311ad.args.mqtt_domain="sub.domain.tld"
|
Loading…
Add table
Reference in a new issue