mirror of
https://github.com/YunoHost-Apps/droppy_ynh.git
synced 2024-09-03 18:26:27 +02:00
parent
257c616e1f
commit
22dea51c51
6 changed files with 21 additions and 27 deletions
|
@ -26,7 +26,6 @@ Shared files are stored in the following directory: `/home/yunohost.app/droppy/f
|
||||||
## Documentation
|
## Documentation
|
||||||
|
|
||||||
* Official documentation: https://github.com/silverwind/droppy
|
* Official documentation: https://github.com/silverwind/droppy
|
||||||
* YunoHost documentation:
|
|
||||||
|
|
||||||
## YunoHost specific features
|
## YunoHost specific features
|
||||||
|
|
||||||
|
|
|
@ -26,7 +26,6 @@ Les fichiers partagés sont stockés dans le répertoire suivant : `/home/yunoho
|
||||||
## Documentation
|
## Documentation
|
||||||
|
|
||||||
* Documentation officielle : https://github.com/silverwind/droppy
|
* Documentation officielle : https://github.com/silverwind/droppy
|
||||||
* Documentation YunoHost :
|
|
||||||
|
|
||||||
## Caractéristiques spécifiques YunoHost
|
## Caractéristiques spécifiques YunoHost
|
||||||
|
|
||||||
|
|
|
@ -6,14 +6,14 @@
|
||||||
"en": "Self-hosted file storage server",
|
"en": "Self-hosted file storage server",
|
||||||
"fr": "Serveur de stockage de fichiers auto-hébergé"
|
"fr": "Serveur de stockage de fichiers auto-hébergé"
|
||||||
},
|
},
|
||||||
"version": "12.2.0~ynh4",
|
"version": "12.2.0~ynh5",
|
||||||
"url": "https://github.com/silverwind/droppy",
|
"url": "https://github.com/silverwind/droppy",
|
||||||
"license": "BSD-2-Clause",
|
"license": "BSD-2-Clause",
|
||||||
"maintainer": {
|
"maintainer": {
|
||||||
"name": "eric_G"
|
"name": "eric_G"
|
||||||
},
|
},
|
||||||
"requirements": {
|
"requirements": {
|
||||||
"yunohost": ">= 3.8.1"
|
"yunohost": ">= 4.1.7"
|
||||||
},
|
},
|
||||||
"multi_instance": false,
|
"multi_instance": false,
|
||||||
"services": [
|
"services": [
|
||||||
|
@ -24,29 +24,17 @@
|
||||||
{
|
{
|
||||||
"name": "domain",
|
"name": "domain",
|
||||||
"type": "domain",
|
"type": "domain",
|
||||||
"ask": {
|
|
||||||
"en": "Choose a domain name for Droppy",
|
|
||||||
"fr": "Choisissez un nom de domaine pour Droppy"
|
|
||||||
},
|
|
||||||
"example": "domain.org"
|
"example": "domain.org"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "path",
|
"name": "path",
|
||||||
"type": "path",
|
"type": "path",
|
||||||
"ask": {
|
|
||||||
"en": "Choose a path for Droppy",
|
|
||||||
"fr": "Choisissez un chemin pour Droppy"
|
|
||||||
},
|
|
||||||
"example": "/droppy",
|
"example": "/droppy",
|
||||||
"default": "/droppy"
|
"default": "/droppy"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "is_public",
|
"name": "is_public",
|
||||||
"type": "boolean",
|
"type": "boolean",
|
||||||
"ask": {
|
|
||||||
"en": "Is it a public site?",
|
|
||||||
"fr": "Est-ce un site public ?"
|
|
||||||
},
|
|
||||||
"help": {
|
"help": {
|
||||||
"en": "If enabled, Droppy will be accessible by people who do not have an account. This can be changed later via the webadmin.",
|
"en": "If enabled, Droppy will be accessible by people who do not have an account. This can be changed later via the webadmin.",
|
||||||
"fr": "Si cette case est cochée, Droppy sera accessible aux personnes n’ayant pas de compte. Vous pourrez changer ceci plus tard via la webadmin."
|
"fr": "Si cette case est cochée, Droppy sera accessible aux personnes n’ayant pas de compte. Vous pourrez changer ceci plus tard via la webadmin."
|
||||||
|
|
|
@ -13,6 +13,4 @@
|
||||||
|
|
||||||
## Package_check results
|
## Package_check results
|
||||||
---
|
---
|
||||||
*If you have access to [App Continuous Integration for packagers](https://yunohost.org/#/packaging_apps_ci) you can provide a link to the package_check results like below, replacing '-NUM-' in this link by the PR number and USERNAME by your username on the ci-apps-dev. Or you provide a screenshot or a pastebin of the results*
|
* 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!"*
|
||||||
|
|
||||||
[/badge/icon)](https://ci-apps-dev.yunohost.org/jenkins/job/droppy_ynh%20PR-NUM-%20(USERNAME)/)
|
|
||||||
|
|
|
@ -47,7 +47,6 @@ ynh_script_progression --message="Storing installation settings..." --weight=2
|
||||||
|
|
||||||
ynh_app_setting_set --app=$app --key=domain --value=$domain
|
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=path --value=$path_url
|
||||||
ynh_app_setting_set --app=$app --key=is_public --value=$is_public
|
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# STANDARD MODIFICATIONS
|
# STANDARD MODIFICATIONS
|
||||||
|
@ -173,12 +172,12 @@ ynh_systemd_action --service_name=$app --action="start" --log_path="systemd" --l
|
||||||
#=================================================
|
#=================================================
|
||||||
# SETUP SSOWAT
|
# SETUP SSOWAT
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Configuring SSOwat..." --weight=1
|
ynh_script_progression --message="Configuring permissions..." --weight=1
|
||||||
|
|
||||||
# Make app public if necessary or protect it
|
# Make app public if necessary or protect it
|
||||||
if [ $is_public -eq 1 ]
|
if [ $is_public -eq 1 ]
|
||||||
then
|
then
|
||||||
ynh_permission_update --permission "main" --add "visitors"
|
ynh_permission_update --permission="main" --add="visitors"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
|
@ -18,7 +18,6 @@ app=$YNH_APP_INSTANCE_NAME
|
||||||
|
|
||||||
domain=$(ynh_app_setting_get --app=$app --key=domain)
|
domain=$(ynh_app_setting_get --app=$app --key=domain)
|
||||||
path_url=$(ynh_app_setting_get --app=$app --key=path)
|
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)
|
final_path=$(ynh_app_setting_get --app=$app --key=final_path)
|
||||||
port=$(ynh_app_setting_get --app=$app --key=port)
|
port=$(ynh_app_setting_get --app=$app --key=port)
|
||||||
|
|
||||||
|
@ -29,10 +28,22 @@ ynh_script_progression --message="Checking version..." --weight=1
|
||||||
|
|
||||||
upgrade_type=$(ynh_check_app_version_changed)
|
upgrade_type=$(ynh_check_app_version_changed)
|
||||||
|
|
||||||
|
#=================================================
|
||||||
|
# ENSURE DOWNWARD COMPATIBILITY
|
||||||
|
#=================================================
|
||||||
|
ynh_script_progression --message="Ensuring downward compatibility..." --weight=1
|
||||||
|
|
||||||
|
# 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
|
# BACKUP BEFORE UPGRADE THEN ACTIVE TRAP
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Backing up $app before upgrading (may take a while)..." --weight=40
|
ynh_script_progression --message="Backing up $app before upgrading (may take a while)..." --weight=2
|
||||||
|
|
||||||
# Backup the current version of the app
|
# Backup the current version of the app
|
||||||
ynh_backup_before_upgrade
|
ynh_backup_before_upgrade
|
||||||
|
@ -48,9 +59,9 @@ ynh_abort_if_errors
|
||||||
#=================================================
|
#=================================================
|
||||||
# STOP SYSTEMD SERVICE
|
# STOP SYSTEMD SERVICE
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Stopping a systemd service..." --weight=1
|
ynh_script_progression --message="Stopping a systemd service..." --weight=9
|
||||||
|
|
||||||
ynh_systemd_action --service_name=$app --action="stop" --log_path="systemd"
|
ynh_systemd_action --service_name=$app --action=stop --log_path=systemd
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# DOWNLOAD, CHECK AND UNPACK SOURCE
|
# DOWNLOAD, CHECK AND UNPACK SOURCE
|
||||||
|
@ -172,7 +183,7 @@ yunohost service add $app --description="Self-hosted file storage server" --log=
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Starting a systemd service..." --weight=40
|
ynh_script_progression --message="Starting a systemd service..." --weight=40
|
||||||
|
|
||||||
ynh_systemd_action --service_name=$app --action="start" --log_path="systemd" --line_match="Ready for requests!"
|
ynh_systemd_action --service_name=$app --action=start --log_path=systemd --line_match="Ready for requests!"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# RELOAD NGINX
|
# RELOAD NGINX
|
||||||
|
|
Loading…
Add table
Reference in a new issue