mirror of
https://github.com/YunoHost-Apps/ttrss_ynh.git
synced 2024-10-01 13:34:46 +02:00
parent
4978e6a961
commit
7e81de02ab
10 changed files with 41 additions and 35 deletions
|
@ -27,7 +27,7 @@ Tiny Tiny RSS is a free and open source web-based news feed (RSS/Atom) reader an
|
||||||
## Documentation
|
## Documentation
|
||||||
|
|
||||||
* Official documentation: https://git.tt-rss.org/git/tt-rss/wiki
|
* Official documentation: https://git.tt-rss.org/git/tt-rss/wiki
|
||||||
* YunoHost documentation: https://yunohost.org/#/app_ttrss
|
* YunoHost documentation: https://yunohost.org/en/app_ttrss
|
||||||
|
|
||||||
## YunoHost specific features
|
## YunoHost specific features
|
||||||
|
|
||||||
|
@ -35,8 +35,8 @@ Tiny Tiny RSS is a free and open source web-based news feed (RSS/Atom) reader an
|
||||||
|
|
||||||
#### Supported architectures
|
#### Supported architectures
|
||||||
|
|
||||||
* x86-64 - [![Build Status](https://ci-apps.yunohost.org/ci/logs/ttrss%20%28Apps%29.svg)](https://ci-apps.yunohost.org/ci/apps/ttrss/)
|
* x86-64 - [![Build Status](https://ci-apps.yunohost.org/ci/logs/ttrss.svg)](https://ci-apps.yunohost.org/ci/apps/ttrss/)
|
||||||
* ARMv8-A - [![Build Status](https://ci-apps-arm.yunohost.org/ci/logs/ttrss%20%28Apps%29.svg)](https://ci-apps-arm.yunohost.org/ci/apps/ttrss/)
|
* ARMv8-A - [![Build Status](https://ci-apps-arm.yunohost.org/ci/logs/ttrss.svg)](https://ci-apps-arm.yunohost.org/ci/apps/ttrss/)
|
||||||
|
|
||||||
## Limitations
|
## Limitations
|
||||||
|
|
||||||
|
|
|
@ -27,7 +27,7 @@ Tiny Tiny RSS est un lecteur et agrégateur de flux d'actualités (RSS/Atom) en
|
||||||
## Documentation
|
## Documentation
|
||||||
|
|
||||||
* Documentation officielle : https://git.tt-rss.org/git/tt-rss/wiki
|
* Documentation officielle : https://git.tt-rss.org/git/tt-rss/wiki
|
||||||
* Documentation YunoHost : https://yunohost.org/#/app_ttrss
|
* Documentation YunoHost : https://yunohost.org/fr/app_ttrss
|
||||||
|
|
||||||
## Caractéristiques spécifiques YunoHost
|
## Caractéristiques spécifiques YunoHost
|
||||||
|
|
||||||
|
@ -38,8 +38,8 @@ Tiny Tiny RSS est un lecteur et agrégateur de flux d'actualités (RSS/Atom) en
|
||||||
|
|
||||||
#### Architectures supportées
|
#### Architectures supportées
|
||||||
|
|
||||||
* x86-64 - [![Build Status](https://ci-apps.yunohost.org/ci/logs/ttrss%20%28Apps%29.svg)](https://ci-apps.yunohost.org/ci/apps/ttrss/)
|
* x86-64 - [![Build Status](https://ci-apps.yunohost.org/ci/logs/ttrss.svg)](https://ci-apps.yunohost.org/ci/apps/ttrss/)
|
||||||
* ARMv8-A - [![Build Status](https://ci-apps-arm.yunohost.org/ci/logs/ttrss%20%28Apps%29.svg)](https://ci-apps-arm.yunohost.org/ci/apps/ttrss/)
|
* ARMv8-A - [![Build Status](https://ci-apps-arm.yunohost.org/ci/logs/ttrss.svg)](https://ci-apps-arm.yunohost.org/ci/apps/ttrss/)
|
||||||
|
|
||||||
## Limitations
|
## Limitations
|
||||||
|
|
||||||
|
|
|
@ -13,7 +13,6 @@
|
||||||
upgrade=1 from_commit=e27175c2dde0ebbd483b212dc76c5b27877e4ed2
|
upgrade=1 from_commit=e27175c2dde0ebbd483b212dc76c5b27877e4ed2
|
||||||
backup_restore=1
|
backup_restore=1
|
||||||
multi_instance=1
|
multi_instance=1
|
||||||
port_already_use=0
|
|
||||||
change_url=1
|
change_url=1
|
||||||
;;; Options
|
;;; Options
|
||||||
Email=
|
Email=
|
||||||
|
|
|
@ -5,9 +5,9 @@
|
||||||
|
|
||||||
define('DB_TYPE', "mysql"); // or mysql
|
define('DB_TYPE', "mysql"); // or mysql
|
||||||
define('DB_HOST', "localhost");
|
define('DB_HOST', "localhost");
|
||||||
define('DB_USER', "__DBNAME__");
|
define('DB_USER', "__DB_NAME__");
|
||||||
define('DB_NAME', "__DBNAME__");
|
define('DB_NAME', "__DB_NAME__");
|
||||||
define('DB_PASS', "__DBPWD__");
|
define('DB_PASS', "__DB_PWD__");
|
||||||
define('DB_PORT', '3306'); // usually 5432 for PostgreSQL, 3306 for MySQL
|
define('DB_PORT', '3306'); // usually 5432 for PostgreSQL, 3306 for MySQL
|
||||||
|
|
||||||
define('MYSQL_CHARSET', 'UTF8');
|
define('MYSQL_CHARSET', 'UTF8');
|
||||||
|
@ -18,7 +18,7 @@
|
||||||
// *** Basic settings (important!) ***
|
// *** Basic settings (important!) ***
|
||||||
// ***********************************
|
// ***********************************
|
||||||
|
|
||||||
define('SELF_URL_PATH', '__DOMAINPATH__');
|
define('SELF_URL_PATH', '__DOMAIN_PATH__');
|
||||||
// Full URL of your tt-rss installation. This should be set to the
|
// Full URL of your tt-rss installation. This should be set to the
|
||||||
// location of tt-rss directory, e.g. http://example.org/tt-rss/
|
// location of tt-rss directory, e.g. http://example.org/tt-rss/
|
||||||
// You need to set this option correctly otherwise several features
|
// You need to set this option correctly otherwise several features
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
"en": "News feed (RSS/Atom) reader and aggregator.",
|
"en": "News feed (RSS/Atom) reader and aggregator.",
|
||||||
"fr": "Lecteur de flux d’actualité utilisant les protocoles RSS et Atom."
|
"fr": "Lecteur de flux d’actualité utilisant les protocoles RSS et Atom."
|
||||||
},
|
},
|
||||||
"version": "20200916~ynh2",
|
"version": "20200916~ynh3",
|
||||||
"url": "http://tt-rss.org",
|
"url": "http://tt-rss.org",
|
||||||
"license": "GPL-3.0-only",
|
"license": "GPL-3.0-only",
|
||||||
"maintainer": {
|
"maintainer": {
|
||||||
|
@ -14,12 +14,12 @@
|
||||||
"email": ""
|
"email": ""
|
||||||
},
|
},
|
||||||
"requirements": {
|
"requirements": {
|
||||||
"yunohost": ">= 3.8.1"
|
"yunohost": ">= 4.1.7"
|
||||||
},
|
},
|
||||||
"multi_instance": true,
|
"multi_instance": true,
|
||||||
"services": [
|
"services": [
|
||||||
"nginx",
|
"nginx",
|
||||||
"php7.0-fpm",
|
"php7.3-fpm",
|
||||||
"mysql"
|
"mysql"
|
||||||
],
|
],
|
||||||
"arguments": {
|
"arguments": {
|
||||||
|
@ -27,19 +27,11 @@
|
||||||
{
|
{
|
||||||
"name": "domain",
|
"name": "domain",
|
||||||
"type": "domain",
|
"type": "domain",
|
||||||
"ask": {
|
|
||||||
"en": "Choose a domain for Tiny Tiny RSS",
|
|
||||||
"fr": "Choisissez un domaine pour Tiny Tiny RSS"
|
|
||||||
},
|
|
||||||
"example": "domain.org"
|
"example": "domain.org"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "path",
|
"name": "path",
|
||||||
"type": "path",
|
"type": "path",
|
||||||
"ask": {
|
|
||||||
"en": "Choose a path for Tiny Tiny RSS",
|
|
||||||
"fr": "Choisissez un chemin pour Tiny Tiny RSS"
|
|
||||||
},
|
|
||||||
"example": "/ttrss",
|
"example": "/ttrss",
|
||||||
"default": "/ttrss"
|
"default": "/ttrss"
|
||||||
}
|
}
|
||||||
|
|
|
@ -13,6 +13,4 @@
|
||||||
|
|
||||||
## Package_check results
|
## Package_check results
|
||||||
---
|
---
|
||||||
*If you have access to [App Continuous Integration for packagers](https://yunohost.org/#/packaging_apps_ci) you can provide a link to the package_check results like below, replacing '-NUM-' in this link by the PR number and USERNAME by your username on the ci-apps-dev. Or you provide a screenshot or a pastebin of the results*
|
* An automatic package_check will be launch at https://ci-apps-dev.yunohost.org/, when you add a specific comment to your Pull Request: "!testme", "!gogogadgetoci" or "By the power of systemd, I invoke The Great App CI to test this Pull Request!"*
|
||||||
|
|
||||||
[![Build Status](https://ci-apps-dev.yunohost.org/jenkins/job/ttrss_ynh%20PR-NUM-%20(USERNAME)/badge/icon)](https://ci-apps-dev.yunohost.org/jenkins/job/ttrss_ynh%20PR-NUM-%20(USERNAME)/)
|
|
||||||
|
|
|
@ -30,6 +30,23 @@ final_path=$(ynh_app_setting_get --app=$app --key=final_path)
|
||||||
db_name=$(ynh_app_setting_get --app=$app --key=db_name)
|
db_name=$(ynh_app_setting_get --app=$app --key=db_name)
|
||||||
db_pwd=$(ynh_app_setting_get --app=$app --key=mysqlpwd)
|
db_pwd=$(ynh_app_setting_get --app=$app --key=mysqlpwd)
|
||||||
|
|
||||||
|
#=================================================
|
||||||
|
# BACKUP BEFORE UPGRADE THEN ACTIVE TRAP
|
||||||
|
#=================================================
|
||||||
|
ynh_script_progression --message="Backing up the app before changing its URL (may take a while)..." --time --weight=1
|
||||||
|
|
||||||
|
# Backup the current version of the app
|
||||||
|
ynh_backup_before_upgrade
|
||||||
|
ynh_clean_setup () {
|
||||||
|
# Remove the new domain config file, the remove script won't do it as it doesn't know yet its location.
|
||||||
|
ynh_secure_remove --file="/etc/nginx/conf.d/$new_domain.d/$app.conf"
|
||||||
|
|
||||||
|
# Restore it if the upgrade fails
|
||||||
|
ynh_restore_upgradebackup
|
||||||
|
}
|
||||||
|
# Exit if an error occurs during the execution of the script
|
||||||
|
ynh_abort_if_errors
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# CHECK WHICH PARTS SHOULD BE CHANGED
|
# CHECK WHICH PARTS SHOULD BE CHANGED
|
||||||
#=================================================
|
#=================================================
|
||||||
|
@ -90,9 +107,9 @@ ynh_backup_if_checksum_is_different --file="$final_path/config.php"
|
||||||
cp ../conf/config.php "$final_path/config.php"
|
cp ../conf/config.php "$final_path/config.php"
|
||||||
|
|
||||||
# Change domain name in config.php
|
# Change domain name in config.php
|
||||||
ynh_replace_string --match_string="__DBNAME__" --replace_string="$db_name" --target_file="$final_path/config.php"
|
ynh_replace_string --match_string="__DB_NAME__" --replace_string="$db_name" --target_file="$final_path/config.php"
|
||||||
ynh_replace_string --match_string="__DBPWD__" --replace_string="$db_pwd" --target_file="$final_path/config.php"
|
ynh_replace_string --match_string="__DB_PWD__" --replace_string="$db_pwd" --target_file="$final_path/config.php"
|
||||||
ynh_replace_string --match_string="__DOMAINPATH__" --replace_string="https://$domain$path_url" --target_file="$final_path/config.php"
|
ynh_replace_string --match_string="__DOMAIN_PATH__" --replace_string="https://$domain$path_url" --target_file="$final_path/config.php"
|
||||||
|
|
||||||
# Recalculate and store the config file checksum into the app settings
|
# Recalculate and store the config file checksum into the app settings
|
||||||
ynh_store_file_checksum --file="$final_path/config.php"
|
ynh_store_file_checksum --file="$final_path/config.php"
|
||||||
|
|
|
@ -100,9 +100,9 @@ ynh_script_progression --message="Configuring ttrss..." --weight=1
|
||||||
cp ../conf/config.php "$final_path/config.php"
|
cp ../conf/config.php "$final_path/config.php"
|
||||||
|
|
||||||
# Change variables in ttrss configuration
|
# Change variables in ttrss configuration
|
||||||
ynh_replace_string --match_string="__DBNAME__" --replace_string="$db_name" --target_file="$final_path/config.php"
|
ynh_replace_string --match_string="__DB_NAME__" --replace_string="$db_name" --target_file="$final_path/config.php"
|
||||||
ynh_replace_string --match_string="__DBPWD__" --replace_string="$db_pwd" --target_file="$final_path/config.php"
|
ynh_replace_string --match_string="__DB_PWD__" --replace_string="$db_pwd" --target_file="$final_path/config.php"
|
||||||
ynh_replace_string --match_string="__DOMAINPATH__" --replace_string="https://$domain$path_url" --target_file="$final_path/config.php"
|
ynh_replace_string --match_string="__DOMAIN_PATH__" --replace_string="https://$domain$path_url" --target_file="$final_path/config.php"
|
||||||
|
|
||||||
# Recalculate and store the config file checksum into the app settings
|
# Recalculate and store the config file checksum into the app settings
|
||||||
ynh_store_file_checksum --file="$final_path/config.php"
|
ynh_store_file_checksum --file="$final_path/config.php"
|
||||||
|
|
|
@ -19,7 +19,7 @@ ynh_abort_if_errors
|
||||||
#=================================================
|
#=================================================
|
||||||
# LOAD SETTINGS
|
# LOAD SETTINGS
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Loading settings..." --weight=1
|
ynh_script_progression --message="Loading settings..." --weight=1
|
||||||
|
|
||||||
app=$YNH_APP_INSTANCE_NAME
|
app=$YNH_APP_INSTANCE_NAME
|
||||||
|
|
||||||
|
|
|
@ -133,9 +133,9 @@ then
|
||||||
cp ../conf/config.php "$final_path/config.php"
|
cp ../conf/config.php "$final_path/config.php"
|
||||||
|
|
||||||
# Change variables in ttrss configuration
|
# Change variables in ttrss configuration
|
||||||
ynh_replace_string --match_string="__DBNAME__" --replace_string="$db_name" --target_file="$final_path/config.php"
|
ynh_replace_string --match_string="__DB_NAME__" --replace_string="$db_name" --target_file="$final_path/config.php"
|
||||||
ynh_replace_string --match_string="__DBPWD__" --replace_string="$db_pwd" --target_file="$final_path/config.php"
|
ynh_replace_string --match_string="__DB_PWD__" --replace_string="$db_pwd" --target_file="$final_path/config.php"
|
||||||
ynh_replace_string --match_string="__DOMAINPATH__" --replace_string="https://$domain$path_url" --target_file="$final_path/config.php"
|
ynh_replace_string --match_string="__DOMAIN_PATH__" --replace_string="https://$domain$path_url" --target_file="$final_path/config.php"
|
||||||
|
|
||||||
# Recalculate and store the config file checksum into the app settings
|
# Recalculate and store the config file checksum into the app settings
|
||||||
ynh_store_file_checksum --file="$final_path/config.php"
|
ynh_store_file_checksum --file="$final_path/config.php"
|
||||||
|
|
Loading…
Reference in a new issue