PHP code example of samyapp / cloudways-restart-php-deployer-task

1. Go to this page and download the library: Download samyapp/cloudways-restart-php-deployer-task library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

samyapp / cloudways-restart-php-deployer-task example snippets


// The email attached to your cloudways account.
set('cloudways_email', '[email protected]'); 

// the id of the cloudways server to restart
set('cloudways_server_id', 42); 

// the php version to restart
set('cloudways_php_version', '8.1');

// your cloudways api key - you could hard code this in your deploy script of
// just set it in your environment instead.
set('cloudways_api_key', $_ENV['CLOUDWAYS_API_KEY']);

after('deploy:symlink', 'deploy:restart-php-fpm');