1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/phpldapadmin_ynh.git synced 2024-09-03 19:56:45 +02:00

fix deprecated ynh cmd

This commit is contained in:
aymhce 2017-09-03 21:11:33 +00:00
parent 331165d2dc
commit 5791e0dc90
2 changed files with 7 additions and 3 deletions

View file

@ -15,7 +15,9 @@ admin=$YNH_APP_ARG_ADMIN
ynh_app_setting_set "$app" admin "$admin"
# Check domain/path availability
sudo yunohost app checkurl "${domain}${path}" -a "$app" || ynh_die "Path not available: ${domain}${path}"
path=$(ynh_normalize_url_path $path)
ynh_webpath_available $domain $path
ynh_webpath_register $app $domain $path
# Copy files to the right place
version=$(cat upstream_version)

View file

@ -10,11 +10,13 @@ domain=$(ynh_app_setting_get "$app" domain)
path=$(ynh_app_setting_get "$app" path)
admin=$(ynh_app_setting_get "$app" admin)
yunohost app checkurl "${domain}${path}" -a "$app" \
|| ynh_die "Path not available: ${domain}${path}"
test ! -d /var/www/$app \
|| ynh_die "There is already a directory: /var/www/$app "
path=$(ynh_normalize_url_path $path)
ynh_webpath_available $domain $path
ynh_webpath_register $app $domain $path
sudo cp -a ./sources "/var/www/$app"
cp -a ./conf/nginx.conf "/etc/nginx/conf.d/$domain.d/$app.conf"