Documentation ¶
Index ¶
- Constants
- Variables
- type BaseClientError
- type DomainRecord
- type DomainRecordResponse
- type DomainResponse
- type ErrorBodyResponse
- type FirewallRule
- type GatewayEntity
- type ImageResponse
- type KubernetesClusterEntity
- type KubernetesNodeGroupEntity
- type LocationEntity
- type LocationEntityWrap
- type NATRule
- type NATRuleListResponseWrap
- type NATRuleType
- type NICEntity
- type NetworkData
- type NetworkEntity
- type NetworkType
- type ProtoType
- type ProtocolType
- type RecordType
- type RequestError
- type SSClient
- func (c *SSClient) CreateDomain(name string, migrateRecords bool) (*TaskIDWrap, error)
- func (c *SSClient) CreateDomainAndWait(name string, migrateRecords bool) (*DomainResponse, error)
- func (c *SSClient) CreateGateway(locationID string, name string, bandwidthMbps int, networkIDs []string) (*TaskIDWrap, error)
- func (c *SSClient) CreateGatewayAndWait(locationID string, name string, bandwidthMbps int, networkIDs []string) (*GatewayEntity, error)
- func (c *SSClient) CreateKubernetesCluster(locationID string, name string, version string, highAvailability bool, ...) (*KubernetesClusterEntity, error)
- func (c *SSClient) CreateKubernetesClusterAndWait(locationID string, name string, version string, highAvailability bool, ...) (*KubernetesClusterEntity, error)
- func (c *SSClient) CreateKubernetesNodeGroups(kubernetesClusterID string, nodeGroups []*KubernetesNodeGroupEntity) (*KubernetesClusterEntity, error)
- func (c *SSClient) CreateKubernetesNodeGroupsAndWait(kubernetesClusterID string, nodeGroups []*KubernetesNodeGroupEntity) (*KubernetesClusterEntity, error)
- func (c *SSClient) CreateNIC(serverID, networkID string, bandwidth int) (*TaskIDWrap, error)
- func (c *SSClient) CreateNICAndWait(serverID, networkID string, bandwidth int) (*NICEntity, error)
- func (c *SSClient) CreateNetwork(name string, locationID string, description string, networkPrefix string, ...) (*TaskIDWrap, error)
- func (c *SSClient) CreateNetworkAndWait(name string, locationID string, description string, networkPrefix string, ...) (*NetworkEntity, error)
- func (c *SSClient) CreateRecord(domainName string, record DomainRecord) (*TaskIDWrap, error)
- func (c *SSClient) CreateRecordAndWait(domainName string, record DomainRecord) (*DomainRecordResponse, error)
- func (c *SSClient) CreateSSHKey(name string, publicKey string) (*SSHResponse, error)
- func (c *SSClient) CreateServer(name string, locationID string, imageID string, cpu int, ram int, ...) (*TaskIDWrap, error)
- func (c *SSClient) CreateServerAndWait(name string, locationID string, imageID string, cpu int, ram int, ...) (*ServerResponse, error)
- func (c *SSClient) CreateVolume(serverID, name string, size int) (*TaskIDWrap, error)
- func (c *SSClient) CreateVolumeAndWait(serverID string, name string, size int) (*VolumeEntity, error)
- func (c *SSClient) DeleteDomain(domainName string) error
- func (c *SSClient) DeleteGateway(gatewayID string) error
- func (c *SSClient) DeleteKubernetesCluster(kubernetesClusterID string) error
- func (c *SSClient) DeleteKubernetesNodeGroup(kubernetesClusterID string, nodeGroupID string) error
- func (c *SSClient) DeleteNIC(serverID string, nicID int) error
- func (c *SSClient) DeleteNetwork(networkID string) error
- func (c *SSClient) DeleteRecord(domainName string, recordId string) error
- func (c *SSClient) DeleteSSHKey(sshID int) error
- func (c *SSClient) DeleteServer(serverID string) error
- func (c *SSClient) DeleteVolume(serverID string, volumeID int) error
- func (c *SSClient) DeployIngressController(kubernetesClusterID string, nodeGroupID string) (*KubernetesClusterEntity, error)
- func (c *SSClient) DeployIngressControllerAndWait(kubernetesClusterID string, nodeGroupID string) (*KubernetesClusterEntity, error)
- func (c *SSClient) EditFirewallRules(gatewayID string, firewallRules []*FirewallRule) (*TaskIDWrap, error)
- func (c *SSClient) EditFirewallRulesAndWait(gatewayID string, firewallRules []*FirewallRule) (*GatewayEntity, error)
- func (c *SSClient) EditGatewayBandwidth(gatewayID string, bandwidthMbps int) (*TaskIDWrap, error)
- func (c *SSClient) EditNATRules(gatewayID string, NATRules []*NATRule) (*TaskIDWrap, error)
- func (c *SSClient) EditNATRulesAndWait(gatewayID string, NATRules []*NATRule) (*GatewayEntity, error)
- func (c *SSClient) GetAvailableKubernetesVersions(kubernetesClusterID string) ([]string, error)
- func (c *SSClient) GetDomain(domainName string) (*DomainResponse, error)
- func (c *SSClient) GetDomainList() ([]*DomainResponse, error)
- func (c *SSClient) GetFirewallRules(gatewayID string) ([]*FirewallRule, error)
- func (c *SSClient) GetGateway(gatewayID string) (*GatewayEntity, error)
- func (c *SSClient) GetGatewayList() ([]*GatewayEntity, error)
- func (c *SSClient) GetImageList() ([]*ImageResponse, error)
- func (c *SSClient) GetKubernetesCluster(kubernetesClusterID string) (*KubernetesClusterEntity, error)
- func (c *SSClient) GetKubernetesClusterList() ([]*KubernetesClusterEntity, error)
- func (c *SSClient) GetKubernetesNodeGroup(kubernetesClusterID string, nodeGroupID string) (*KubernetesNodeGroupEntity, error)
- func (c *SSClient) GetKubernetesNodeGroupList() ([]*KubernetesNodeGroupEntity, error)
- func (c *SSClient) GetKubernetesVersions() ([]string, error)
- func (c *SSClient) GetLocationList() ([]*LocationEntity, error)
- func (c *SSClient) GetNATRules(gatewayID string) ([]*NATRule, error)
- func (c *SSClient) GetNIC(serverID string, nicID int) (*NICEntity, error)
- func (c *SSClient) GetNICList(serverID string) ([]*NICEntity, error)
- func (c *SSClient) GetNetwork(networkID string) (*NetworkEntity, error)
- func (c *SSClient) GetNetworkList() ([]*NetworkEntity, error)
- func (c *SSClient) GetRecord(recordID string, domainName string) (*DomainRecordResponse, error)
- func (c *SSClient) GetRecordList(domainName string) ([]*DomainRecordResponse, error)
- func (c *SSClient) GetSSHKey(sshID int) (*SSHResponse, error)
- func (c *SSClient) GetSSHKeyList() ([]*SSHResponse, error)
- func (c *SSClient) GetServer(serverID string) (*ServerResponse, error)
- func (c *SSClient) GetServerList() ([]*ServerResponse, error)
- func (c *SSClient) GetSnapshotList(serverID string) ([]*SnapshotEntity, error)
- func (c *SSClient) GetTask(taskID string) (*TaskResponse, error)
- func (c *SSClient) GetVolume(serverID string, volumeID int) (*VolumeEntity, error)
- func (c *SSClient) RenameGateway(gatewayID string, name string) error
- func (c *SSClient) ScaleKubernetesNodeGroup(kubernetesClusterID string, nodeGroupID string, nodeReplicas int) (*KubernetesClusterEntity, error)
- func (c *SSClient) ScaleKubernetesNodeGroupAndWait(kubernetesClusterID string, nodeGroupID string, nodeReplicas int) (*KubernetesClusterEntity, error)
- func (c *SSClient) TagNetwork(networkID string) error
- func (c *SSClient) TagServer(serverID string) error
- func (c *SSClient) UpdateDomain(domainName string, cpu int, ram int) (*TaskIDWrap, error)
- func (c *SSClient) UpdateNetwork(networkID, name, description string) (*TaskIDWrap, error)
- func (c *SSClient) UpdateNetworkAndWait(networkID, name, description string) (*NetworkEntity, error)
- func (c *SSClient) UpdatePublicNIC(serverID string, nicID, bandwidth int) (*TaskIDWrap, error)
- func (c *SSClient) UpdatePublicNICAndWait(serverID string, nicID, bandwidth int) (*NICEntity, error)
- func (c *SSClient) UpdateRecord(recordID string, domainName string, record DomainRecord) (*TaskIDWrap, error)
- func (c *SSClient) UpdateRecordAndWait(recordID string, domainName string, record DomainRecord) (*DomainRecordResponse, error)
- func (c *SSClient) UpdateServer(serverID string, cpu int, ram int) (*TaskIDWrap, error)
- func (c *SSClient) UpdateServerAndWait(serverID string, cpu int, ram int) (*ServerResponse, error)
- func (c *SSClient) UpdateVolume(serverID string, volumeID int, name string, size int) (*TaskIDWrap, error)
- func (c *SSClient) UpdateVolumeAndWait(serverID string, volumeID int, name string, size int) (*VolumeEntity, error)
- func (c *SSClient) UpgradeKubernetesCluster(kubernetesClusterID string, version string) (*KubernetesClusterEntity, error)
- type SSHResponse
- type ServerResponse
- type SnapshotEntity
- type SnapshotEntityWrap
- type TaskIDWrap
- type TaskResponse
- type VolumeData
- type VolumeEntity
- type WrongKeyFormatError
Constants ¶
View Source
const ( FirewallActionAllow string = "Allow" FirewallActionDeny string = "Deny" FirewallDirectionIn string = "In" FirewallDirectionOut string = "Out" NATRuleTypeSNAT NATRuleType = "SNAT" NATRuleTypeDNAT NATRuleType = "DNAT" NATRuleTypeBINAT NATRuleType = "BINAT" ProtocolIP ProtoType = "IP" ProtocolTCP ProtoType = "TCP" ProtocolUDP ProtoType = "UDP" ProtocolICMP ProtoType = "ICMP" )
Variables ¶
View Source
var HOST_MAP = map[string]string{
"02": "https://api.serverspace.by",
"04": "https://api.serverspace.io",
"06": "https://api.serverspace.ru",
"07": "https://api.lincore.kz",
"08": "https://api.serverspace.us",
"09": "https://api.serverspace.com.tr",
"0a": "https://api.serverspace.in",
"14": "https://api.serverspace.kz",
"21": "https://api.serverspace.ca",
"22": "https://api.serverspace.com.br",
"23": "https://api.falconcloud.ae",
}
Functions ¶
This section is empty.
Types ¶
type BaseClientError ¶
func (*BaseClientError) Error ¶
func (e *BaseClientError) Error() string
func (*BaseClientError) Unwrap ¶
func (e *BaseClientError) Unwrap() error
type DomainRecord ¶
type DomainRecord struct { Name string `json:"name"` Type RecordType `json:"type"` IP *string `json:"ip,omitempty"` MailHost *string `json:"mail_host,omitempty"` Priority *int `json:"priority,omitempty"` CanonicalName *string `json:"canonical_name,omitempty"` NameServerHost *string `json:"name_server_host,omitempty"` Text *string `json:"text,omitempty"` Protocol *ProtocolType `json:"protocol,omitempty"` Service *string `json:"service,omitempty"` Weight *int `json:"weight,omitempty"` Port *int `json:"port,omitempty"` Target *string `json:"target,omitempty"` TTL *string `json:"ttl,omitempty"` }
type DomainRecordResponse ¶
type DomainRecordResponse struct { ID int `json:"id"` DomainRecord }
type DomainResponse ¶
type DomainResponse struct { Name string `json:"name,omitempty"` IsDelegated bool `json:"is_delegated,omitempty"` Records []*DomainRecordResponse `json:"records,omitempty"` }
type ErrorBodyResponse ¶
type FirewallRule ¶
type FirewallRule struct { Action string `json:"action,omitempty"` Direction string `json:"direction,omitempty"` Protocol ProtoType `json:"protocol,omitempty"` Source string `json:"source,omitempty"` SourcePort int `json:"source_port,omitempty"` Destination string `json:"destination,omitempty"` DestinationPort int `json:"destination_port,omitempty"` }
type GatewayEntity ¶
type GatewayEntity struct { ID string `json:"id,omitempty"` LocationID string `json:"location_id,omitempty"` Name string `json:"name,omitempty"` NICS []*NICEntity `json:"nics,omitempty"` NetworkIDs []string `json:"network_ids,omitempty"` NATRules []*NATRule `json:"nat_rules,omitempty"` FirewallRules []*FirewallRule `json:"firewall_rules,omitempty"` State string `json:"state,omitempty"` }
type ImageResponse ¶
type KubernetesClusterEntity ¶
type KubernetesClusterEntity struct { ID string `json:"id,omitempty"` LocationID string `json:"location_id,omitempty"` Name string `json:"name,omitempty"` Version string `json:"version,omitempty"` HighAvailability bool `json:"high_availability,omitempty"` NodeGroups []*KubernetesNodeGroupEntity `json:"node_groups,omitempty"` State string `json:"state,omitempty"` Tags []string `json:"tags,omitempty"` }
type KubernetesNodeGroupEntity ¶
type KubernetesNodeGroupEntity struct { ID string `json:"id,omitempty"` Name string `json:"name,omitempty"` CPUPerNode int `json:"cpu_per_node,omitempty"` RAMPerNode int `json:"ram_per_node,omitempty"` NumberOfNodes int `json:"number_of_nodes,omitempty"` Nodes []string `json:"nodes,omitempty"` Ingress bool `json:"ingress,omitempty"` State string `json:"state,omitempty"` Tags []string `json:"tags,omitempty"` }
type LocationEntity ¶
type LocationEntity struct { ID string `json:"id,omitempty"` SystemVolumeMin int `json:"system_volume_min,omitempty"` AdditionalVolumeMin int `json:"additional_volume_min,omitempty"` VolumeMax int `json:"volume_max,omitempty"` WindowsSystemVolumeMin int `json:"windows_system_volume_min,omitempty"` BandwidthMin int `json:"bandwidth_min,omitempty"` BandwidthMax int `json:"bandwidth_max,omitempty"` CPUQuantityOptions []int `json:"cpu_quantity_options,omitempty"` RAMSizeOptions []int `json:"ram_size_options,omitempty"` }
type LocationEntityWrap ¶
type LocationEntityWrap struct {
Location *LocationEntity `json:"location,omitempty"`
}
type NATRule ¶
type NATRule struct { RuleType NATRuleType `json:"type,omitempty"` Protocol ProtoType `json:"protocol,omitempty"` Source string `json:"source,omitempty"` Destination string `json:"destination,omitempty"` DestinationPort int `json:"destination_port,omitempty"` Translated string `json:"translated,omitempty"` TranslatedPort int `json:"translated_port,omitempty"` }
type NATRuleListResponseWrap ¶
type NATRuleListResponseWrap struct {
NATRules []*NATRule `json:"nat_rules,omitempty"`
}
type NATRuleType ¶
type NATRuleType string
type NICEntity ¶
type NICEntity struct { ID int `json:"id,omitempty"` ServerID string `json:"server_id,omitempty"` NetworkID string `json:"network_id,omitempty"` MAC string `json:"mac,omitempty"` IPAddress string `json:"ip_address,omitempty"` Mask int `json:"mask,omitempty"` Gateway string `json:"gateway,omitempty"` BandwidthMBPS int `json:"bandwidth_mbps,omitempty"` NetworkType NetworkType `json:"network_type,omitempty"` }
type NetworkData ¶
type NetworkEntity ¶
type NetworkEntity struct { ID string `json:"id,omitempty"` Name string `json:"name,omitempty"` LocationID string `json:"location_id,omitempty"` Description string `json:"description,omitempty"` NetworkPrefix string `json:"network_prefix,omitempty"` Mask int `json:"mask,omitempty"` ServerIDS []string `json:"server_ids,omitempty"` State string `json:"state,omitempty"` Created string `json:"created,omitempty"` Tags []string `json:"tags,omitempty"` }
type ProtocolType ¶
type ProtocolType string
const ( TCPProtocol ProtocolType = "TCP" UDPProtocol ProtocolType = "UDP" TLSProtocol ProtocolType = "TLS" )
type RecordType ¶
type RecordType string
const ( ARecordType RecordType = "A" AAAARecordType RecordType = "AAAA" MXRecordType RecordType = "MX" CNAMERecordType RecordType = "CNAME" NSRecordType RecordType = "NS" TXTRecordType RecordType = "TXT" SRVRecordType RecordType = "SRV" )
type RequestError ¶
type RequestError struct { BaseClientError Response *resty.Response Status int Body string }
func NewRequestError ¶
func NewRequestError(response *resty.Response, err error) *RequestError
func (*RequestError) Error ¶
func (e *RequestError) Error() string
type SSClient ¶
type SSClient struct { Key string Host string UserAgent *string // contains filtered or unexported fields }
func (*SSClient) CreateDomain ¶
func (c *SSClient) CreateDomain( name string, migrateRecords bool, ) (*TaskIDWrap, error)
func (*SSClient) CreateDomainAndWait ¶
func (c *SSClient) CreateDomainAndWait( name string, migrateRecords bool, ) (*DomainResponse, error)
func (*SSClient) CreateGateway ¶
func (*SSClient) CreateGatewayAndWait ¶
func (*SSClient) CreateKubernetesCluster ¶
func (c *SSClient) CreateKubernetesCluster( locationID string, name string, version string, highAvailability bool, tags []string, nodeGroups []*KubernetesNodeGroupEntity, ) (*KubernetesClusterEntity, error)
func (*SSClient) CreateKubernetesClusterAndWait ¶
func (c *SSClient) CreateKubernetesClusterAndWait( locationID string, name string, version string, highAvailability bool, tags []string, nodeGroups []*KubernetesNodeGroupEntity, ) (*KubernetesClusterEntity, error)
func (*SSClient) CreateKubernetesNodeGroups ¶
func (c *SSClient) CreateKubernetesNodeGroups(kubernetesClusterID string, nodeGroups []*KubernetesNodeGroupEntity) (*KubernetesClusterEntity, error)
func (*SSClient) CreateKubernetesNodeGroupsAndWait ¶
func (c *SSClient) CreateKubernetesNodeGroupsAndWait(kubernetesClusterID string, nodeGroups []*KubernetesNodeGroupEntity) (*KubernetesClusterEntity, error)
func (*SSClient) CreateNIC ¶
func (c *SSClient) CreateNIC(serverID, networkID string, bandwidth int) (*TaskIDWrap, error)
func (*SSClient) CreateNICAndWait ¶
func (*SSClient) CreateNetwork ¶
func (*SSClient) CreateNetworkAndWait ¶
func (*SSClient) CreateRecord ¶
func (c *SSClient) CreateRecord( domainName string, record DomainRecord, ) (*TaskIDWrap, error)
func (*SSClient) CreateRecordAndWait ¶
func (c *SSClient) CreateRecordAndWait( domainName string, record DomainRecord, ) (*DomainRecordResponse, error)
func (*SSClient) CreateSSHKey ¶
func (c *SSClient) CreateSSHKey( name string, publicKey string, ) (*SSHResponse, error)
func (*SSClient) CreateServer ¶
func (c *SSClient) CreateServer( name string, locationID string, imageID string, cpu int, ram int, volumes []*VolumeData, networks []*NetworkData, sshKeyIds []int, ) (*TaskIDWrap, error)
func (*SSClient) CreateServerAndWait ¶
func (c *SSClient) CreateServerAndWait( name string, locationID string, imageID string, cpu int, ram int, volumes []*VolumeData, networks []*NetworkData, sshKeyIds []int, ) (*ServerResponse, error)
func (*SSClient) CreateVolume ¶
func (c *SSClient) CreateVolume(serverID, name string, size int) (*TaskIDWrap, error)
func (*SSClient) CreateVolumeAndWait ¶
func (*SSClient) DeleteDomain ¶
func (*SSClient) DeleteGateway ¶
func (*SSClient) DeleteKubernetesCluster ¶
func (*SSClient) DeleteKubernetesNodeGroup ¶
func (*SSClient) DeleteNetwork ¶
func (*SSClient) DeleteRecord ¶
func (*SSClient) DeleteSSHKey ¶
func (*SSClient) DeleteServer ¶
func (*SSClient) DeleteVolume ¶
func (*SSClient) DeployIngressController ¶
func (c *SSClient) DeployIngressController(kubernetesClusterID string, nodeGroupID string) (*KubernetesClusterEntity, error)
func (*SSClient) DeployIngressControllerAndWait ¶
func (c *SSClient) DeployIngressControllerAndWait(kubernetesClusterID string, nodeGroupID string) (*KubernetesClusterEntity, error)
func (*SSClient) EditFirewallRules ¶
func (c *SSClient) EditFirewallRules(gatewayID string, firewallRules []*FirewallRule) (*TaskIDWrap, error)
func (*SSClient) EditFirewallRulesAndWait ¶
func (c *SSClient) EditFirewallRulesAndWait(gatewayID string, firewallRules []*FirewallRule) (*GatewayEntity, error)
func (*SSClient) EditGatewayBandwidth ¶
func (c *SSClient) EditGatewayBandwidth(gatewayID string, bandwidthMbps int) (*TaskIDWrap, error)
func (*SSClient) EditNATRules ¶
func (c *SSClient) EditNATRules(gatewayID string, NATRules []*NATRule) (*TaskIDWrap, error)
func (*SSClient) EditNATRulesAndWait ¶
func (c *SSClient) EditNATRulesAndWait(gatewayID string, NATRules []*NATRule) (*GatewayEntity, error)
func (*SSClient) GetAvailableKubernetesVersions ¶
func (*SSClient) GetDomain ¶
func (c *SSClient) GetDomain(domainName string) (*DomainResponse, error)
func (*SSClient) GetDomainList ¶
func (c *SSClient) GetDomainList() ([]*DomainResponse, error)
func (*SSClient) GetFirewallRules ¶
func (c *SSClient) GetFirewallRules(gatewayID string) ([]*FirewallRule, error)
func (*SSClient) GetGateway ¶
func (c *SSClient) GetGateway(gatewayID string) (*GatewayEntity, error)
func (*SSClient) GetGatewayList ¶
func (c *SSClient) GetGatewayList() ([]*GatewayEntity, error)
func (*SSClient) GetImageList ¶
func (c *SSClient) GetImageList() ([]*ImageResponse, error)
func (*SSClient) GetKubernetesCluster ¶
func (c *SSClient) GetKubernetesCluster(kubernetesClusterID string) (*KubernetesClusterEntity, error)
func (*SSClient) GetKubernetesClusterList ¶
func (c *SSClient) GetKubernetesClusterList() ([]*KubernetesClusterEntity, error)
func (*SSClient) GetKubernetesNodeGroup ¶
func (c *SSClient) GetKubernetesNodeGroup(kubernetesClusterID string, nodeGroupID string) (*KubernetesNodeGroupEntity, error)
func (*SSClient) GetKubernetesNodeGroupList ¶
func (c *SSClient) GetKubernetesNodeGroupList() ([]*KubernetesNodeGroupEntity, error)
func (*SSClient) GetKubernetesVersions ¶
func (*SSClient) GetLocationList ¶
func (c *SSClient) GetLocationList() ([]*LocationEntity, error)
func (*SSClient) GetNetwork ¶
func (c *SSClient) GetNetwork(networkID string) (*NetworkEntity, error)
func (*SSClient) GetNetworkList ¶
func (c *SSClient) GetNetworkList() ([]*NetworkEntity, error)
func (*SSClient) GetRecord ¶
func (c *SSClient) GetRecord(recordID string, domainName string) (*DomainRecordResponse, error)
func (*SSClient) GetRecordList ¶
func (c *SSClient) GetRecordList(domainName string) ([]*DomainRecordResponse, error)
func (*SSClient) GetSSHKeyList ¶
func (c *SSClient) GetSSHKeyList() ([]*SSHResponse, error)
func (*SSClient) GetServerList ¶
func (c *SSClient) GetServerList() ([]*ServerResponse, error)
func (*SSClient) GetSnapshotList ¶
func (c *SSClient) GetSnapshotList(serverID string) ([]*SnapshotEntity, error)
func (*SSClient) GetVolume ¶
func (c *SSClient) GetVolume(serverID string, volumeID int) (*VolumeEntity, error)
func (*SSClient) RenameGateway ¶
func (*SSClient) ScaleKubernetesNodeGroup ¶
func (*SSClient) ScaleKubernetesNodeGroupAndWait ¶
func (*SSClient) TagNetwork ¶
func (*SSClient) UpdateDomain ¶
func (*SSClient) UpdateNetwork ¶
func (c *SSClient) UpdateNetwork(networkID, name, description string) (*TaskIDWrap, error)
func (*SSClient) UpdateNetworkAndWait ¶
func (c *SSClient) UpdateNetworkAndWait(networkID, name, description string) (*NetworkEntity, error)
func (*SSClient) UpdatePublicNIC ¶
func (c *SSClient) UpdatePublicNIC(serverID string, nicID, bandwidth int) (*TaskIDWrap, error)
func (*SSClient) UpdatePublicNICAndWait ¶
func (*SSClient) UpdateRecord ¶
func (c *SSClient) UpdateRecord( recordID string, domainName string, record DomainRecord, ) (*TaskIDWrap, error)
func (*SSClient) UpdateRecordAndWait ¶
func (c *SSClient) UpdateRecordAndWait( recordID string, domainName string, record DomainRecord, ) (*DomainRecordResponse, error)
func (*SSClient) UpdateServer ¶
func (*SSClient) UpdateServerAndWait ¶
func (*SSClient) UpdateVolume ¶
func (*SSClient) UpdateVolumeAndWait ¶
func (*SSClient) UpgradeKubernetesCluster ¶
func (c *SSClient) UpgradeKubernetesCluster(kubernetesClusterID string, version string) (*KubernetesClusterEntity, error)
type SSHResponse ¶
type ServerResponse ¶
type ServerResponse struct { ID string `json:"id,omitempty"` Name string `json:"name,omitempty"` LocationID string `json:"location_id,omitempty"` ImageID string `json:"image_id,omitempty"` State string `json:"state,omitempty"` Login string `json:"login,omitempty"` Password string `json:"password,omitempty"` Created string `json:"created,omitempty"` CPU int `json:"cpu,omitempty"` RAM int `json:"ram_mb,omitempty"` Volumes []*VolumeEntity `json:"volumes,omitempty"` NICS []*NICEntity `json:"nics,omitempty"` SSHKeyIDS []int `json:"ssh_key_ids,omitempty"` Tags []string `json:"tags,omitempty"` }
type SnapshotEntity ¶
type SnapshotEntityWrap ¶
type SnapshotEntityWrap struct {
Snapshot *SnapshotEntity `json:"snapshot,omitempty"`
}
type TaskIDWrap ¶
type TaskIDWrap struct {
ID string `json:"task_id,omitempty"`
}
type TaskResponse ¶
type TaskResponse struct { ID string `json:"id,omitempty"` Created string `json:"created,omitempty"` Completed string `json:"completed,omitempty"` IsCompleted string `json:"is_completed,omitempty"` ServerID string `json:"server_id,omitempty"` LocationID string `json:"location_id,omitempty"` NetworkID string `json:"network_id,omitempty"` VolumeID int `json:"volume_id,omitempty"` NicID int `json:"nic_id,omitempty"` SnapshotID int `json:"snapshot_id,omitempty"` DomainName string `json:"domain_id,omitempty"` RecordID int `json:"record_id,omitempty"` GatewayID string `json:"gateway_id,omitempty"` KubernetesClusterID string `json:"cluster_id,omitempty"` KubernetesNodeGroupID string `json:"node_group_id,omitempty"` }
type VolumeData ¶
type VolumeEntity ¶
type WrongKeyFormatError ¶
type WrongKeyFormatError struct {
BaseClientError
}
func NewWrongKeyFormatError ¶
func NewWrongKeyFormatError(err error) *WrongKeyFormatError
Click to show internal directories.
Click to hide internal directories.