mirror of
https://github.com/YunoHost-Apps/calibreweb_ynh.git
synced 2024-09-03 18:16:20 +02:00
Add Kobo Sync auth
This commit is contained in:
parent
bb80e657e4
commit
23d5ff9d34
2 changed files with 10 additions and 0 deletions
|
@ -238,6 +238,9 @@ if [ $public_library -eq 0 ]; then
|
||||||
ynh_permission_update --permission "main" --add $admin
|
ynh_permission_update --permission "main" --add $admin
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
#Kobo sync permission
|
||||||
|
ynh_permission_create --permission="Kobo sync" --url="$domain/kobo" --allowed="visitors"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# RELOAD NGINX
|
# RELOAD NGINX
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
|
@ -134,6 +134,13 @@ if [ -z $(sqlite3 $final_path/app.db "SELECT config_kepubifypath FROM settings")
|
||||||
eval sqlite3 $final_path/app.db "\"UPDATE settings SET config_kepubifypath='/opt/kepubify/kepubify-linux-$mach' WHERE ID=1\""
|
eval sqlite3 $final_path/app.db "\"UPDATE settings SET config_kepubifypath='/opt/kepubify/kepubify-linux-$mach' WHERE ID=1\""
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Create the permission "kobo_sync" only if it doesn't exist.
|
||||||
|
if ! ynh_permission_exists --permission="Kobo sync"
|
||||||
|
then
|
||||||
|
# API Authorization with dedicated URL
|
||||||
|
ynh_permission_create --permission="Kobo sync" --url="$domain/kobo" --allowed="visitors"
|
||||||
|
fi
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# STANDARD UPGRADE STEPS
|
# STANDARD UPGRADE STEPS
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
Loading…
Add table
Reference in a new issue