mirror of
https://github.com/YunoHost-Apps/uptime-kuma_ynh.git
synced 2024-10-01 13:34:58 +02:00
cleanup + simplify manifest (we can't postinstall because of websocket)
This commit is contained in:
parent
cb3b3de289
commit
8c70744924
7 changed files with 29 additions and 52 deletions
|
@ -39,13 +39,13 @@ It is a self-hosted monitoring tool like "Uptime Robot".
|
|||
|
||||
## Disclaimers / important information
|
||||
|
||||
- Not working yet
|
||||
- Requires a full dedicated domain
|
||||
- Uses N to install specific nodejs version
|
||||
- ARM architecture not supported
|
||||
- This app needs a manual post-install
|
||||
- No upgrade script in this package
|
||||
- does not properly use port reserved by yunohost
|
||||
- needs post-install
|
||||
- No restore script in this package
|
||||
- Backup script is untested in this package
|
||||
- Uses N to install specific nodejs version
|
||||
<!-- * Any known limitations, constrains or stuff not working, such as (but not limited to):
|
||||
* requiring a full dedicated domain ?
|
||||
* architectures not supported ?
|
||||
|
|
|
@ -35,13 +35,13 @@ It is a self-hosted monitoring tool like "Uptime Robot".
|
|||
|
||||
## Avertissements / informations importantes
|
||||
|
||||
- Not working yet
|
||||
- Requires a full dedicated domain
|
||||
- Uses N to install specific nodejs version
|
||||
- ARM architecture not supported
|
||||
- This app needs a manual post-install
|
||||
- No upgrade script in this package
|
||||
- does not properly use port reserved by yunohost
|
||||
- needs post-install
|
||||
- No restore script in this package
|
||||
- Backup script is untested in this package
|
||||
- Uses N to install specific nodejs version
|
||||
<!-- * Any known limitations, constrains or stuff not working, such as (but not limited to):
|
||||
* requiring a full dedicated domain ?
|
||||
* architectures not supported ?
|
||||
|
|
|
@ -1,8 +1,9 @@
|
|||
- Not working yet
|
||||
- Requires a full dedicated domain
|
||||
- ARM architecture not supported
|
||||
- This app needs a manual post-install
|
||||
- No upgrade script in this package
|
||||
- needs post-install
|
||||
- No restore script in this package
|
||||
- Backup script is untested in this package
|
||||
- Uses N to install specific nodejs version
|
||||
<!-- * Any known limitations, constrains or stuff not working, such as (but not limited to):
|
||||
* requiring a full dedicated domain ?
|
||||
|
|
|
@ -38,31 +38,10 @@
|
|||
"fr": "Cette app a besoin de tout un sous-domaine à elle toute seule."
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "admin",
|
||||
"type": "user"
|
||||
},
|
||||
{
|
||||
"name": "is_public",
|
||||
"type": "boolean",
|
||||
"default": true
|
||||
},
|
||||
{
|
||||
"name": "password",
|
||||
"type": "password"
|
||||
},
|
||||
{
|
||||
"name": "language",
|
||||
"type": "string",
|
||||
"ask": {
|
||||
"en": "Choose the application language",
|
||||
"fr": "Choisissez la langue de l'application"
|
||||
},
|
||||
"choices": [
|
||||
"fr",
|
||||
"en"
|
||||
],
|
||||
"default": "fr"
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
|
||||
# dependencies used by the app
|
||||
# pkg_dependencies="npm git nodejs"
|
||||
pkg_dependencies=""
|
||||
# pkg_dependencies=""
|
||||
|
||||
nodejs_version=14.18.1
|
||||
|
||||
|
|
|
@ -26,10 +26,10 @@ ynh_abort_if_errors
|
|||
|
||||
path_url=/
|
||||
domain=$YNH_APP_ARG_DOMAIN
|
||||
admin=$YNH_APP_ARG_ADMIN
|
||||
# admin=$YNH_APP_ARG_ADMIN
|
||||
is_public=$YNH_APP_ARG_IS_PUBLIC
|
||||
language=$YNH_APP_ARG_LANGUAGE
|
||||
password=$YNH_APP_ARG_PASSWORD
|
||||
# language=$YNH_APP_ARG_LANGUAGE
|
||||
# password=$YNH_APP_ARG_PASSWORD
|
||||
|
||||
### If it's a multi-instance app, meaning it can be installed several times independently
|
||||
### The id of the app as stated in the manifest is available as $YNH_APP_ID
|
||||
|
@ -72,9 +72,9 @@ ynh_script_progression --message="Storing installation settings..." --time --wei
|
|||
# Subpath not supported
|
||||
ynh_app_setting_set --app=$app --key=path --value=/
|
||||
ynh_app_setting_set --app=$app --key=domain --value=$domain
|
||||
ynh_app_setting_set --app=$app --key=admin --value=$admin
|
||||
ynh_app_setting_set --app=$app --key=password --value=$password
|
||||
ynh_app_setting_set --app=$app --key=language --value=$language
|
||||
# ynh_app_setting_set --app=$app --key=admin --value=$admin
|
||||
# ynh_app_setting_set --app=$app --key=password --value=$password
|
||||
# ynh_app_setting_set --app=$app --key=language --value=$language
|
||||
|
||||
#=================================================
|
||||
# STANDARD MODIFICATIONS
|
||||
|
@ -212,7 +212,7 @@ ynh_add_nginx_config
|
|||
#=================================================
|
||||
ynh_script_progression --message="Installing Uptime Kuma npm dependencies..." --time --weight=5
|
||||
# ynh_exec_warn_less ynh_exec_as $app $ynh_npm install
|
||||
cd $final_path && $ynh_npm install
|
||||
ynh_exec_warn_less cd $final_path && $ynh_npm install
|
||||
# cd $final_path && /usr/local/n/versions/node/14.18.1/bin/npm install
|
||||
ynh_script_progression --message="Downloading Uptime Kuma frontend..." --time --weight=1
|
||||
ynh_exec_warn_less wget https://github.com/louislam/uptime-kuma/releases/download/1.10.0/dist.tar.gz
|
||||
|
@ -301,22 +301,19 @@ ynh_add_systemd_config
|
|||
# SETUP APPLICATION WITH CURL
|
||||
#=================================================
|
||||
|
||||
### Use these lines only if the app installation needs to be finalized through
|
||||
### web forms. We generally don't want to ask the final user,
|
||||
### so we're going to use curl to automatically fill the fields and submit the
|
||||
### forms.
|
||||
### We cannot use it since this app uses websocket exclusively.
|
||||
|
||||
# Set the app as temporarily public for curl call
|
||||
ynh_script_progression --message="Configuring SSOwat..." --time --weight=1
|
||||
# Making the app public for curl
|
||||
ynh_permission_update --permission="main" --add="visitors"
|
||||
# # Set the app as temporarily public for curl call
|
||||
# ynh_script_progression --message="Configuring SSOwat..." --time --weight=1
|
||||
# # Making the app public for curl
|
||||
# ynh_permission_update --permission="main" --add="visitors"
|
||||
|
||||
# Installation with curl
|
||||
# # Installation with curl
|
||||
# ynh_script_progression --message="Finalizing installation..." --time --weight=1
|
||||
# ynh_local_curl "/" "key1=value1" "key2=value2" "key3=value3"
|
||||
|
||||
# Remove the public access
|
||||
ynh_permission_update --permission="main" --remove="visitors"
|
||||
# # Remove the public access
|
||||
# ynh_permission_update --permission="main" --remove="visitors"
|
||||
|
||||
#=================================================
|
||||
# GENERIC FINALIZATION
|
||||
|
@ -409,7 +406,7 @@ fi
|
|||
### does have for example an admin interface or an API.
|
||||
|
||||
# Only the admin can access the admin panel of the app (if the app has an admin panel)
|
||||
ynh_permission_create --permission="admin" --url="/admin" --allowed=$admin
|
||||
# ynh_permission_create --permission="admin" --url="/admin" --allowed=$admin
|
||||
|
||||
# Everyone can access the API part
|
||||
# We don't want to display the tile in the SSO so we put --show_tile="false"
|
||||
|
|
|
@ -121,7 +121,7 @@ chown -R $app:www-data "$datadir"
|
|||
ynh_script_progression --message="Reinstalling dependencies..." --time --weight=1
|
||||
|
||||
# Define and install dependencies
|
||||
ynh_install_app_dependencies $pkg_dependencies
|
||||
# ynh_install_app_dependencies $pkg_dependencies
|
||||
|
||||
#=================================================
|
||||
# RESTORE THE MYSQL DATABASE
|
||||
|
|
Loading…
Reference in a new issue