1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/pluxml_ynh.git synced 2024-09-03 20:16:02 +02:00
* Upgrade to v.5.8.4
- Fix linter warnings
This commit is contained in:
Éric Gaspar 2020-12-14 23:22:49 +01:00 committed by GitHub
parent 217c012848
commit d3182d1f89
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
16 changed files with 59 additions and 90 deletions

View file

@ -9,13 +9,13 @@
If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/install) to learn how to install it.*
## Overview
[PluXml](https://www.pluxml.org/) : Blog or CMS storing data in XML.
PluXml is a content management system (CMS) developed in PHP. The data is stored in XML files. It is therefore not necessary to have the database management system. PluXml is customizable through themes and/or plugins.
**Shipped version:** 5.8.3
**Shipped version:** 5.8.4
## Screenshots
![Screenshot_Pluxml](sources/images/screenshot.jpg)
![Screenshot_Pluxml](sources/images/screenshot.png)
## Demo
@ -59,8 +59,7 @@ Can the app be used by multiple users? **Yes**
---
Developer info
----------------
## Developer info
Please send your pull request to the [testing branch](https://github.com/YunoHost-Apps/pluxml_ynh/tree/testing).

View file

@ -9,13 +9,13 @@
Si vous n'avez pas YunoHost, consultez [le guide](https://yunohost.org/#/install) pour apprendre comment l'installer.*
## Vue d'ensemble
[PluXml](https://www.pluxml.org/) : Blog ou CMS à l'Xml.
PluXml est un système de gestion de contenu développé en PHP. Les données sont stockées dans des fichiers XML. Il n'est donc pas nécessaire de disposer du système de gestion de base de données. PluXml est personnalisable par l'intermédiaire de thèmes et/ou de plugins.
**Version incluse:** 5.8.3
**Version incluse:** 5.8.4
## Captures d'écran
![Screenshot_Pluxml](sources/images/screenshot.jpg)
![Screenshot_Pluxml](sources/images/screenshot.png)
## Démo
@ -59,8 +59,7 @@ Le panneau d'administration est accessible via https://domain.tld/path/core/admi
---
Informations pour les développeurs
----------------
## Informations pour les développeurs
Merci de faire vos pull request sur la [branche testing](https://github.com/YunoHost-Apps/pluxml_ynh/tree/testing).

View file

@ -23,13 +23,8 @@
upgrade=1 from_commit=f618522e430dfcb63e1a5843535cf0da165025f3
backup_restore=1
multi_instance=1
# This test is no longer necessary since the version 2.7 (PR: https://github.com/YunoHost/yunohost/pull/304), you can still do it if your app could be installed with this version.
# incorrect_path=1
port_already_use=0
change_url=1
;;; Levels
# If the level 5 (Package linter) is forced to 1. Please add justifications here.
Level 5=auto
;;; Options
Email=
Notification=none

View file

@ -1,5 +1,5 @@
SOURCE_URL=https://github.com/pluxml/PluXml/archive/v5.8.3.zip
SOURCE_SUM=ed14b037b69144e4f300788fd46520552cb95d3aea450df57da7994b2461d62d
SOURCE_URL=https://github.com/pluxml/PluXml/archive/v5.8.4.zip
SOURCE_SUM=0c2fe54dfe62aee3d4778898fd1935d7a8410385aaea064fc5850db2f12be725
SOURCE_SUM_PRG=sha256sum
SOURCE_FORMAT=zip
SOURCE_IN_SUBDIR=true

View file

@ -49,19 +49,19 @@ location __PATH__/ {
# Cache-control
location ~ ^__PATH__/data/ {
more_set_headers Cache-Control public;
more_set_headers 'Cache-Control: public';
expires 12h;
}
location ~ ^__PATH__/core/ {
more_set_headers Cache-Control public;
more_set_headers 'Cache-Control: public';
expires 12h;
}
location ~ ^__PATH__/plugins/ {
more_set_headers Cache-Control public;
more_set_headers 'Cache-Control: public';
expires 12h;
}
location ~ ^__PATH__/themes/ {
more_set_headers Cache-Control public;
more_set_headers 'Cache-Control: public';
expires 12h;
}

View file

@ -7,7 +7,7 @@ about: Create a report to help us debug, it would be nice to fill the template a
**How to post a meaningful bug report**
1. *Read this whole template first.*
2. *Determine if you are on the right place:*
- *If you were performing an action on the app from the webadmin or the CLI (install, update, backup, restore, change url...), you are on the right place!*
- *If you were performing an action on the app from the webadmin or the CLI (install, update, backup, restore, change_url...), you are on the right place!*
- *Otherwise, the issue may be due to pluxml itself. Refer to its documentation or repository for help.*
- *If you have a doubt, post here, we will figure it out together.*
3. *Delete the italic comments as you write over them below, and remove this guide.*
@ -34,8 +34,8 @@ about: Create a report to help us debug, it would be nice to fill the template a
- *If you used the webadmin, please perform the equivalent command from the CLI first.*
- *If the error occurs in your browser, explain what you did:*
1. *Go to '...'*
2. *Click on '....'*
3. *Scroll down to '....'*
2. *Click on '...'*
3. *Scroll down to '...'*
4. *See error*
**Expected behavior**

View file

@ -6,7 +6,7 @@
"en": "Blog or CMS storing data in XML format.",
"fr": "Blog ou CMS stockant des données au format XML."
},
"version": "5.8.3~ynh1",
"version": "5.8.4~ynh1",
"url": "https://www.pluxml.org/",
"license": "GPL-2.0-only",
"maintainer": {
@ -15,7 +15,7 @@
"url": "https://miaou.org"
},
"requirements": {
"yunohost": ">= 3.5"
"yunohost": ">= 4.0.0"
},
"multi_instance": true,
"services": [

View file

@ -4,8 +4,10 @@
# COMMON VARIABLES
#=================================================
YNH_PHP_VERSION=7.3
# dependencies used by the app
pkg_dependencies=""
#extra_php_dependencies=="php${YNH_PHP_VERSION}-gd"
#=================================================
# PERSONAL HELPERS

View file

@ -32,7 +32,7 @@ final_path=$(ynh_app_setting_get --app=$app --key=final_path)
#=================================================
# BACKUP BEFORE UPGRADE THEN ACTIVE TRAP
#=================================================
ynh_script_progression --message="Backing up the app before changing its url (may take a while)..."
ynh_script_progression --message="Backing up the app before changing its URL (may take a while)..."
# Backup the current version of the app
ynh_backup_before_upgrade
@ -70,19 +70,19 @@ fi
nginx_conf_path=/etc/nginx/conf.d/$old_domain.d/$app.conf
# Change the path in the nginx config file
# Change the path in the NGINX config file
if [ $change_path -eq 1 ]
then
# Make a backup of the original nginx config file if modified
# Make a backup of the original NGINX config file if modified
ynh_backup_if_checksum_is_different --file="$nginx_conf_path"
# Set global variables for nginx helper
# Set global variables for NGINX helper
domain="$old_domain"
path_url="$new_path"
# Create a dedicated nginx config
# Create a dedicated NGINX config
ynh_add_nginx_config
fi
# Change the domain for nginx
# Change the domain for NGINX
if [ $change_domain -eq 1 ]
then
# Delete file checksum for the old conf file location
@ -97,7 +97,7 @@ fi
#=================================================
# RELOAD NGINX
#=================================================
ynh_script_progression --message="Reloading nginx web server..."
ynh_script_progression --message="Reloading NGINX web server..."
ynh_systemd_action --service_name=nginx --action=reload

View file

@ -68,9 +68,9 @@ ynh_setup_source --dest_dir="$final_path"
#=================================================
# NGINX CONFIGURATION
#=================================================
ynh_script_progression --message="Configuring nginx web server..."
ynh_script_progression --message="Configuring NGINX web server..."
# Create a dedicated nginx config
# Create a dedicated NGINX config
ynh_add_nginx_config
#=================================================
@ -84,40 +84,32 @@ ynh_system_user_create --username=$app
#=================================================
# PHP-FPM CONFIGURATION
#=================================================
ynh_script_progression --message="Configuring php-fpm..."
ynh_script_progression --message="Configuring PHP-FPM..."
# Create a dedicated php-fpm config
ynh_add_fpm_config
# Create a dedicated PHP-FPM config
ynh_add_fpm_config #--package="$extra_php_dependencies"
phpversion=$(ynh_app_setting_get --app=$app --key=phpversion)
#=================================================
# SPECIFIC SETUP
#=================================================
# SETUP APPLICATION WITH CURL
#=================================================
ynh_script_progression --message="Setting up application with CURL..."
ynh_script_progression --message="Setting up application with cURL..."
# Set right permissions for curl install
chown -R $app: $final_path
# Set the app as temporarily public for curl call
ynh_script_progression --message="Configuring ssowat ..."
ynh_app_setting_set --app=$app --key=skipped_uris --value="/"
# Reload SSOwat config
yunohost app ssowatconf
# Set the app as temporarily public for cURL call
ynh_permission_update --permission "main" --add "visitors"
# Reload Nginx
# Reload NGINX
ynh_systemd_action --service_name=nginx --action=reload
# Installation with curl
ynh_script_progression --message="Finalizing installation..."
ynh_local_curl "/install.php" "default_lang=$language" "install=Installer" "name=$admin" "login=$admin" "pwd=$password" "pwd2=$password" "data=1" "email=$admin@$domain" "timezone=Europe/Paris"
# Remove the public access
if [ $is_public -eq 0 ]
then
ynh_app_setting_delete --app=$app --key=skipped_uris
fi
#=================================================
# REMOVING NO MORE NEEDED FILES
#=================================================
@ -141,17 +133,16 @@ chown -R "$app":"$app" $final_path # modif perso
#=================================================
ynh_script_progression --message="Configuring SSOwat..."
# Make app public if necessary
if [ $is_public -eq 1 ]
# Make app public if necessary or protect it
if [ $is_public -eq 0 ]
then
# unprotected_uris allows SSO credentials to be passed anyway.
ynh_app_setting_set --app=$app --key=unprotected_uris --value="/"
ynh_permission_update --permission "main" --remove "visitors"
fi
#=================================================
# RELOAD NGINX
#=================================================
ynh_script_progression --message="Reloading nginx web server..."
ynh_script_progression --message="Reloading NGINX web server..."
ynh_systemd_action --service_name=nginx --action=reload

View file

@ -32,17 +32,17 @@ ynh_secure_remove --file="$final_path"
#=================================================
# REMOVE NGINX CONFIGURATION
#=================================================
ynh_script_progression --message="Removing nginx web server configuration..."
ynh_script_progression --message="Removing NGINX web server configuration..."
# Remove the dedicated nginx config
# Remove the dedicated NGINX config
ynh_remove_nginx_config
#=================================================
# REMOVE PHP-FPM CONFIGURATION
#=================================================
ynh_script_progression --message="Removing php-fpm configuration..."
ynh_script_progression --message="Removing PHP-FPM configuration..."
# Remove the dedicated php-fpm config
# Remove the dedicated PHP-FPM config
ynh_remove_fpm_config
#=================================================

View file

@ -47,7 +47,7 @@ test ! -d $final_path \
#=================================================
# RESTORE THE NGINX CONFIGURATION
#=================================================
ynh_script_progression --message="Restoring the nginx configuration..."
ynh_script_progression --message="Restoring the NGINX configuration..."
ynh_restore_file --origin_path="/etc/nginx/conf.d/$domain.d/$app.conf"
@ -72,7 +72,7 @@ ynh_system_user_create --username=$app
ynh_script_progression --message="Restoring user rights..."
# Restore permissions on app files
chown -R "$app":"$app" $final_path
chown -R $app:$app $final_path
#=================================================
# RESTORE THE PHP-FPM CONFIGURATION
@ -81,12 +81,14 @@ ynh_script_progression --message="Restoring PHP-FPM configuration..."
ynh_restore_file --origin_path="/etc/php/$phpversion/fpm/pool.d/$app.conf"
ynh_add_fpm_config #--package="$extra_php_dependencies"
#=================================================
# GENERIC FINALIZATION
#=================================================
# RELOAD NGINX AND PHP-FPM
#=================================================
ynh_script_progression --message="Reloading nginx web server and php-fpm..."
ynh_script_progression --message="Reloading NGINX web server and PHP-FPM..."
ynh_systemd_action --service_name=php$phpversion-fpm --action=reload
ynh_systemd_action --service_name=nginx --action=reload

View file

@ -64,13 +64,6 @@ ynh_clean_setup () {
# Exit if an error occurs during the execution of the script
ynh_abort_if_errors
#=================================================
# CHECK THE PATH
#=================================================
# Normalize the URL path syntax
path_url=$(ynh_normalize_url_path --path_url=$path_url)
#=================================================
# STANDARD UPGRADE STEPS
#=================================================
@ -88,7 +81,7 @@ fi
#=================================================
# NGINX CONFIGURATION
#=================================================
ynh_script_progression --message="Upgrading nginx web server configuration..."
ynh_script_progression --message="Upgrading NGINX web server configuration..."
# Create a dedicated nginx config
ynh_add_nginx_config
@ -104,17 +97,17 @@ ynh_system_user_create --username=$app
#=================================================
# PHP-FPM CONFIGURATION
#=================================================
ynh_script_progression --message="Upgrading php-fpm configuration..."
ynh_script_progression --message="Upgrading PHP-FPM configuration..."
# Create a dedicated php-fpm config
ynh_add_fpm_config
# Create a dedicated PHP-FPM config
ynh_add_fpm_config #--package="$extra_php_dependencies"
#=================================================
# SPECIFIC UPGRADE
#=================================================
# SETUP APPLICATION WITH CURL
#=================================================
ynh_script_progression --message="Setting up application with CURL..."
ynh_script_progression --message="Setting up application with cURL..."
chown -R "$app":"$app" $final_path
ynh_local_curl "/update/index.php" "submit=submit"
@ -135,24 +128,12 @@ ynh_secure_remove --file="${final_path}/update"
ynh_script_progression --message="Securing files and directories..."
# Set permissions on app files
chown -R "$app":"$app" $final_path # modif perso
#=================================================
# SETUP SSOWAT
#=================================================
ynh_script_progression --message="Upgrading SSOwat configuration..."
# Make app public if necessary
if [ $is_public -eq 1 ]
then
# unprotected_uris allows SSO credentials to be passed anyway
ynh_app_setting_set --app=$app --key=unprotected_uris --value="/"
fi
chown -R $app:$app $final_path # modif perso
#=================================================
# RELOAD NGINX
#=================================================
ynh_script_progression --message="Reloading nginx web server..."
ynh_script_progression --message="Reloading NGINX web server..."
ynh_systemd_action --service_name=nginx --action=reload

Binary file not shown.

Before

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 45 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 763 KiB