1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/friendica_ynh.git synced 2024-09-03 18:36:14 +02:00
This commit is contained in:
ericgaspar 2021-07-19 10:27:45 +02:00
parent de5e792c63
commit f6ba6ad505
No known key found for this signature in database
GPG key ID: 574F281483054D44
4 changed files with 14 additions and 9 deletions

View file

@ -68,6 +68,11 @@ ynh_script_progression --message="Removing logrotate configuration..." --weight=
# Remove the app-specific logrotate config # Remove the app-specific logrotate config
ynh_remove_logrotate ynh_remove_logrotate
#=================================================
# REMOVE CRON FILE
#=================================================
ynh_script_progression --message="Removing cron file..." --weight=1
# Remove a cron file # Remove a cron file
ynh_secure_remove --file="/etc/cron.d/$app" ynh_secure_remove --file="/etc/cron.d/$app"

View file

@ -82,7 +82,7 @@ ynh_restore_file --origin_path="$final_path"
chmod 750 "$final_path" chmod 750 "$final_path"
chmod -R o-rwx "$final_path" chmod -R o-rwx "$final_path"
chown -R $app:www-data "$final_path" chown -R $app:www-data "$final_path"
chmod -R 775 $final_path/view/smarty3 chmod -R 775 "$final_path/view/smarty3"
#================================================= #=================================================
# RESTORE THE PHP-FPM CONFIGURATION # RESTORE THE PHP-FPM CONFIGURATION

View file

@ -107,7 +107,7 @@ then
# Check if the repo can be updated with git # Check if the repo can be updated with git
if [ `cd $final_path && git rev-parse --is-inside-work-tree` ]; if [ `cd $final_path && git rev-parse --is-inside-work-tree` ];
then then
# Update through git # Update through Git
pushd "$final_path" pushd "$final_path"
git fetch git fetch
git checkout stable git checkout stable
@ -120,7 +120,7 @@ then
git pull git pull
git reset --hard $addons_version_commit git reset --hard $addons_version_commit
popd popd
# If git is not present upgrade through manual method # If Git is not present upgrade through manual method
else else
# Create a temporary directory and backup smarty3 folder # Create a temporary directory and backup smarty3 folder
@ -132,14 +132,14 @@ else
ynh_secure_remove "$final_path" ynh_secure_remove "$final_path"
# 1 - Clone stable repo # 1 - Clone stable repo
git clone https://github.com/friendica/friendica.git -b stable "$final_path" git clone --quiet https://github.com/friendica/friendica.git -b stable "$final_path"
# Reset branch to the level of update we needed # Reset branch to the level of update we needed
pushd "$final_path" pushd "$final_path"
git reset --hard $version_commit git reset --hard $version_commit
popd popd
# 2 - Clone addons repo # 2 - Clone addons repo
git clone https://github.com/friendica/friendica-addons.git -b stable "$final_path/addon" git clone --quiet https://github.com/friendica/friendica-addons.git -b stable "$final_path/addon"
# Reset addons branch to the level of update we needed # Reset addons branch to the level of update we needed
pushd "$final_path/addon" pushd "$final_path/addon"
git reset --hard $addons_version_commit git reset --hard $addons_version_commit
@ -159,7 +159,7 @@ chmod -R o-rwx "$final_path"
chown -R $app:www-data "$final_path" chown -R $app:www-data "$final_path"
# 3 - some extra folders # 3 - some extra folders
chmod -R 775 $final_path/view/smarty3 chmod -R 775 "$final_path/view/smarty3"
#================================================= #=================================================
# NGINX CONFIGURATION # NGINX CONFIGURATION