mirror of
https://github.com/233boy/sing-box.git
synced 2026-05-02 22:04:40 +08:00
fix: use supervise-daemon for OpenRC to prevent blocking
This commit is contained in:
@@ -77,6 +77,7 @@ install_service_openrc() {
|
||||
|
||||
name="$is_core_name"
|
||||
description="$is_core_name Service"
|
||||
|
||||
command="$is_core_bin"
|
||||
command_args="run -c $is_config_json -C $is_conf_dir"
|
||||
command_background=true
|
||||
@@ -84,6 +85,8 @@ pidfile="/run/\${RC_SVCNAME}.pid"
|
||||
output_log="/var/log/$is_core/access.log"
|
||||
error_log="/var/log/$is_core/error.log"
|
||||
|
||||
supervisor=supervise-daemon
|
||||
|
||||
depend() {
|
||||
need net
|
||||
after firewall
|
||||
@@ -97,11 +100,14 @@ EOF
|
||||
|
||||
name="Caddy"
|
||||
description="Caddy web server"
|
||||
|
||||
command="$is_caddy_bin"
|
||||
command_args="run --environ --config $is_caddyfile --adapter caddyfile"
|
||||
command_background=true
|
||||
pidfile="/run/\${RC_SVCNAME}.pid"
|
||||
|
||||
supervisor=supervise-daemon
|
||||
|
||||
depend() {
|
||||
need net
|
||||
after firewall
|
||||
|
||||
Reference in New Issue
Block a user