From 7fbff6d76c4e9c6a11655a2a19e6291ac6dac4c4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 25 Mar 2021 23:42:14 +0100 Subject: [PATCH] Testing (#9) * Fix linter --- README.md | 2 +- check_process | 4 ---- manifest.json | 16 ++-------------- pull_request_template.md | 9 ++------- scripts/backup | 5 ++++- scripts/restore | 2 +- scripts/upgrade | 6 ------ 7 files changed, 10 insertions(+), 34 deletions(-) diff --git a/README.md b/README.md index 2206fb6..85566fa 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # phpLDAPadmin for YunoHost [![Integration level](https://dash.yunohost.org/integration/phpldapadmin.svg)](https://dash.yunohost.org/appci/app/phpldapadmin) ![](https://ci-apps.yunohost.org/ci/badges/phpldapadmin.status.svg) ![](https://ci-apps.yunohost.org/ci/badges/phpldapadmin.maintain.svg) -[![Install phpLDAPadmin with YunoHost](https://install-app.yunohost.org/install-with-yunohost.png)](https://install-app.yunohost.org/?app=phpldapadmin) +[![Install phpLDAPadmin with YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=phpldapadmin) > *This package allow you to install phpLDAPadmin quickly and simply on a YunoHost server. If you don't have YunoHost, please see [here](https://yunohost.org/#/install) to know how to install and enjoy it.* diff --git a/check_process b/check_process index f5d6ff9..09c1138 100644 --- a/check_process +++ b/check_process @@ -17,11 +17,7 @@ upgrade=1 from_commit=785706fb2607e95fbc4876e1367a715a6b8543d2 backup_restore=1 multi_instance=1 - incorrect_path=1 change_url=0 -;;; Levels - # If the level 5 (Package linter) is forced to 1. Please add justifications here. - Level 5=auto ;;; Options Email=aymhce@gmail.com Notification=none diff --git a/manifest.json b/manifest.json index 9fe2498..aac5b99 100644 --- a/manifest.json +++ b/manifest.json @@ -14,41 +14,29 @@ "email": "aymhce@gmail.com" }, "requirements": { - "yunohost": ">= 4.0.0" + "yunohost": ">= 4.1.7" }, "multi_instance": true, "services": [ "nginx", - "php7.0-fpm" + "php7.3-fpm" ], "arguments": { "install" : [ { "name": "domain", "type": "domain", - "ask": { - "en": "Choose a domain for phpLDAPadmin", - "fr": "Choisissez un domaine pour phpLDAPadmin" - }, "example": "domain.org" }, { "name": "path", "type": "path", - "ask": { - "en": "Choose a path for phpLDAPadmin", - "fr": "Choisissez un chemin pour phpLDAPadmin" - }, "example": "/phpldapadmin", "default": "/phpldapadmin" }, { "name": "admin", "type": "user", - "ask": { - "en": "Choose the only allowed admin user", - "fr": "Choisissez l'unique utilisateur autorisé" - }, "example": "johndoe" } ] diff --git a/pull_request_template.md b/pull_request_template.md index 89898f3..6c28fc5 100644 --- a/pull_request_template.md +++ b/pull_request_template.md @@ -11,11 +11,6 @@ - [ ] Upgrade from last version tested. - [ ] Can be reviewed and tested. -## Validation +## Package_check results --- -- [ ] **Code review** -- [ ] **Approval (LGTM)** - -- **CI succeeded** : - -When the PR is marked as ready to merge, you have to wait for 3 days before really merging it. +* An automatic package_check will be launch at https://ci-apps-dev.yunohost.org/, when you add a specific comment to your Pull Request: "!testme", "!gogogadgetoci" or "By the power of systemd, I invoke The Great App CI to test this Pull Request!"* diff --git a/scripts/backup b/scripts/backup index a93bf68..ea50559 100755 --- a/scripts/backup +++ b/scripts/backup @@ -27,7 +27,10 @@ domain=$(ynh_app_setting_get --app=$app --key=domain) phpversion=$(ynh_app_setting_get --app=$app --key=phpversion) #================================================= -# STANDARD BACKUP STEPS +# DECLARE DATA AND CONF FILES TO BACKUP +#================================================= +ynh_print_info --message="Declaring files to be backed up..." + #================================================= # BACKUP THE APP MAIN DIR #================================================= diff --git a/scripts/restore b/scripts/restore index a203bad..7b55515 100755 --- a/scripts/restore +++ b/scripts/restore @@ -82,7 +82,7 @@ ynh_restore_file --origin_path="/etc/php/$phpversion/fpm/pool.d/$app.conf" # GRANT ACCESS RIGHT TO ADMIN #================================================= -yunohost app addaccess $app -u $admin +ynh_permission_update --permission "main" --add $admin --remove "all_users" #================================================= # GENERIC FINALIZATION diff --git a/scripts/upgrade b/scripts/upgrade index b5955b5..78fe0b0 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -52,12 +52,6 @@ ynh_clean_setup () { # Exit if an error occurs during the execution of the script ynh_abort_if_errors -#================================================= -# CHECK THE PATH -#================================================= - -path_url=$(ynh_normalize_url_path --path_url=$path_url) - #================================================= # STANDARD UPGRADE STEPS #=================================================