mirror of
https://github.com/YunoHost-Apps/piwigo_ynh.git
synced 2024-09-03 20:06:03 +02:00
Comply with new package_linter rules
This commit is contained in:
parent
c4c7645890
commit
c5d7cfdbf3
2 changed files with 6 additions and 13 deletions
|
@ -30,13 +30,6 @@ ynh_app_setting_set "$app" language "$language"
|
|||
sudo yunohost app checkurl "${domain}${path}" -a "$app" \
|
||||
|| ynh_die "Path not available: ${domain}${path}"
|
||||
|
||||
# Check user parameter
|
||||
sudo yunohost user list --json | grep -qi "\"username\": \"$admin\""
|
||||
if [[ ! $? -eq 0 ]]; then
|
||||
echo "Wrong user"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Download sources
|
||||
sudo wget -q http://piwigo.org/download/dlcounter.php?code=2.8.3 -O piwigo.zip
|
||||
|
||||
|
@ -79,7 +72,7 @@ sudo cp $nginx_conf /etc/nginx/conf.d/$domain.d/$app.conf
|
|||
|
||||
# Set permissions and reload nginx (needed at this stage for the PHP piwigo installation process)
|
||||
sudo service nginx reload
|
||||
sudo yunohost app setting "$app" unprotected_uris -v "/"
|
||||
ynh_app_setting_set "$app" unprotected_uris "/"
|
||||
sudo yunohost app ssowatconf
|
||||
|
||||
# Generate random password for admin
|
||||
|
@ -108,6 +101,6 @@ mysql -u $dbuser -p$dbpass $dbname -e "INSERT INTO plugins (id,state,version) VA
|
|||
#protect URIs if private
|
||||
if [ $is_public -eq 0 ];
|
||||
then
|
||||
sudo yunohost app setting "$app" -d unprotected_uris
|
||||
sudo yunohost app setting "$app" protected_uris -v "/"
|
||||
ynh_app_setting_delete "$app" unprotected_uris
|
||||
ynh_app_setting_set "$app" protected_uris "/"
|
||||
fi
|
||||
|
|
|
@ -48,7 +48,7 @@ sudo cp $nginx_conf /etc/nginx/conf.d/$domain.d/$app.conf
|
|||
|
||||
# Set permissions and reload nginx (needed at this stage for the PHP piwigo installation process)
|
||||
sudo service nginx reload
|
||||
sudo yunohost app setting "$app" unprotected_uris -v "/"
|
||||
ynh_app_setting_set "$app" unprotected_uris "/"
|
||||
sudo yunohost app ssowatconf
|
||||
|
||||
#activate ldap plugin
|
||||
|
@ -57,6 +57,6 @@ sudo yunohost app ssowatconf
|
|||
#protect URIs if private
|
||||
if [ $is_public -eq 0 ];
|
||||
then
|
||||
sudo yunohost app setting "$app" -d unprotected_uris
|
||||
sudo yunohost app setting "$app" protected_uris -v "/"
|
||||
ynh_app_setting_delete "$app" unprotected_uris
|
||||
ynh_app_setting_set "$app" protected_uris "/"
|
||||
fi
|
Loading…
Reference in a new issue