From b4b99655b1ef4db20e69f077dc87fe77fb091aef Mon Sep 17 00:00:00 2001 From: midoks Date: Tue, 21 Jun 2022 10:36:05 +0800 Subject: [PATCH] =?UTF-8?q?php=20systemd=20=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- plugins/php/init.d/php.service.bak.tpl | 17 +++++++++++++++++ plugins/php/init.d/php.service.tpl | 6 +++--- 2 files changed, 20 insertions(+), 3 deletions(-) create mode 100644 plugins/php/init.d/php.service.bak.tpl diff --git a/plugins/php/init.d/php.service.bak.tpl b/plugins/php/init.d/php.service.bak.tpl new file mode 100644 index 000000000..9a02235e2 --- /dev/null +++ b/plugins/php/init.d/php.service.bak.tpl @@ -0,0 +1,17 @@ +# It's not recommended to modify this file in-place, because it +# will be overwritten during upgrades. If you want to customize, +# the best way is to use the "systemctl edit" command. + +[Unit] +Description=The PHP {$VERSION} FastCGI Process Manager +After=network.target + +[Service] +Type=forking +ExecStart={$SERVER_PATH}/php/{$VERSION}/sbin/php-fpm --daemonize --fpm-config {$SERVER_PATH}/php/{$VERSION}/etc/php-fpm.conf +ExecStop=/bin/kill -INT $MAINPID +ExecReload=/bin/kill -USR2 $MAINPID +PrivateTmp=false + +[Install] +WantedBy=multi-user.target diff --git a/plugins/php/init.d/php.service.tpl b/plugins/php/init.d/php.service.tpl index 9a02235e2..0d5beb87d 100644 --- a/plugins/php/init.d/php.service.tpl +++ b/plugins/php/init.d/php.service.tpl @@ -8,9 +8,9 @@ After=network.target [Service] Type=forking -ExecStart={$SERVER_PATH}/php/{$VERSION}/sbin/php-fpm --daemonize --fpm-config {$SERVER_PATH}/php/{$VERSION}/etc/php-fpm.conf -ExecStop=/bin/kill -INT $MAINPID -ExecReload=/bin/kill -USR2 $MAINPID +ExecStart={$SERVER_PATH}/php/init.d/php{$VERSION} start +ExecStop={$SERVER_PATH}/php/init.d/php{$VERSION} stop +ExecReload={$SERVER_PATH}/php/init.d/php{$VERSION} reload PrivateTmp=false [Install]