mirror of
https://github.com/YunoHost-Apps/cockpit_ynh.git
synced 2024-09-03 18:16:26 +02:00
Fix
This commit is contained in:
parent
dff622dcda
commit
9ac97734ed
4 changed files with 9 additions and 36 deletions
|
@ -1,7 +1,7 @@
|
|||
#sub_path_only rewrite ^__PATH__$ __PATH__/ permanent;
|
||||
location ^~ __PATH__/ {
|
||||
|
||||
proxy_pass http://127.0.0.1:__PORT__;
|
||||
proxy_pass http://127.0.0.1:__PORT__/;
|
||||
proxy_http_version 1.1;
|
||||
proxy_buffering off;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
|
|
|
@ -39,11 +39,6 @@
|
|||
},
|
||||
"example": "/monitor",
|
||||
"default": "/monitor"
|
||||
},
|
||||
{
|
||||
"name": "is_public",
|
||||
"type": "boolean",
|
||||
"default": true
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
@ -83,34 +83,20 @@ ynh_script_progression --message="Configuring NGINX web server..." --weight=2
|
|||
# Create a dedicated NGINX config
|
||||
ynh_add_nginx_config
|
||||
|
||||
#=================================================
|
||||
# INTEGRATE SERVICE IN YUNOHOST
|
||||
#=================================================
|
||||
ynh_script_progression --message="Integrating service in YunoHost..." --weight=1
|
||||
|
||||
yunohost service add cockpit.socket --description="Monitor" --log="/var/log/$app/$app.log"
|
||||
|
||||
#=================================================
|
||||
# START SYSTEMD SERVICE
|
||||
#=================================================
|
||||
ynh_script_progression --message="Starting a systemd service..." --weight=2
|
||||
|
||||
# Reload services
|
||||
#systemctl enable cockpit.socket --quiet
|
||||
#ynh_systemd_action --service_name=cockpit.socket --action=start
|
||||
|
||||
#=================================================
|
||||
# ADVERTISE SERVICE IN ADMIN PANEL
|
||||
#=================================================
|
||||
|
||||
yunohost service add cockpit.socket --description="Monitor" #--log="/var/log/syslog"
|
||||
|
||||
ynh_systemd_action --service_name=cockpit.socket --action="start" --log_path="/var/log/$app/$app.log"
|
||||
|
||||
#=================================================
|
||||
# SETUP SSOWAT
|
||||
#=================================================
|
||||
# ynh_script_progression --message="Configuring SSOwat..." --weight=1
|
||||
|
||||
# # Make app public if necessary or protect it
|
||||
# if [ $is_public -eq 1 ]
|
||||
# then
|
||||
# ynh_permission_update --permission "main" --add "visitors"
|
||||
# fi
|
||||
|
||||
#=================================================
|
||||
# RELOAD NGINX
|
||||
#=================================================
|
||||
|
|
|
@ -30,7 +30,7 @@ final_path=$(ynh_app_setting_get $app final_path)
|
|||
if ynh_exec_warn_less yunohost service status $app >/dev/null
|
||||
then
|
||||
ynh_script_progression --message="Removing $app service..." --weight=1
|
||||
yunohost service remove $app
|
||||
yunohost service remove cockpit.socket
|
||||
fi
|
||||
|
||||
#=================================================
|
||||
|
@ -49,14 +49,6 @@ ynh_script_progression --message="Removing dependencies..." --weight=1
|
|||
# Remove metapackage and its dependencies
|
||||
ynh_remove_app_dependencies
|
||||
|
||||
#=================================================
|
||||
# REMOVE APP MAIN DIR
|
||||
#=================================================
|
||||
# ynh_print_info "Removing app main directory"
|
||||
|
||||
# # Remove the app directory securely
|
||||
# ynh_secure_remove "$final_path"
|
||||
|
||||
#=================================================
|
||||
# REMOVE NGINX CONFIGURATION
|
||||
#=================================================
|
||||
|
|
Loading…
Add table
Reference in a new issue