1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/lychee_ynh.git synced 2024-09-03 19:36:36 +02:00
This commit is contained in:
ericgaspar 2021-01-28 12:57:15 +01:00
parent 48744ce986
commit 91cae0406f
No known key found for this signature in database
GPG key ID: 574F281483054D44
2 changed files with 10 additions and 6 deletions

View file

@ -102,7 +102,7 @@ phpversion=$(ynh_app_setting_get --app=$app --key=phpversion)
ynh_script_progression --message="Installing Lychee with Composer..." --weight=15
# Install composer
ynh_install_composer --phpversion="${YNH_PHP_VERSION}" --workdir="$final_path" --install_args="--prefer-source --no-dev"
ynh_install_composer --phpversion="$phpversion" --workdir="$final_path" --install_args="--prefer-source --no-dev"
#=================================================
# BUILDING
@ -117,10 +117,12 @@ ynh_replace_string --match_string="__DB_PASS__" --replace_string="$db_pwd" --tar
ynh_replace_string --match_string="__APP__" --replace_string="$app" --target_file="$final_path/.env"
# setup application config
cd $final_path && php$phpversion artisan key:generate -n --force --env
cd $final_path && php$phpversion artisan migrate -n --force
cd $final_path && php$phpversion artisan config:clear -n
cd $final_path && php$phpversion artisan config:cache -n
pushd $final_path
hp$phpversion artisan key:generate -n --force --env
php$phpversion artisan migrate -n --force
php$phpversion artisan config:clear -n
php$phpversion artisan config:cache -n
popd
#=================================================
# STORE THE CONFIG FILE CHECKSUM

View file

@ -117,7 +117,9 @@ ynh_script_progression --message="Installing Composer..." --weight=10
ynh_install_composer --phpversion="${YNH_PHP_VERSION}" --workdir="$final_path" --install_args="--prefer-source --no-dev"
cd $final_path && php$phpversion artisan migrate -n --force
pushd $final_path
php$phpversion artisan migrate #-n --force
popd
ynh_backup_if_checksum_is_different --file="$final_path/.env"
# Recalculate and store the checksum of the file for the next upgrade.