DataSift\Storyplayer\HostLib\VagrantVm::runCommandViaHostManager PHP Метод

runCommandViaHostManager() публичный Метод

public runCommandViaHostManager ( VagrantVmDetails $vmDetails, string $command ) : CommandResult
$vmDetails VagrantVmDetails
$command string
Результат DataSift\Storyplayer\CommandLib\CommandResult
    public function runCommandViaHostManager($vmDetails, $command)
    {
        // what are we doing?
        $log = usingLog()->startAction("run vagrant command '{$command}'");
        // build the command
        $fullCommand = "cd '{$vmDetails->dir}' && vagrant ssh -c \"{$command}\"";
        // run the command
        $commandRunner = new CommandRunner();
        $result = $commandRunner->runSilently($fullCommand);
        // all done
        $log->endAction("return code was '{$result->returnCode}'");
        return $result;
    }