PHP code example of plasticstudio / ps-deployer
1. Go to this page and download the library: Download plasticstudio/ps-deployer 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/ */
plasticstudio / ps-deployer example snippets
namespace Deployer;
//set('current_path', '/container/application/current');
set('repository', '[email protected] :PlasticStudio/skeletor.git');
set('remote_assets_backup_path', '/container/backups/containers/latest/application/shared/public/assets'); //no trailing slash is important
set('remote_assets_path', '/container/application/shared/public/assets/');
set('local_assets_path', '/var/www/html/public/assets/');
//Staging
host('uat.domain.co.nz')
->set('labels', ['stage' => 'uat'])
->set('http_user', 'uatuser')
->set('remote_user', 'uatuser');
//Production
host('production.domain.co.nz')
->set('labels', ['stage' => 'prod'])
->set('http_user', 'produser')
->set('remote_user', 'uatuser');
namespace Deployer;
se
//set('current_path', '/container/application/current');
set('repository', '[email protected] :PlasticStudio/skeletor.git');
set('remote_assets_backup_path', '/container/backups/containers/latest/application/shared/public/assets'); //no trailing slash is important
set('remote_assets_path', '/container/application/shared/public/assets/');
set('local_assets_path', '/var/www/html/public/assets/');
//Staging
host('uat.domain.co.nz')
->set('labels', ['stage' => 'uat'])
->set('http_user', 'uatuser')
->set('remote_user', 'uatuser');
//Production
host('production.domain.co.nz')
->set('labels', ['stage' => 'prod'])
->set('http_user', 'produser')
->set('remote_user', 'uatuser');