1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/h5ai_ynh.git synced 2024-09-03 20:36:25 +02:00

Merge pull request #11 from YunoHost-Apps/testing

Testing
This commit is contained in:
Alexandre Aubin 2021-11-29 15:31:42 +01:00 committed by GitHub
commit af190a49ec
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 24 additions and 31 deletions

View file

@ -15,9 +15,9 @@ If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/in
## Overview
Modern HTTP web server index for NGINX.
Modern HTTP web server index for NGINX
**Shipped version:** 0.30.0~ynh2
**Shipped version:** 0.30.0~ynh3

View file

@ -11,9 +11,9 @@ Si vous n'avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) pour
## Vue d'ensemble
Serveur moderne d'index pour NGINX.
Serveur moderne d'index pour NGINX
**Version incluse :** 0.30.0~ynh2
**Version incluse :** 0.30.0~ynh3

View file

@ -3,4 +3,4 @@ SOURCE_SUM=fe138305a61d72094beb8c507dab728020158e4b00dae695a60b9803babb3e30
SOURCE_SUM_PRG=sha256sum
SOURCE_FORMAT=zip
SOURCE_IN_SUBDIR=false
SOURCE_FILENAME=h5ai-0.30.0.zip
SOURCE_FILENAME=h5ai.zip

View file

@ -12,10 +12,6 @@ location __PATH__/ {
client_max_body_size 10G;
if ($scheme = http) {
rewrite ^ https://$server_name$request_uri? permanent;
}
location ~ [^/]\.php(/|$) {
fastcgi_split_path_info ^(.+?\.php)(/.*)$;
fastcgi_pass unix:/var/run/php/php__PHPVERSION__-fpm.sock;

View file

@ -3,10 +3,10 @@
"id": "h5ai",
"packaging_format": 1,
"description": {
"en": "Modern HTTP web server index for NGINX.",
"fr": "Serveur moderne d'index pour NGINX."
"en": "Modern HTTP web server index for NGINX",
"fr": "Serveur moderne d'index pour NGINX"
},
"version": "0.30.0~ynh2",
"version": "0.30.0~ynh3",
"url": "https://larsjung.de/h5ai/",
"upstream": {
"license": "MIT",
@ -20,7 +20,7 @@
"email": "alex.aubin@mailoo.org"
},
"requirements": {
"yunohost": ">= 4.2.0"
"yunohost": ">= 4.3.0"
},
"multi_instance": false,
"services": [
@ -31,8 +31,7 @@
"install" : [
{
"name": "domain",
"type": "domain",
"example": "domain.org"
"type": "domain"
},
{
"name": "path",

View file

@ -31,8 +31,6 @@ final_path=$(ynh_app_setting_get --app=$app --key=final_path)
#=================================================
ynh_script_progression --message="Validating restoration parameters..." --weight=1
ynh_webpath_available --domain=$domain --path_url=$path_url \
|| ynh_die --message="Path not available: ${domain}${path_url}"
test ! -d $final_path \
|| ynh_die --message="There is already a directory: $final_path "

View file

@ -32,6 +32,20 @@ domain=$(ynh_app_setting_get --app=$app --key=domain)
upgrade_type=$(ynh_check_app_version_changed)
#=================================================
# BACKUP BEFORE UPGRADE THEN ACTIVE TRAP
#=================================================
ynh_script_progression --message="Backing up the app before upgrading (may take a while)..." --weight=1
# Backup the current version of the app
ynh_backup_before_upgrade
ynh_clean_setup () {
# restore it if the upgrade fails
ynh_restore_upgradebackup
}
# Exit if an error occurs during the execution of the script
ynh_abort_if_errors
#=================================================
# ENSURE DOWNWARD COMPATIBILITY
#=================================================
@ -57,20 +71,6 @@ ynh_script_progression --message="Making sure dedicated system user exists..." -
# Create a dedicated user (if not existing)
ynh_system_user_create --username=$app --home_dir="$final_path"
#=================================================
# BACKUP BEFORE UPGRADE THEN ACTIVE TRAP
#=================================================
ynh_script_progression --message="Backing up the app before upgrading (may take a while)..." --weight=1
# Backup the current version of the app
ynh_backup_before_upgrade
ynh_clean_setup () {
# restore it if the upgrade fails
ynh_restore_upgradebackup
}
# Exit if an error occurs during the execution of the script
ynh_abort_if_errors
#=================================================
# DOWNLOAD, CHECK AND UNPACK SOURCE
#=================================================