Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F433277
PhabricatorDaemonManagementDebugWorkflow.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
PhabricatorDaemonManagementDebugWorkflow.php
View Options
<?php
final
class
PhabricatorDaemonManagementDebugWorkflow
extends
PhabricatorDaemonManagementWorkflow
{
public
function
shouldParsePartial
()
{
return
true
;
}
protected
function
didConstruct
()
{
$this
->
setName
(
'debug'
)
->
setExamples
(
'**debug** __daemon__'
)
->
setSynopsis
(
pht
(
'Start __daemon__ in the foreground and print large volumes of '
.
'diagnostic information to the console.'
))
->
setArguments
(
array
(
array
(
'name'
=>
'argv'
,
'wildcard'
=>
true
,
),
array
(
'name'
=>
'as-current-user'
,
'help'
=>
pht
(
'Run the daemon as the current user '
.
'instead of the configured %s'
,
'phd.user'
),
),
array
(
'name'
=>
'autoscale'
,
'help'
=>
pht
(
'Put the daemon in an autoscale group.'
),
),
));
}
public
function
execute
(
PhutilArgumentParser
$args
)
{
$argv
=
$args
->
getArg
(
'argv'
);
$run_as_current_user
=
$args
->
getArg
(
'as-current-user'
);
if
(!
$argv
)
{
throw
new
PhutilArgumentUsageException
(
pht
(
'You must specify which daemon to debug.'
));
}
$config
=
array
();
$config
[
'class'
]
=
array_shift
(
$argv
);
$config
[
'argv'
]
=
$argv
;
if
(
$args
->
getArg
(
'autoscale'
))
{
$config
[
'autoscale'
]
=
array
(
'group'
=>
'debug'
,
);
}
return
$this
->
launchDaemons
(
array
(
$config
,
),
$is_debug
=
true
,
$run_as_current_user
);
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Sat, May 3, 3:37 PM (2 d)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
61134
Default Alt Text
PhabricatorDaemonManagementDebugWorkflow.php (1 KB)
Attached To
Mode
rP Phorge
Attached
Detach File
Event Timeline
Log In to Comment