1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/garradin_ynh.git synced 2024-09-03 18:36:17 +02:00

first try upgrading to 1.1.15 release disabling auto-upgrade need to change the config.local.php file

This commit is contained in:
Robles Rodolphe 2021-12-05 15:12:31 +01:00
parent 062a0dedc5
commit 9d8e07831b
6 changed files with 20 additions and 6 deletions

View file

@ -17,7 +17,7 @@ If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/in
Garradin (word meaning money in an aboriginal dialect of northern Australia, pronounced "gar-a-dine" em) is software for associative management. It is the tool of choice for managing an association, a sports club, an NGO, etc. It is designed to meet the needs of a small to medium-sized structure: management of members, accounting, website, note-taking in meetings, archiving and sharing of the association's operating documents, discussion between members, etc. etc. .
**Shipped version:** 1.1.14~ynh1
**Shipped version:** 1.1.15~ynh1
**Demo:** https://garradin.eu/essai/

View file

@ -13,7 +13,7 @@ Si vous n'avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) pour
Garradin (mot signifiant argent dans un dialecte aborigène du nord de l'Australie, prononcé « gar-a-dine »em) est un logiciel de gestion associative. Il est l'outil de prédilection pour gérer une association, un club sportif, une ONG, etc. Il est conçu pour répondre aux besoins d'une structure de petite à moyenne taille : gestion des adhérents, comptabilité, site web, prise de notes en réunion, archivage et partage des documents de fonctionnement de l'association, discussion entre adhérents, etc etc.
**Version incluse :** 1.1.14~ynh1
**Version incluse :** 1.1.15~ynh1
**Démo :** https://garradin.eu/essai/

View file

@ -1,5 +1,5 @@
SOURCE_URL=https://fossil.kd2.org/garradin/uv/garradin-1.1.14.tar.bz2
SOURCE_SUM=bd735252540c6d26a1593d61486881a296a9b4a166532083805808b015da33d7
SOURCE_URL=https://fossil.kd2.org/garradin/uv/garradin-1.1.15.tar.gz
SOURCE_SUM=451c87a356c942ecd2233684faf406d640fca7ca6a65856faf3f341c9941e2f3
SOURCE_SUM_PRG=sha256sum
SOURCE_FORMAT=tar.bz2
SOURCE_IN_SUBDIR=true

View file

@ -6,7 +6,7 @@
"en": "Software to manage association",
"fr": "Logiciel libre de gestion d'association"
},
"version": "1.1.14~ynh1",
"version": "1.1.15~ynh1",
"url": "http://garradin.eu",
"upstream": {
"license": "GPL-3.0-or-later",

View file

@ -94,6 +94,7 @@ if [ "$path_url" == "/" ]; then
else
ynh_replace_string --match_string="//const WWW_URI = '/asso/';" --replace_string="const WWW_URI = '$path_url/';" --target_file="$final_path/config.local.php"
fi
ynh_replace_string --match_string="//const ENABLE_UPGRADES = true;" --replace_string="//const ENABLE_UPGRADES = false;" --target_file="$final_path/config.local.php"
# Permissions on files and directories
chmod -R o-rwx "$final_path"

View file

@ -186,7 +186,7 @@ ynh_script_progression --message="Upgrading source files..." --weight=5
if [ "$upgrade_type" == "UPGRADE_APP" ]
then
# Download, check integrity, uncompress and patch the source from app.src
ynh_setup_source --keep="config.local.php" --dest_dir="$final_path"
ynh_setup_source --dest_dir="$final_path"
fi
#=================================================
@ -230,6 +230,19 @@ fi
#=================================================
ynh_script_progression --message="Adding a configuration file..." --weight=5
# copy config.dist.php creating config.local.php
cp -a $final_path/config.dist.php $final_path/config.local.php
# create a key for the secret key CSFR;
key=$(ynh_string_random --length=50)
# edit config.local.php
ynh_replace_string --match_string="const SECRET_KEY = '3xUhIgGwuovRKOjVsVPQ5yUMfXUSIOX2GKzcebsz5OINrYC50r';" --replace_string="const SECRET_KEY = '$key';" --target_file="$final_path/config.local.php"
if [ "$path_url" == "/" ]; then
ynh_replace_string --match_string="//const WWW_URI = '/asso/';" --replace_string="const WWW_URI = '$path_url';" --target_file="$final_path/config.local.php"
else
ynh_replace_string --match_string="//const WWW_URI = '/asso/';" --replace_string="const WWW_URI = '$path_url/';" --target_file="$final_path/config.local.php"
fi
ynh_replace_string --match_string="//const ENABLE_UPGRADES = true;" --replace_string="//const ENABLE_UPGRADES = false;" --target_file="$final_path/config.local.php"
# Permissions on files and directories
chmod -R o-rwx "$final_path"
chown -R $app:www-data "$final_path"