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

Upgrade to 4.1.0

This commit is contained in:
ericgaspar 2021-03-19 12:28:27 +01:00
parent 74daeee17d
commit 6033cd21ad
No known key found for this signature in database
GPG key ID: 574F281483054D44
7 changed files with 20 additions and 36 deletions

View file

@ -1,7 +1,6 @@
# Ghost for YunoHost
[![Integration level](https://dash.yunohost.org/integration/ghost.svg)](https://dash.yunohost.org/appci/app/ghost) ![](https://ci-apps.yunohost.org/ci/badges/ghost.status.svg) ![](https://ci-apps.yunohost.org/ci/badges/ghost.maintain.svg)
[![Integration level](https://dash.yunohost.org/integration/ghost.svg)](https://dash.yunohost.org/appci/app/ghost) ![](https://ci-apps.yunohost.org/ci/badges/ghost.status.svg) ![](https://ci-apps.yunohost.org/ci/badges/ghost.maintain.svg)
[![Install Ghost with YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=ghost)
> *This package allows you to install Ghost quickly and simply on a YunoHost server.
@ -10,7 +9,7 @@ If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/in
## Overview
Ghost is a fully open source, adaptable platform for building and running a modern online publication.
**Shipped version:** 3.41.8
**Shipped version:** 4.1.0
## Screenshots

View file

@ -1,6 +1,7 @@
SOURCE_URL=https://github.com/TryGhost/Admin/archive/3.41.8.zip
SOURCE_SUM=252080e8b4fdc558300b2d33701735a3e2a6d7d82ef66a5eeb9b651a488c67e0
SOURCE_URL=https://github.com/TryGhost/Admin/archive/v4.1.0.zip
SOURCE_SUM=21551a87bf8870b6cd915d8fc54caff3ad562bc981db5067d6293c9a75bcda96
SOURCE_SUM_PRG=sha256sum
SOURCE_FORMAT=zip
SOURCE_IN_SUBDIR=false
SOURCE_FILENAME=

View file

@ -1,5 +1,5 @@
SOURCE_URL=https://github.com/TryGhost/Ghost/releases/download/3.41.8/Ghost-3.41.8.zip
SOURCE_SUM=e650e3d55155c5974a8c3e58bf996c523be51b3a38f9728517b14d9114e0106a
SOURCE_URL=https://github.com/TryGhost/Ghost/releases/download/v4.1.0/Ghost-4.1.0.zip
SOURCE_SUM=63b620598ad2ce63061e7185cc220cac4b8eec2fc6e19a174f68a4ac97b7ce8d
SOURCE_SUM_PRG=sha256sum
SOURCE_FORMAT=zip
SOURCE_IN_SUBDIR=false

View file

@ -6,7 +6,7 @@
"en": "Just a blogging platform",
"fr": "Plateforme de blogging"
},
"version": "3.41.8~ynh1",
"version": "4.1.0~ynh1",
"url": "https://ghost.org/",
"license": "MIT",
"maintainer": {
@ -14,7 +14,7 @@
"email": "julien.malik@paraiso.me"
},
"requirements": {
"yunohost": ">= 3.8.1"
"yunohost": ">= 4.1.7"
},
"multi_instance": true,
"services": [
@ -26,29 +26,17 @@
{
"name": "domain",
"type": "domain",
"ask": {
"en": "Choose a domain for Ghost",
"fr": "Choisissez un domaine pour Ghost"
},
"example": "domain.org"
},
{
"name": "path",
"type": "path",
"ask": {
"en": "Choose a path for Ghost",
"fr": "Choisissez un chemin pour Ghost"
},
"example": "/blog",
"default": "/blog"
},
{
"name": "is_public",
"type": "boolean",
"ask": {
"en": "Is it a public application?",
"fr": "Est-ce une application publique ?"
},
"default": true
}
]

View file

@ -49,7 +49,6 @@ ynh_script_progression --message="Storing installation settings..." --weight=1
ynh_app_setting_set --app=$app --key=domain --value=$domain
ynh_app_setting_set --app=$app --key=path --value=$path_url
ynh_app_setting_set --app=$app --key=is_public --value=$is_public
#=================================================
# STANDARD MODIFICATIONS
@ -176,7 +175,7 @@ ynh_systemd_action --service_name=$app --action="start" --log_path="systemd" --l
#=================================================
# SETUP SSOWAT
#=================================================
ynh_script_progression --message="Configuring SSOwat..."
ynh_script_progression --message="Configuring permissions..."
if [ $is_public -eq 1 ]
then

View file

@ -121,7 +121,7 @@ yunohost service add $app --description="$app daemon for Ghost" --log="/var/log/
#=================================================
ynh_script_progression --message="Starting a systemd service..."
ynh_systemd_action --service_name=$app --action="start" --log_path="systemd" --line_match="Ghost boot"
ynh_systemd_action --service_name=$app --action=start --log_path=systemd --line_match="Ghost boot"
#=================================================
# GENERIC FINALIZATION

View file

@ -19,7 +19,6 @@ app=$YNH_APP_INSTANCE_NAME
domain=$(ynh_app_setting_get --app=$app --key=domain)
path_url=$(ynh_app_setting_get --app=$app --key=path)
is_public=$(ynh_app_setting_get --app=$app --key=is_public)
final_path=$(ynh_app_setting_get --app=$app --key=final_path)
port=$(ynh_app_setting_get --app=$app --key=port)
db_name=$(ynh_app_setting_get --app=$app --key=db_name)
@ -38,21 +37,19 @@ upgrade_type=$(ynh_check_app_version_changed)
#=================================================
ynh_script_progression --message="Ensuring downward compatibility..."
# Fix is_public as a boolean value
if [ "$is_public" = "Yes" ]; then
ynh_app_setting_set --app=$app --key=is_public --value=1
is_public=1
elif [ "$is_public" = "No" ]; then
ynh_app_setting_set --app=$app --key=is_public --value=0
is_public=0
fi
# If db_name doesn't exist, create it
if [ -z "$db_name" ]; then
db_name=$(ynh_sanitize_dbid --db_name=$app)
ynh_app_setting_set --app=$app --key=db_name --value=$db_name
fi
# Cleaning legacy permissions
if ynh_legacy_permissions_exists; then
ynh_legacy_permissions_delete_all
ynh_app_setting_delete --app=$app --key=is_public
fi
#=================================================
# BACKUP BEFORE UPGRADE THEN ACTIVE TRAP
#=================================================
@ -75,7 +72,7 @@ ynh_abort_if_errors
#=================================================
ynh_script_progression --message="Stopping a systemd service..."
ynh_systemd_action --service_name=$app --action="stop" --log_path="/var/log/$app/$app.log"
ynh_systemd_action --service_name=$app --action=stop --log_path="/var/log/$app/$app.log"
#=================================================
# DOWNLOAD, CHECK AND UNPACK SOURCE
@ -200,7 +197,7 @@ yunohost service add $app --description="$app daemon for Ghost" --log="/var/log/
#=================================================
ynh_script_progression --message="Starting a systemd service..."
ynh_systemd_action --service_name=$app --action="start" --log_path="systemd" --line_match="Ghost boot"
ynh_systemd_action --service_name=$app --action=start --log_path=systemd --line_match="Ghost boot"
#=================================================
# RELOAD NGINX