Scalr_Account_User::getSshConsoleSettings PHP Method

getSshConsoleSettings() public method

public getSshConsoleSettings ( $ignoreCache = false, $gvi = false, $serverId = null )
    public function getSshConsoleSettings($ignoreCache = false, $gvi = false, $serverId = null)
    {
        $result = array();
        $list = array(Scalr_Account_User::VAR_SSH_CONSOLE_USERNAME, Scalr_Account_User::VAR_SSH_CONSOLE_IP, Scalr_Account_User::VAR_SSH_CONSOLE_PORT, Scalr_Account_User::VAR_SSH_CONSOLE_KEY_NAME, Scalr_Account_User::VAR_SSH_CONSOLE_DISABLE_KEY_AUTH, Scalr_Account_User::VAR_SSH_CONSOLE_LOG_LEVEL, Scalr_Account_User::VAR_SSH_CONSOLE_PREFERRED_PROVIDER, Scalr_Account_User::VAR_SSH_CONSOLE_ENABLE_AGENT_FORWARDING);
        if ($serverId) {
            $dbServer = DBServer::LoadByID($serverId);
            $this->permissions->validate($dbServer);
        }
        foreach ($list as $name) {
            $result[$name] = $this->getVar($name, $ignoreCache);
            if ($gvi && $dbServer) {
                $result[$name] = $dbServer->applyGlobalVarsToValue($result[$name]);
            }
        }
        return $result;
    }