vitodeploy / vito

The Ultimate Server Management Tool
https://vitodeploy.com
GNU Affero General Public License v3.0
947 stars 156 forks source link

How to restart PHP-FPM from deployment script ? #270

Closed gaetan-hexadog closed 1 month ago

gaetan-hexadog commented 1 month ago

Hi,

how can I restart PHP-FPM from a deployment script ?

regards

saeedvaziry commented 1 month ago

You can just run a command in your script to restart

sudo systemctl restart phpX.Y-fpm

for example for PHP 8.1

sudo systemctl restart php8.1-fpm
gaetan-hexadog commented 1 month ago

Hi @saeedvaziry

Running a cmd with sudo will ask for the password ! Right ? How to manage that with deployment script ?

saeedvaziry commented 1 month ago

@gaetan-hexadog vito user has enough permissions, it should not ask for password.