Skip to content

Instantly share code, notes, and snippets.

@radmiraal
Created June 22, 2014 00:38
Show Gist options
  • Save radmiraal/84281f5393523c157d82 to your computer and use it in GitHub Desktop.
Save radmiraal/84281f5393523c157d82 to your computer and use it in GitHub Desktop.
Example Surf Deployment with rsync
<?php
use \TYPO3\Surf\Domain\Model\Node;
use \TYPO3\Surf\Domain\Model\SimpleWorkflow;
$application = new \TYPO3\Surf\Application\TYPO3\Flow('deployment-name');
$application->setDeploymentPath('/var/www/');
$application->setOption('packageMethod', 'git');
$application->setOption('transferMethod', 'rsync');
$application->setOption('updateMethod', NULL);
$application->setOption('repositoryUrl', 'ssh://review.typo3.org/repo.git');
$application->setOption('sitePackageKey', 'My.Site');
$deployment->addApplication($application);
$workflow = new SimpleWorkflow();
$workflow->setEnableRollback(TRUE);
$deployment->setWorkflow($workflow);
$node = new Node('my.deployment.server');
$node->setHostname('my.deployment.server.hostname');
$application->addNode($node);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment