1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/gotify_ynh.git synced 2024-09-03 20:36:26 +02:00

Merge pull request #24 from YunoHost-Apps/feature/fix-arm

Feature/fix arm
This commit is contained in:
Clément 2020-08-30 10:21:19 +02:00 committed by GitHub
commit fb9b399b00
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 8 additions and 4 deletions

View file

@ -8,7 +8,7 @@ Type=simple
User=__APP__
Group=__APP__
WorkingDirectory=__FINALPATH__/
ExecStart=__FINALPATH__/gotify-linux-amd64
ExecStart=__FINALPATH__/gotify-linux-__ARCHITECTURE__
[Install]
WantedBy=multi-user.target

View file

@ -12,11 +12,13 @@ ynh_delete_file_checksum () {
ynh_app_setting_delete $app $checksum_setting_name
}
if [ -n "$(uname -m | grep 64)" ]; then
if [ -n "$(uname -m | grep arm64)" ] || [ -n "$(uname -m | grep aarch64)" ]; then
architecture="arm64"
elif [ -n "$(uname -m | grep 64)" ]; then
architecture="amd64"
elif [ -n "$(uname -m | grep arm)" ]; then
architecture="arm"
architecture="arm-7"
else
ynh_die "Unable to detect your achitecture, please open a bug describing \
your hardware and the result of the command \"uname -m\"." 1
fi
fi

View file

@ -107,6 +107,7 @@ ynh_system_user_create $app
#=================================================
# Create a dedicated systemd config
ynh_replace_string "__ARCHITECTURE__" $architecture "../conf/systemd.service"
ynh_add_systemd_config
#=================================================

View file

@ -129,6 +129,7 @@ ynh_store_file_checksum "$final_path/config.yml"
#=================================================
# Create a dedicated systemd config
ynh_replace_string "__ARCHITECTURE__" $architecture "../conf/systemd.service"
ynh_add_systemd_config
#=================================================