mirror of
https://github.com/YunoHost-Apps/commento_ynh.git
synced 2024-09-03 18:16:16 +02:00
cleaning
This commit is contained in:
parent
45e280395b
commit
ad35d09524
5 changed files with 11 additions and 22 deletions
|
@ -7,7 +7,7 @@ description.fr = "Plateforme de commentaires rapide axée sur la confidentialit
|
||||||
|
|
||||||
version = "1.8.7~ynh2"
|
version = "1.8.7~ynh2"
|
||||||
|
|
||||||
maintainers = ["eric_G"]
|
maintainers = []
|
||||||
|
|
||||||
[upstream]
|
[upstream]
|
||||||
license = "MIT"
|
license = "MIT"
|
||||||
|
@ -20,8 +20,11 @@ code = "https://github.com/souramoo/commentoplusplus"
|
||||||
yunohost = ">= 11.2"
|
yunohost = ">= 11.2"
|
||||||
architectures = ["amd64"]
|
architectures = ["amd64"]
|
||||||
multi_instance = true
|
multi_instance = true
|
||||||
|
|
||||||
ldap = false
|
ldap = false
|
||||||
|
|
||||||
sso = false
|
sso = false
|
||||||
|
|
||||||
disk = "50M"
|
disk = "50M"
|
||||||
ram.build = "150M"
|
ram.build = "150M"
|
||||||
ram.runtime = "50M"
|
ram.runtime = "50M"
|
||||||
|
|
|
@ -22,15 +22,11 @@ ynh_print_info --message="Declaring files to be backed up..."
|
||||||
ynh_backup --src_path="$install_dir"
|
ynh_backup --src_path="$install_dir"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# BACKUP THE NGINX CONFIGURATION
|
# SYSTEM CONFIGURATION
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
||||||
ynh_backup --src_path="/etc/nginx/conf.d/$domain.d/$app.conf"
|
ynh_backup --src_path="/etc/nginx/conf.d/$domain.d/$app.conf"
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# BACKUP SYSTEMD
|
|
||||||
#=================================================
|
|
||||||
|
|
||||||
ynh_backup --src_path="/etc/systemd/system/$app.service"
|
ynh_backup --src_path="/etc/systemd/system/$app.service"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
|
@ -31,7 +31,7 @@ ynh_change_url_nginx_config
|
||||||
ynh_script_progression --message="Adding a configuration file..." --weight=1
|
ynh_script_progression --message="Adding a configuration file..." --weight=1
|
||||||
|
|
||||||
domain="$new_domain"
|
domain="$new_domain"
|
||||||
ynh_add_config --template="../conf/.env" --destination="$install_dir/commento.env"
|
ynh_add_config --template=".env" --destination="$install_dir/commento.env"
|
||||||
|
|
||||||
chmod 400 "$install_dir/commento.env"
|
chmod 400 "$install_dir/commento.env"
|
||||||
chown $app:$app "$install_dir/commento.env"
|
chown $app:$app "$install_dir/commento.env"
|
||||||
|
|
|
@ -45,7 +45,7 @@ yunohost service add $app --description="Privacy-focused commenting platform" --
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Adding a configuration file..." --weight=1
|
ynh_script_progression --message="Adding a configuration file..." --weight=1
|
||||||
|
|
||||||
ynh_add_config --template="../conf/.env" --destination="$install_dir/commento.env"
|
ynh_add_config --template=".env" --destination="$install_dir/commento.env"
|
||||||
|
|
||||||
chmod 400 "$install_dir/commento.env"
|
chmod 400 "$install_dir/commento.env"
|
||||||
chown $app:$app "$install_dir/commento.env"
|
chown $app:$app "$install_dir/commento.env"
|
||||||
|
|
|
@ -9,12 +9,6 @@
|
||||||
source _common.sh
|
source _common.sh
|
||||||
source /usr/share/yunohost/helpers
|
source /usr/share/yunohost/helpers
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# CHECK VERSION
|
|
||||||
#=================================================
|
|
||||||
|
|
||||||
upgrade_type=$(ynh_check_app_version_changed)
|
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# STANDARD UPGRADE STEPS
|
# STANDARD UPGRADE STEPS
|
||||||
#=================================================
|
#=================================================
|
||||||
|
@ -37,14 +31,10 @@ fi
|
||||||
#=================================================
|
#=================================================
|
||||||
# DOWNLOAD, CHECK AND UNPACK SOURCE
|
# DOWNLOAD, CHECK AND UNPACK SOURCE
|
||||||
#=================================================
|
#=================================================
|
||||||
|
ynh_script_progression --message="Upgrading source files..." --weight=1
|
||||||
|
|
||||||
if [ "$upgrade_type" == "UPGRADE_APP" ]
|
# Download, check integrity, uncompress and patch the source from app.src
|
||||||
then
|
ynh_setup_source --dest_dir="$install_dir" #--keep="commento.env"
|
||||||
ynh_script_progression --message="Upgrading source files..." --weight=1
|
|
||||||
|
|
||||||
# Download, check integrity, uncompress and patch the source from app.src
|
|
||||||
ynh_setup_source --dest_dir="$install_dir" #--keep="commento.env"
|
|
||||||
fi
|
|
||||||
|
|
||||||
chmod -R o-rwx "$install_dir"
|
chmod -R o-rwx "$install_dir"
|
||||||
chown -R $app:www-data "$install_dir"
|
chown -R $app:www-data "$install_dir"
|
||||||
|
@ -67,7 +57,7 @@ yunohost service add $app --description="Privacy-focused commenting platform" --
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Updating a configuration file..." --weight=1
|
ynh_script_progression --message="Updating a configuration file..." --weight=1
|
||||||
|
|
||||||
ynh_add_config --template="../conf/.env" --destination="$install_dir/commento.env"
|
ynh_add_config --template=".env" --destination="$install_dir/commento.env"
|
||||||
|
|
||||||
chmod 400 "$install_dir/commento.env"
|
chmod 400 "$install_dir/commento.env"
|
||||||
chown $app:$app "$install_dir/commento.env"
|
chown $app:$app "$install_dir/commento.env"
|
||||||
|
|
Loading…
Add table
Reference in a new issue