-
Notifications
You must be signed in to change notification settings - Fork 178
/
Task.php
60 lines (53 loc) · 1.08 KB
/
Task.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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
<?php
namespace Laravel\Envoy;
class Task
{
/**
* All of the hosts to run the task on.
*
* @var array
*/
public $hosts = [];
/**
* The username the task should be run as.
*
* @var string
*/
public $user;
/**
* The script commands.
*
* @var string
*/
public $script;
/**
* Indicates if the task should be run in parallel across servers.
*
* @var array
*/
public $parallel;
/**
* Asks a user for a confirmation.
*
* @var string
*/
public $confirm;
/**
* Create a new Task instance.
*
* @param array $hosts
* @param string $user
* @param string $script
* @param bool $parallel
* @param string|null $confirm
* @return void
*/
public function __construct(array $hosts, $user, $script, $parallel = false, $confirm = null)
{
$this->user = $user;
$this->hosts = $hosts;
$this->script = $script;
$this->parallel = $parallel;
$this->confirm = $confirm;
}
}