mirror of
https://github.com/YunoHost-Apps/headscale_ynh.git
synced 2024-09-03 19:25:53 +02:00
Cleanup and appease the almighty linter
This commit is contained in:
parent
d40de63888
commit
6bacfcdd81
6 changed files with 9 additions and 59 deletions
|
@ -1,34 +0,0 @@
|
|||
# See here for more information
|
||||
# https://github.com/YunoHost/package_check#syntax-check_process-file
|
||||
|
||||
# Move this file from check_process.default to check_process when you have filled it.
|
||||
|
||||
;; Test complet
|
||||
; Manifest
|
||||
domain="domain.tld"
|
||||
path="/path"
|
||||
is_public=1
|
||||
language="fr"
|
||||
admin="john"
|
||||
password="1Strong-Password"
|
||||
port="666"
|
||||
; Checks
|
||||
pkg_linter=1
|
||||
setup_sub_dir=1
|
||||
setup_root=1
|
||||
setup_nourl=0
|
||||
setup_private=1
|
||||
setup_public=1
|
||||
upgrade=1
|
||||
upgrade=1 from_commit=CommitHash
|
||||
backup_restore=1
|
||||
multi_instance=1
|
||||
port_already_use=0
|
||||
change_url=1
|
||||
;;; Options
|
||||
Email=
|
||||
Notification=none
|
||||
;;; Upgrade options
|
||||
; commit=CommitHash
|
||||
name=Name and date of the commit.
|
||||
manifest_arg=domain=DOMAIN&path=PATH&is_public=1&language=fr&admin=USER&password=pass&port=666&
|
|
@ -21,8 +21,8 @@ fund = "https://ko-fi.com/headscale"
|
|||
yunohost = ">= 11.0.0"
|
||||
architectures = "all"
|
||||
multi_instance = false
|
||||
ldap = "true"
|
||||
sso = "false"
|
||||
ldap = true
|
||||
sso = false
|
||||
disk = "50M"
|
||||
ram.build = "50M"
|
||||
ram.runtime = "50M"
|
||||
|
@ -80,6 +80,6 @@ ram.runtime = "50M"
|
|||
metrics.default = 9090
|
||||
grpc.default = 50443
|
||||
|
||||
# FIXME: cf. config file
|
||||
# Disabled, cf. config file
|
||||
# [resources.database]
|
||||
# type = "postgresql"
|
||||
|
|
|
@ -56,14 +56,6 @@ then
|
|||
ynh_exec_warn_less yunohost firewall disallow TCP $port
|
||||
fi
|
||||
|
||||
#=================================================
|
||||
# REMOVE FAIL2BAN CONFIGURATION
|
||||
#=================================================
|
||||
ynh_script_progression --message="Removing Fail2Ban configuration..." --weight=1
|
||||
|
||||
# Remove the dedicated Fail2Ban config
|
||||
ynh_remove_fail2ban_config
|
||||
|
||||
#=================================================
|
||||
# SPECIFIC REMOVE
|
||||
#=================================================
|
||||
|
@ -71,24 +63,12 @@ ynh_remove_fail2ban_config
|
|||
#=================================================
|
||||
ynh_script_progression --message="Removing various files..." --weight=1
|
||||
|
||||
# Remove a cron file
|
||||
ynh_secure_remove --file="/etc/cron.d/$app"
|
||||
|
||||
# Remove a directory securely
|
||||
ynh_secure_remove --file="/etc/$app"
|
||||
|
||||
# Remove the log files
|
||||
ynh_secure_remove --file="/var/log/$app"
|
||||
|
||||
#=================================================
|
||||
# GENERIC FINALIZATION
|
||||
#=================================================
|
||||
# REMOVE DEDICATED USER
|
||||
#=================================================
|
||||
#REMOVEME? ynh_script_progression --message="Removing the dedicated system user..." --weight=1
|
||||
|
||||
# Delete a system user
|
||||
#REMOVEME? ynh_system_user_delete --username=$app
|
||||
|
||||
#=================================================
|
||||
# END OF SCRIPT
|
||||
|
|
|
@ -27,7 +27,7 @@ chown $app:$app "$install_dir/config.yaml"
|
|||
#=================================================
|
||||
# RESTORE THE NGINX CONFIGURATION
|
||||
#=================================================
|
||||
ynh_script_progression --message="Restoring the NGINX web server configuration..." --time --weight=1
|
||||
ynh_script_progression --message="Restoring the NGINX web server configuration..." --weight=1
|
||||
|
||||
ynh_restore_file --origin_path="/etc/nginx/conf.d/$domain.d/$app.conf"
|
||||
|
||||
|
|
|
@ -39,7 +39,7 @@ chown -R $app:www-data "$install_dir"
|
|||
#=================================================
|
||||
# NGINX CONFIGURATION
|
||||
#=================================================
|
||||
ynh_script_progression --message="Upgrading NGINX web server configuration..." --time --weight=1
|
||||
ynh_script_progression --message="Upgrading NGINX web server configuration..." --weight=1
|
||||
|
||||
# Create a dedicated NGINX config
|
||||
ynh_add_nginx_config
|
||||
|
|
4
tests.toml
Normal file
4
tests.toml
Normal file
|
@ -0,0 +1,4 @@
|
|||
test_format = 1.0
|
||||
|
||||
[default]
|
||||
|
Loading…
Reference in a new issue