1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/baikal_ynh.git synced 2024-09-03 18:16:11 +02:00

Merge pull request #44 from YunoHost-Apps/0.6.0

Upgrade to 0.6.0
This commit is contained in:
Kayou 2020-03-18 14:01:50 +01:00 committed by GitHub
commit 9331c8fae0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 18 additions and 9 deletions

View file

@ -10,7 +10,7 @@ If you don't have YunoHost, please see [here](https://yunohost.org/#/install) to
[Baïkal](http://baikal-server.com/) is a CalDAV and CardDAV server, based on
sabre/dav, that includes an administration interface for easy management.
**Shipped version:** 0.5.3
**Shipped version:** 0.6.1
## Screenshots

View file

@ -1,5 +1,5 @@
SOURCE_URL=https://github.com/sabre-io/Baikal/releases/download/0.5.3/baikal-0.5.3.zip
SOURCE_SUM=11e6971a3cdc4c0cfc36e82498809162b5a6cfb67545f0dbc5b9d9e0c28c93c0
SOURCE_URL=https://github.com/sabre-io/Baikal/releases/download/0.6.1/baikal-0.6.1.zip
SOURCE_SUM=b3a553591a84f4262a6333cf79a1624e5d424d52c4071c77934b7191f714d757
SOURCE_SUM_PRG=sha256sum
SOURCE_FORMAT=zip
SOURCE_IN_SUBDIR=true

View file

@ -59,4 +59,4 @@ define("BAIKAL_DAV_LDAP_DISPLAYNAME_ATTR", 'cn');
define("BAIKAL_DAV_LDAP_EMAIL_ATTR", 'mail');
# Baïkal Web admin password hash; Set via Baïkal Web Admin
define("BAIKAL_ADMIN_PASSWORDHASH", '__PASSWORDHASH__');
define("BAIKAL_ADMIN_PASSWORDHASH", '__PASSWORDHASH__');

View file

@ -69,4 +69,4 @@ define("PROJECT_DB_MYSQL_PASSWORD", '__DBPASS__');
define("BAIKAL_ENCRYPTION_KEY", '__DESKEY__');
# The currently configured Baïkal version
define("BAIKAL_CONFIGURED_VERSION", '0.5.3');
define("BAIKAL_CONFIGURED_VERSION", '0.6.1');

View file

@ -6,7 +6,7 @@
"en": "Lightweight CalDAV+CardDAV server",
"fr": "Serveur CalDAV+CardDAV léger"
},
"version": "0.5.3~ynh1",
"version": "0.6.1~ynh1",
"url": "http://baikal-server.com/",
"license": "GPL-3.0",
"maintainer": {

View file

@ -75,8 +75,16 @@ if [ "$upgrade_type" == "UPGRADE_APP" ]
then
ynh_script_progression --message="Upgrading source files..." --weight=3
# Keep the Specific folder intact: https://sabre.io/baikal/upgrade/
temp_folder=$(mktemp -d)
mv "$final_path/Specific" "$temp_folder"
# Download, check integrity, uncompress and patch the source from app.src
ynh_setup_source --dest_dir="$final_path"
ynh_secure_remove --file="$final_path/Specific"
mv "$temp_folder/Specific" "$final_path"
ynh_secure_remove --file="$temp_folder"
fi
#=================================================
@ -141,7 +149,7 @@ then
ynh_replace_string --match_string="__TIMEZONE__" --replace_string="$(cat /etc/timezone)" --target_file="$bk_conf"
password_hash=$(ynh_app_setting_get $app password_hash)
password_hash=$(ynh_app_setting_get --app=$app --key=password_hash)
# If the password_hash is not in the app's config, recreate it from the password.
if [ -z "$password_hash" ]; then
password=$(ynh_app_setting_get --app=$app --key=password)
@ -163,10 +171,11 @@ then
ynh_replace_string --match_string="__PATH__" --replace_string="$path_url" --target_file="$bk_conf"
ynh_replace_string --match_string="__DBNAME__" --replace_string="$db_name" --target_file="$bk_conf"
ynh_replace_string --match_string="__DBUSER__" --replace_string="$db_name" --target_file="$bk_conf"
db_pwd=$(ynh_app_setting_get $app mysqlpwd)
db_pwd=$(ynh_app_setting_get --app=$app --key=mysqlpwd)
ynh_replace_string --match_string="__DBPASS__" --replace_string="$db_pwd" --target_file="$bk_conf"
deskey=$(ynh_app_setting_get $app deskey)
deskey=$(ynh_app_setting_get --app=$app --key=encrypt_key)
ynh_replace_string --match_string="__DESKEY__" --replace_string="$deskey" --target_file="$bk_conf"
# Store the config file checksum into the app settings