1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/alltube_ynh.git synced 2024-09-03 18:06:12 +02:00

Merge pull request #24 from YunoHost-Apps/4.3

4.3
This commit is contained in:
Alexandre Aubin 2021-11-29 19:26:00 +01:00 committed by GitHub
commit bc775fc2da
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 7 additions and 22 deletions

View file

@ -4,11 +4,6 @@ location __PATH__/ {
# Path to source
alias __FINALPATH__/ ;
# Force usage of https
if ($scheme = http) {
rewrite ^ https://$server_name$request_uri? permanent;
}
index index.php;
try_files $uri @__NAME__;

View file

@ -21,7 +21,7 @@
"email": "plopoyop@gmail.com"
},
"requirements": {
"yunohost": ">= 4.2.0"
"yunohost": ">= 4.3.0"
},
"multi_instance": true,
"services": [
@ -32,8 +32,7 @@
"install" : [
{
"name": "domain",
"type": "domain",
"example": "example.com"
"type": "domain"
},
{
"name": "path",

View file

@ -4,12 +4,9 @@
# COMMON VARIABLES
#=================================================
# dependencies used by the app
pkg_dependencies="ffmpeg"
YNH_PHP_VERSION="7.3"
extra_php_dependencies="php${YNH_PHP_VERSION}-intl php${YNH_PHP_VERSION}-curl php${YNH_PHP_VERSION}-gmp php${YNH_PHP_VERSION}-mbstring"
pkg_dependencies="ffmpeg php${YNH_PHP_VERSION}-intl php${YNH_PHP_VERSION}-curl php${YNH_PHP_VERSION}-gmp php${YNH_PHP_VERSION}-mbstring"
#=================================================
# PERSONAL HELPERS

View file

@ -92,11 +92,12 @@ ynh_add_nginx_config
ynh_script_progression --message="Configuring PHP-FPM..." --weight=1
# Create a dedicated php-fpm config
ynh_add_fpm_config --usage=low --footprint=low --package="$extra_php_dependencies"
ynh_add_fpm_config --usage=low --footprint=low
#=================================================
# SPECIFIC SETUP
#=================================================
ynh_script_progression --message="Adding a configuration file..." --weight=1
cp ../conf/config.yml "$final_path/config/"

View file

@ -34,10 +34,7 @@ phpversion=$(ynh_app_setting_get --app=$app --key=phpversion)
#=================================================
ynh_script_progression --message="Validating restoration parameters..." --weight=1
ynh_webpath_available --domain=$domain --path_url=$path_url \
|| ynh_die --message="Path not available: ${domain}${path_url}"
test ! -d $final_path \
|| ynh_die --message="There is already a directory: $final_path "
test ! -d $final_path || ynh_die --message="There is already a directory: $final_path "
#=================================================
# STANDARD RESTORATION STEPS
@ -74,9 +71,6 @@ ynh_script_progression --message="Restoring PHP-FPM configuration..."
ynh_restore_file --origin_path="/etc/php/$phpversion/fpm/pool.d/$app.conf"
# Recreate a dedicated php-fpm config
ynh_add_fpm_config --usage=low --footprint=low --package="$extra_php_dependencies"
#=================================================
# SPECIFIC RESTORATION
#=================================================

View file

@ -23,7 +23,6 @@ final_path=$(ynh_app_setting_get --app=$app --key=final_path)
#=================================================
# CHECK VERSION
#=================================================
ynh_script_progression --message="Checking version..."
upgrade_type=$(ynh_check_app_version_changed)
@ -106,7 +105,7 @@ ynh_install_app_dependencies $pkg_dependencies
ynh_script_progression --message="Upgrading PHP-FPM configuration..." --weight=1
# Create a dedicated php-fpm config
ynh_add_fpm_config --usage=low --footprint=low --package="$extra_php_dependencies"
ynh_add_fpm_config --usage=low --footprint=low
#=================================================
# SPECIFIC UPGRADE