-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathdeploy.php
42 lines (30 loc) · 907 Bytes
/
deploy.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
<?php
namespace Deployer;
require 'recipe/symfony.php';
// Configuration
set('repository', '[email protected]:Pirate-Parties-International/PPI-rest-api.git');
set('git_tty', true); // [Optional] Allocate tty for git on first deployment
set('http_user', 'www-data');
set('writable_use_sudo', false);
set('dump_assets', false);
add('shared_files', []);
add('shared_dirs', [
'app/logs',
'etc',
"web/img/pp-flag",
"web/img/pp-logo",
"web/img/fb-covers",
"web/img/uploads"
]);
add('writable_dirs', []);
set('allow_anonymous_stats', false);
// Hosts
host('deploy.pss.web')
->stage('production')
->forwardAgent()
->set('deploy_path', '/var/www/sites/deployed/ppi_registry.prod');
// Tasks
// [Optional] if deploy fails automatically unlock.
after('deploy:failed', 'deploy:unlock');
// Migrate database before symlink new release.
//before('deploy:symlink', 'database:migrate');