1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/movim_ynh.git synced 2024-09-03 19:46:19 +02:00
This commit is contained in:
Éric Gaspar 2023-09-28 13:55:52 +02:00
parent 16baa39e6b
commit 90d8889280
2 changed files with 10 additions and 11 deletions

View file

@ -23,7 +23,7 @@ multi_instance = false
ldap = false
sso = true
disk = "50M"
ram.build = "50M"
ram.build = "100M"
ram.runtime = "50M"
[install]

View file

@ -36,19 +36,19 @@ ynh_systemd_action --service_name=$app --action="stop" --log_path="systemd" --li
ynh_script_progression --message="Ensuring downward compatibility..."
# If fpm_footprint doesn't exist, create it
if [ -z "$fpm_footprint" ]; then
if [ -z "${fpm_footprint:-}" ]; then
fpm_footprint=low
ynh_app_setting_set --app=$app --key=fpm_footprint --value=$fpm_footprint
fi
# If fpm_free_footprint doesn't exist, create it
if [ -z "$fpm_free_footprint" ]; then
if [ -z "${fpm_free_footprint:-}" ]; then
fpm_free_footprint=0
ynh_app_setting_set --app=$app --key=fpm_free_footprint --value=$fpm_free_footprint
fi
# If fpm_usage doesn't exist, create it
if [ -z "$fpm_usage" ]; then
if [ -z "${fpm_usage:-}" ]; then
fpm_usage=low
ynh_app_setting_set --app=$app --key=fpm_usage --value=$fpm_usage
fi
@ -62,10 +62,8 @@ then
ynh_script_progression --message="Upgrading source files..."
# Download, check integrity, uncompress and patch the source from app.src
ynh_setup_source --dest_dir="$install_dir" --keep="config/db.inc.php"
ynh_setup_source --dest_dir="$install_dir"
# Temporary workaround to fix movim.ERROR: Error: Call to undefined function GuzzleHttp\Psr7\uri_for()
#ynh_replace_string --match_string="0.3.5" --replace_string="0.4.1" --target_file="$install_dir/composer.json"
fi
chmod -R o-rwx "$install_dir"
@ -104,10 +102,11 @@ chown $app:$app "$install_dir/config/.env"
#=================================================
ynh_script_progression --message="Building Movim..."
ynh_exec_warn_less ynh_install_composer --phpversion="$phpversion" --workdir="$install_dir"
ynh_exec_warn_less ynh_composer_exec --phpversion="$phpversion" --workdir="$install_dir" --commands="config --global discard-changes true --quiet"
ynh_exec_warn_less ynh_composer_exec --phpversion="$phpversion" --workdir="$install_dir" --commands="update --no-interaction --quiet"
ynh_exec_warn_less ynh_composer_exec --phpversion="$phpversion" --workdir="$install_dir" --commands="movim:migrate --quiet"
ynh_exec_warn_less ynh_install_composer
ynh_exec_warn_less ynh_composer_exec --commands="config --global discard-changes true --quiet"
ynh_exec_warn_less ynh_composer_exec --commands="update --no-interaction --quiet"
ynh_exec_warn_less ynh_composer_exec --commands="movim:migrate --quiet"
#=================================================
# START SYSTEMD SERVICE