mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-19 05:12:41 +01:00
Set the working directory when providing SSH / SFTP interfaces
Summary: Ref T1049. Set the working directory when executing commands on Drydock hosts. Without this set, they execute in the user's default home directory. Test Plan: Ran a build and saw the correct working directory when running `pwd`. Reviewers: #blessed_reviewers, epriestley Reviewed By: #blessed_reviewers, epriestley Subscribers: CanadianBadass, epriestley, Korvin Maniphest Tasks: T1049 Differential Revision: https://secure.phabricator.com/D10293
This commit is contained in:
parent
34a90a0d2b
commit
2a4a30044b
1 changed files with 4 additions and 2 deletions
|
@ -108,13 +108,15 @@ final class DrydockPreallocatedHostBlueprintImplementation
|
|||
'host' => $resource->getAttribute('host'),
|
||||
'port' => $resource->getAttribute('port'),
|
||||
'credential' => $resource->getAttribute('credential'),
|
||||
'platform' => $resource->getAttribute('platform')));
|
||||
'platform' => $resource->getAttribute('platform')))
|
||||
->setWorkingDirectory($lease->getAttribute('path'));
|
||||
case 'filesystem':
|
||||
return id(new DrydockSFTPFilesystemInterface())
|
||||
->setConfiguration(array(
|
||||
'host' => $resource->getAttribute('host'),
|
||||
'port' => $resource->getAttribute('port'),
|
||||
'credential' => $resource->getAttribute('credential')));
|
||||
'credential' => $resource->getAttribute('credential')))
|
||||
->setWorkingDirectory($lease->getAttribute('path'));
|
||||
}
|
||||
|
||||
throw new Exception("No interface of type '{$type}'.");
|
||||
|
|
Loading…
Reference in a new issue