From 8a89a9594f51e9e094b1e86d77d07b7f48ca6a8d Mon Sep 17 00:00:00 2001 From: midoks Date: Sat, 18 Jun 2022 13:01:18 +0800 Subject: [PATCH] Update openresty.service.tpl --- plugins/openresty/init.d/openresty.service.tpl | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/plugins/openresty/init.d/openresty.service.tpl b/plugins/openresty/init.d/openresty.service.tpl index b9b46574f..2e5b44f99 100644 --- a/plugins/openresty/init.d/openresty.service.tpl +++ b/plugins/openresty/init.d/openresty.service.tpl @@ -3,10 +3,12 @@ Description=OpenResty is a dynamic web platform based on NGINX and LuaJIT. After=network.target [Service] + +{$SERVER_PATH} Type=forking -ExecStart=/usr/local/open/sbin/nginx -c /usr/local/nginx/conf/nginx.conf -ExecStop=/usr/local/nginx/sbin/nginx -s stop -ExecReload=/usr/local/nginx/sbin/nginx -s reload +ExecStart={$SERVER_PATH}/openresty/bin/openresty -c {$SERVER_PATH}/openresty/nginx/conf/nginx.conf +ExecStop={$SERVER_PATH}/openresty/bin/openresty -s stop +ExecReload={$SERVER_PATH}/openresty/bin/openresty -s reload KillMode=process Restart=on-failure