1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/ttrss_ynh.git synced 2024-10-01 13:34:46 +02:00
This commit is contained in:
Éric Gaspar 2024-09-08 12:51:04 +02:00
parent f6957b065c
commit 6c2e258383
7 changed files with 7 additions and 17 deletions

View file

@ -5,7 +5,7 @@ name = "Tiny Tiny RSS"
description.en = "News feed (RSS/Atom) reader and aggregator" description.en = "News feed (RSS/Atom) reader and aggregator"
description.fr = "Lecteur de flux dactualité utilisant les protocoles RSS et Atom" description.fr = "Lecteur de flux dactualité utilisant les protocoles RSS et Atom"
version = "20240831~ynh1" version = "20240831~ynh2"
maintainers = [] maintainers = []
@ -17,7 +17,7 @@ admindoc = "https://tt-rss.org/wiki.php"
code = "https://gitlab.tt-rss.org/tt-rss/tt-rss" code = "https://gitlab.tt-rss.org/tt-rss/tt-rss"
[integration] [integration]
yunohost = ">= 11.2.29" yunohost = ">= 11.2.30"
helpers_version = "2.1" helpers_version = "2.1"
architectures = "all" architectures = "all"
multi_instance = true multi_instance = true

View file

@ -12,7 +12,7 @@ ynh_print_info "Declaring files to be backed up..."
ynh_backup "$install_dir" ynh_backup "$install_dir"
#================================================= #=================================================
# BACKUP THE NGINX CONFIGURATION # SYSTEM CONFIGURATION
#================================================= #=================================================
ynh_backup "/etc/nginx/conf.d/$domain.d/$app.conf" ynh_backup "/etc/nginx/conf.d/$domain.d/$app.conf"

View file

@ -17,8 +17,6 @@ ynh_script_progression "Updating NGINX web server configuration..."
ynh_config_change_url_nginx ynh_config_change_url_nginx
#=================================================
# SPECIFIC MODIFICATIONS
#================================================= #=================================================
# UPDATE A CONFIG FILE # UPDATE A CONFIG FILE
#================================================= #=================================================

View file

@ -11,6 +11,7 @@ ynh_app_setting_set --key=php_upload_max_filesize --value=10M
ynh_script_progression "Setting up source files..." ynh_script_progression "Setting up source files..."
ynh_setup_source --dest_dir="$install_dir" ynh_setup_source --dest_dir="$install_dir"
echo "$(ynh_app_upstream_version)" > "$install_dir/version_static.txt" echo "$(ynh_app_upstream_version)" > "$install_dir/version_static.txt"
#================================================= #=================================================
@ -18,19 +19,14 @@ echo "$(ynh_app_upstream_version)" > "$install_dir/version_static.txt"
#================================================= #=================================================
ynh_script_progression "Adding system configurations related to $app..." ynh_script_progression "Adding system configurations related to $app..."
# Create a dedicated PHP-FPM config
ynh_config_add_phpfpm ynh_config_add_phpfpm
# Create a dedicated NGINX config
ynh_config_add_nginx ynh_config_add_nginx
# Create a dedicated systemd config
ynh_config_add_systemd ynh_config_add_systemd
yunohost service add $app --description="News feed reader and aggregator" --log="/var/log/$app/$app.log" yunohost service add $app --description="News feed reader and aggregator" --log="/var/log/$app/$app.log"
#=================================================
# SPECIFIC SETUP
#================================================= #=================================================
# ADD A CONFIGURATION # ADD A CONFIGURATION
#================================================= #=================================================
@ -43,8 +39,7 @@ ynh_config_add --template="config.php" --destination="$install_dir/config.php"
#================================================= #=================================================
ynh_script_progression "Initializing database..." ynh_script_progression "Initializing database..."
ynh_psql_db_shell \ ynh_psql_db_shell < "$install_dir/schema/ttrss_schema_pgsql.sql"
< "$install_dir/schema/ttrss_schema_pgsql.sql"
ynh_exec_as_app php$php_version $install_dir/update.php --update-schema=force-yes ynh_exec_as_app php$php_version $install_dir/update.php --update-schema=force-yes
@ -53,7 +48,6 @@ ynh_exec_as_app php$php_version $install_dir/update.php --update-schema=force-ye
#================================================= #=================================================
ynh_script_progression "Starting $app's systemd service..." ynh_script_progression "Starting $app's systemd service..."
# Start a systemd service
ynh_systemctl --service=$app --action="start" --log_path="systemd" ynh_systemctl --service=$app --action="start" --log_path="systemd"
#================================================= #=================================================

View file

@ -5,9 +5,6 @@ source /usr/share/yunohost/helpers
#================================================= #=================================================
# REMOVE SYSTEM CONFIGURATIONS # REMOVE SYSTEM CONFIGURATIONS
#=================================================
# REMOVE SYSTEMD SERVICE
#================================================= #=================================================
ynh_script_progression "Removing system configurations related to $app..." ynh_script_progression "Removing system configurations related to $app..."

View file

@ -37,8 +37,8 @@ yunohost service add $app --description="News feed reader and aggregator" --log=
ynh_script_progression "Starting $app's systemd service..." ynh_script_progression "Starting $app's systemd service..."
ynh_systemctl --service=$app --action="start" --log_path="systemd" ynh_systemctl --service=$app --action="start" --log_path="systemd"
ynh_systemctl --service=php$php_version-fpm --action=reload ynh_systemctl --service=php$php_version-fpm --action=reload
ynh_systemctl --service=nginx --action=reload ynh_systemctl --service=nginx --action=reload
#================================================= #=================================================

View file

@ -25,6 +25,7 @@ ynh_safe_rm "/etc/cron.d/$app"
ynh_script_progression "Upgrading source files..." ynh_script_progression "Upgrading source files..."
ynh_setup_source --dest_dir="$install_dir" ynh_setup_source --dest_dir="$install_dir"
echo "$(ynh_app_upstream_version)" > "$install_dir/version_static.txt" echo "$(ynh_app_upstream_version)" > "$install_dir/version_static.txt"
#================================================= #=================================================