diff --git a/README.md b/README.md index 28a38c5..d374439 100755 --- a/README.md +++ b/README.md @@ -32,7 +32,7 @@ Castopod is easy to install and was built on top of CodeIgniter4, a powerful PHP - Multi-tenant: host as many podcasts as you want - Multi-user: add contributors and set roles -**Shipped version:** 1.6.5~ynh1 +**Shipped version:** 1.6.5~ynh2 **Demo:** https://podcast.podlibre.org/@podlibre_fr diff --git a/README_fr.md b/README_fr.md index aa23611..443629c 100755 --- a/README_fr.md +++ b/README_fr.md @@ -31,7 +31,7 @@ Castopod est une plate-forme d'hébergement gratuite et open source conçue pour - Multi-locataire : hébergez autant de podcasts que vous le souhaitez - Multi-utilisateur : ajouter des contributeurs et définir des rôles -**Version incluse :** 1.6.5~ynh1 +**Version incluse :** 1.6.5~ynh2 **Démo :** https://podcast.podlibre.org/@podlibre_fr diff --git a/manifest.toml b/manifest.toml index de6c3ef..dc1c1cc 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Castopod" description.en = "Hosting platform made for podcasters" description.fr = "Plateforme d'hébergement conçue pour les podcasteurs" -version = "1.6.5~ynh1" +version = "1.6.5~ynh2" maintainers = ["eric_G"] diff --git a/scripts/install b/scripts/install index 94c4a4c..f84ad84 100755 --- a/scripts/install +++ b/scripts/install @@ -72,7 +72,7 @@ chown $app:www-data "$install_dir/.env" mkdir -p $data_dir/media cp -rf $install_dir/public/media/* $data_dir/media chmod -R 750 $data_dir -chgrp -R www-data $data_dir +chown -R $app:www-data $data_dir ynh_secure_remove --file="$install_dir/public/media" diff --git a/scripts/upgrade b/scripts/upgrade index 2fd85bc..8743ae1 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -47,13 +47,15 @@ if ynh_compare_current_package_version --comparison le --version "1.1.2~ynh2"; t mkdir -p $data_dir/media cp -rf $install_dir/public/media/* $data_dir/media chmod -R 750 $data_dir - chgrp -R www-data $data_dir + chown -R $app:www-data $data_dir ynh_secure_remove --file="$install_dir/public/media" ynh_script_progression --message="Fixing migrations..." --weight=1 # this will fail is `cp-install` was not run on prev version - just ignore, DB schema is (re)generated later. ynh_mysql_execute_as_root --database=$db_name --sql="UPDATE cp_migrations SET class='Media\\\\Database\\\\Migrations\\\\AddMedia', namespace='Media' where class='App\\\\Database\\\\Migrations\\\\AddMedia'" || true +elif ynh_compare_current_package_version --comparison lt --version "1.6.5~ynh2"; then + chown -R $app:www-data $data_dir fi #=================================================