mirror of
https://github.com/YunoHost/test_apps.git
synced 2024-09-03 20:06:29 +02:00
Update config_app to packaging v2
This commit is contained in:
parent
dc78c4cfc2
commit
17ad0515ca
5 changed files with 61 additions and 74 deletions
|
@ -1,22 +0,0 @@
|
||||||
{
|
|
||||||
"packaging_format": 1,
|
|
||||||
"name": "Config panel",
|
|
||||||
"id": "config_app",
|
|
||||||
"description": {
|
|
||||||
"en": "Dummy app to test config panel"
|
|
||||||
},
|
|
||||||
"license": "GPL-3+",
|
|
||||||
"maintainer": {
|
|
||||||
"name": "ljf",
|
|
||||||
"email": "ljf+config_app@reflexlibre.net",
|
|
||||||
"url": "http://reflexlibre.net"
|
|
||||||
},
|
|
||||||
"requirements": {
|
|
||||||
"yunohost": ">= 4.2"
|
|
||||||
},
|
|
||||||
"multi_instance": false,
|
|
||||||
"arguments": {
|
|
||||||
"install" : [
|
|
||||||
]
|
|
||||||
}
|
|
||||||
}
|
|
33
config_app_ynh/manifest.toml
Normal file
33
config_app_ynh/manifest.toml
Normal file
|
@ -0,0 +1,33 @@
|
||||||
|
#:schema https://raw.githubusercontent.com/YunoHost/apps/master/schemas/manifest.v2.schema.json
|
||||||
|
|
||||||
|
packaging_format = 2
|
||||||
|
|
||||||
|
id = "config_app"
|
||||||
|
name = "Config panel"
|
||||||
|
description.en = "Dummy app to test config panel"
|
||||||
|
|
||||||
|
version = "1.0~ynh1"
|
||||||
|
|
||||||
|
maintainers = ["ljf"]
|
||||||
|
|
||||||
|
[upstream]
|
||||||
|
license = "GPL-3+"
|
||||||
|
|
||||||
|
[integration]
|
||||||
|
yunohost = ">= 4.2"
|
||||||
|
architectures = "all"
|
||||||
|
multi_instance = false
|
||||||
|
ldap = "not_relevant"
|
||||||
|
sso = "not_relevant"
|
||||||
|
disk = "50M"
|
||||||
|
ram.build = "50M"
|
||||||
|
ram.runtime = "50M"
|
||||||
|
|
||||||
|
[install]
|
||||||
|
|
||||||
|
[resources]
|
||||||
|
[resources.system_user]
|
||||||
|
|
||||||
|
[resources.install_dir]
|
||||||
|
|
||||||
|
[resources.permissions]
|
|
@ -1,19 +1,7 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# GENERIC STARTING
|
|
||||||
#=================================================
|
|
||||||
# IMPORT GENERIC HELPERS
|
|
||||||
#=================================================
|
|
||||||
|
|
||||||
source /usr/share/yunohost/helpers
|
source /usr/share/yunohost/helpers
|
||||||
|
|
||||||
ynh_abort_if_errors
|
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# RETRIEVE ARGUMENTS
|
|
||||||
#=================================================
|
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# SPECIFIC GETTERS FOR TOML SHORT KEY
|
# SPECIFIC GETTERS FOR TOML SHORT KEY
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
|
@ -1,40 +1,32 @@
|
||||||
set -eux
|
set -eux
|
||||||
|
|
||||||
# Source app helpers
|
|
||||||
source /usr/share/yunohost/helpers
|
source /usr/share/yunohost/helpers
|
||||||
|
|
||||||
app=$YNH_APP_INSTANCE_NAME
|
|
||||||
final_path=/var/www/$app
|
|
||||||
ynh_app_setting_set --app=$app --key=final_path --value=$final_path
|
|
||||||
mkdir -p $final_path
|
|
||||||
|
|
||||||
cp ../conf/* /var/www/$app/
|
cp ../conf/* /var/www/$app/
|
||||||
# Initialize default values
|
|
||||||
ynh_app_setting_set --app=$app --key=boolean --value=0
|
|
||||||
ynh_app_setting_set --app=$app --key=number --value=20
|
|
||||||
ynh_app_setting_set --app=$app --key=range --value=50
|
|
||||||
ynh_app_setting_set --app=$app --key=str --value=""
|
|
||||||
ynh_app_setting_set --app=$app --key=text --value=""
|
|
||||||
ynh_app_setting_set --app=$app --key=password --value=""
|
|
||||||
ynh_app_setting_set --app=$app --key=path --value=""
|
|
||||||
ynh_app_setting_set --app=$app --key=email --value=""
|
|
||||||
ynh_app_setting_set --app=$app --key=url --value=""
|
|
||||||
ynh_app_setting_set --app=$app --key=date --value=""
|
|
||||||
ynh_app_setting_set --app=$app --key=time --value=""
|
|
||||||
ynh_app_setting_set --app=$app --key=color --value=""
|
|
||||||
ynh_app_setting_set --app=$app --key=select --value="option_one"
|
|
||||||
ynh_app_setting_set --app=$app --key=domain --value=""
|
|
||||||
ynh_app_setting_set --app=$app --key=app_ --value=""
|
|
||||||
ynh_app_setting_set --app=$app --key=user --value=""
|
|
||||||
ynh_app_setting_set --app=$app --key=group --value=""
|
|
||||||
ynh_app_setting_set --app=$app --key=tags --value=""
|
|
||||||
ynh_app_setting_set --app=$app --key=tags2 --value=""
|
|
||||||
ynh_app_setting_set --app=$app --key=pattern --value=""
|
|
||||||
ynh_app_setting_set --app=$app --key=example --value=""
|
|
||||||
ynh_app_setting_set --app=$app --key=required --value=""
|
|
||||||
ynh_app_setting_set --app=$app --key=helptext --value=""
|
|
||||||
ynh_app_setting_set --app=$app --key=triggervisible --value="nothing"
|
|
||||||
ynh_app_setting_set --app=$app --key=visible_question --value=""
|
|
||||||
ynh_app_setting_set --app=$app --key=sub --value=""
|
|
||||||
ynh_app_setting_set --app=$app --key=arg1 --value=""
|
|
||||||
|
|
||||||
|
ynh_app_setting_set --key=boolean --value=0
|
||||||
|
ynh_app_setting_set --key=number --value=20
|
||||||
|
ynh_app_setting_set --key=range --value=50
|
||||||
|
ynh_app_setting_set --key=str --value=""
|
||||||
|
ynh_app_setting_set --key=text --value=""
|
||||||
|
ynh_app_setting_set --key=password --value=""
|
||||||
|
ynh_app_setting_set --key=path --value=""
|
||||||
|
ynh_app_setting_set --key=email --value=""
|
||||||
|
ynh_app_setting_set --key=url --value=""
|
||||||
|
ynh_app_setting_set --key=date --value=""
|
||||||
|
ynh_app_setting_set --key=time --value=""
|
||||||
|
ynh_app_setting_set --key=color --value=""
|
||||||
|
ynh_app_setting_set --key=select --value="option_one"
|
||||||
|
ynh_app_setting_set --key=domain --value=""
|
||||||
|
ynh_app_setting_set --key=app_ --value=""
|
||||||
|
ynh_app_setting_set --key=user --value=""
|
||||||
|
ynh_app_setting_set --key=group --value=""
|
||||||
|
ynh_app_setting_set --key=tags --value=""
|
||||||
|
ynh_app_setting_set --key=tags2 --value=""
|
||||||
|
ynh_app_setting_set --key=pattern --value=""
|
||||||
|
ynh_app_setting_set --key=example --value=""
|
||||||
|
ynh_app_setting_set --key=required --value=""
|
||||||
|
ynh_app_setting_set --key=helptext --value=""
|
||||||
|
ynh_app_setting_set --key=triggervisible --value="nothing"
|
||||||
|
ynh_app_setting_set --key=visible_question --value=""
|
||||||
|
ynh_app_setting_set --key=sub --value=""
|
||||||
|
ynh_app_setting_set --key=arg1 --value=""
|
||||||
|
|
|
@ -1,7 +1,3 @@
|
||||||
set -eux
|
set -eux
|
||||||
|
|
||||||
# See comments in install script
|
# Nothing to do
|
||||||
app=$YNH_APP_INSTANCE_NAME
|
|
||||||
|
|
||||||
rm -rf /var/www/$app
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue