Documentation ¶
Index ¶
- type Certificate
- type CertificateStatus
- type CertificateStatusType
- type CertificateType
- type CertificateUsedByRef
- type CertificateUsedByRefType
- type CpuType
- type Datacenter
- type DatacenterServerTypes
- type Error
- type ErrorCode
- type Firewall
- type FirewallResource
- type FirewallResourceLabelSelector
- type FirewallResourceServer
- type FirewallResourceType
- type FirewallRule
- type FirewallRuleDirection
- type FirewallRuleProtocol
- type FloatingIp
- type FloatingIpType
- type Image
- type ImageStatus
- type ImageType
- type Iso
- type IsoType
- type LoadBalancer
- type LoadBalancerAlgorithm
- type LoadBalancerAlgorithmType
- type LoadBalancerPrivateNet
- type LoadBalancerPublicNet
- type LoadBalancerPublicNetIpV4
- type LoadBalancerPublicNetIpV6
- type LoadBalancerService
- type LoadBalancerServiceHTTP
- type LoadBalancerServiceHealthCheck
- type LoadBalancerServiceHealthCheckHTTP
- type LoadBalancerServiceProtocol
- type LoadBalancerTarget
- type LoadBalancerTargetHealthStatus
- type LoadBalancerTargetHealthStatusStatus
- type LoadBalancerTargetIP
- type LoadBalancerTargetLabelSelector
- type LoadBalancerTargetServer
- type LoadBalancerTargetType
- type LoadBalancerType
- type Location
- type Network
- type NetworkRoute
- type NetworkSubnet
- type NetworkSubnetType
- type NetworkZone
- type PlacementGroup
- type PlacementGroupType
- type Server
- type ServerFirewallStatus
- type ServerFirewallStatusEnum
- type ServerPrivateNet
- type ServerPublicNet
- type ServerPublicNetIpV4
- type ServerPublicNetIpV6
- type ServerStatus
- type ServerType
- type ServerTypePrice
- type ServerTypePriceValue
- type StorageType
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Certificate ¶
type Certificate struct { Id int `json:"id"` Name string `json:"name"` Created time.Time `json:"created"` Labels map[string]string `json:"labels"` Type CertificateType `json:"type"` Certificate string `json:"certificate"` Fingerprint string `json:"fingerprint"` NotValidBefore time.Time `json:"not_valid_before"` NotValidAfter time.Time `json:"not_valid_after"` DomainNames []string `json:"domain_names"` Status *CertificateStatus `json:"status"` UsedBy []CertificateUsedByRef `json:"used_by"` }
type CertificateStatus ¶
type CertificateStatus struct { Issuance CertificateStatusType `json:"issuance"` Renewal CertificateStatusType `json:"renewal"` Error *Error `json:"error"` }
type CertificateStatusType ¶
type CertificateStatusType string
const ( CertificateStatusTypePending CertificateStatusType = "pending" CertificateStatusTypeFailed CertificateStatusType = "failed" CertificateStatusTypeCompleted CertificateStatusType = "completed" CertificateStatusTypeScheduled CertificateStatusType = "scheduled" )
type CertificateType ¶
type CertificateType string
const ( CertificateTypeUploaded CertificateType = "uploaded" CertificateTypeManaged CertificateType = "managed" )
type CertificateUsedByRef ¶
type CertificateUsedByRef struct { Id int `json:"id"` Type CertificateUsedByRefType `json:"type"` }
type CertificateUsedByRefType ¶
type CertificateUsedByRefType string
const (
CertificateUsedByRefTypeLoadBalancer CertificateUsedByRefType = "load_balancer"
)
type Datacenter ¶
type Datacenter struct { Id int `json:"id"` Name string `json:"name"` Description string `json:"description"` Location *Location `json:"location"` ServerTypes DatacenterServerTypes `json:"server_types"` }
type DatacenterServerTypes ¶
type Firewall ¶
type Firewall struct { Id int `json:"id"` Name string `json:"name"` Created time.Time `json:"created"` Labels map[string]string `json:"labels"` Rules []FirewallRule `json:"rules"` AppliedTo []FirewallResource `json:"applied_to"` }
type FirewallResource ¶
type FirewallResource struct { Type FirewallResourceType `json:"type"` Server *FirewallResourceServer `json:"server"` LabelSelector *FirewallResourceLabelSelector `json:"label_selector"` }
type FirewallResourceLabelSelector ¶
type FirewallResourceLabelSelector struct {
Selector string `json:"selector"`
}
type FirewallResourceServer ¶
type FirewallResourceServer struct {
Id int `json:"id"`
}
type FirewallResourceType ¶
type FirewallResourceType string
const ( FirewallResourceTypeServer FirewallResourceType = "server" FirewallResourceTypeLabelSelector FirewallResourceType = "label_selector" )
type FirewallRule ¶
type FirewallRule struct { Protocol FirewallRuleProtocol `json:"protocol"` Port *string `json:"port"` Direction FirewallRuleDirection `json:"direction"` SourceIps []net.IPNet `json:"source_ips"` DestinationIps []net.IPNet `json:"destination_ips"` Description *string `json:"description"` }
type FirewallRuleDirection ¶
type FirewallRuleDirection string
const ( FirewallRuleDirectionIn FirewallRuleDirection = "in" FirewallRuleDirectionOut FirewallRuleDirection = "out" )
type FirewallRuleProtocol ¶
type FirewallRuleProtocol string
const ( FirewallRuleProtocolTCP FirewallRuleProtocol = "tcp" FirewallRuleProtocolUDP FirewallRuleProtocol = "udp" FirewallRuleProtocolICMP FirewallRuleProtocol = "icmp" FirewallRuleProtocolESP FirewallRuleProtocol = "esp" FirewallRuleProtocolGRE FirewallRuleProtocol = "gre" )
type FloatingIp ¶
type FloatingIp struct { Id int `json:"id"` Name string `json:"name"` Created time.Time `json:"created"` Description string `json:"description"` Labels map[string]string `json:"labels"` Ip net.IP `json:"ip"` Network *net.IPNet `json:"network"` Type FloatingIpType `json:"type"` Server *Server `json:"server"` DnsPtr any `json:"dns_ptr"` HomeLocation *Location `json:"home_location"` Blocked bool `json:"blocked"` }
type FloatingIpType ¶
type FloatingIpType string
const ( FloatingIpTypeIpV4 FloatingIpType = "ipv4" FloatingIpTypeIpV6 FloatingIpType = "ipv6" )
type Image ¶
type Image struct { Id int `json:"id"` Name string `json:"name"` Type ImageType `json:"type"` Status ImageStatus `json:"status"` Created time.Time `json:"created"` Description string `json:"description"` Labels map[string]string `json:"labels"` ImageSize float32 `json:"image_size"` DiskSize float32 `json:"disk_size"` CreatedFrom *Server `json:"created_from"` BoundTo *Server `json:"bound_to"` RapidDeploy bool `json:"rapid_deploy"` OsFlavor string `json:"os_flavor"` OsVersion string `json:"os_version"` Deprecated time.Time `json:"deprecated"` }
type ImageStatus ¶
type ImageStatus string
const ( ImageStatusCreating ImageStatus = "creating" ImageStatusAvailable ImageStatus = "available" )
type LoadBalancer ¶
type LoadBalancer struct { Id int `json:"id"` Name string `json:"name"` Created time.Time `json:"created"` Labels map[string]string `json:"labels"` PublicNet LoadBalancerPublicNet `json:"public_net"` PrivateNet []LoadBalancerPrivateNet `json:"private_net"` Location *Location `json:"location"` LoadBalancerType *LoadBalancerType `json:"load_balancer_type"` Algorithm LoadBalancerAlgorithm `json:"algorithm"` Services []LoadBalancerService `json:"services"` Targets []LoadBalancerTarget `json:"targets"` IncludedTraffic uint64 `json:"included_traffic"` OutgoingTraffic uint64 `json:"outgoing_traffic"` IngoingTraffic uint64 `json:"ingoing_traffic"` }
type LoadBalancerAlgorithm ¶
type LoadBalancerAlgorithm struct {
Type LoadBalancerAlgorithmType `json:"type"`
}
type LoadBalancerAlgorithmType ¶
type LoadBalancerAlgorithmType string
const ( LoadBalancerAlgorithmTypeRoundRobin LoadBalancerAlgorithmType = "round_robin" LoadBalancerAlgorithmTypeLeastConnections LoadBalancerAlgorithmType = "least_connections" )
type LoadBalancerPrivateNet ¶
type LoadBalancerPublicNet ¶
type LoadBalancerPublicNet struct { Enabled bool `json:"enabled"` IpV4 LoadBalancerPublicNetIpV4 `json:"ipv4"` IpV6 LoadBalancerPublicNetIpV6 `json:"ipv6"` }
type LoadBalancerService ¶
type LoadBalancerService struct { Protocol LoadBalancerServiceProtocol `json:"protocol"` ListenPort int `json:"listen_port"` DestinationPort int `json:"destination_port"` ProxyProtocol bool `json:"proxy_protocol"` Http LoadBalancerServiceHTTP `json:"http"` HealthCheck LoadBalancerServiceHealthCheck `json:"health_check"` }
type LoadBalancerServiceHTTP ¶
type LoadBalancerServiceHealthCheck ¶
type LoadBalancerServiceHealthCheck struct { Protocol LoadBalancerServiceProtocol `json:"protocol"` Port int `json:"port"` Interval time.Duration `json:"interval"` Timeout time.Duration `json:"timeout"` Retries int `json:"retries"` Http *LoadBalancerServiceHealthCheckHTTP `json:"http"` }
type LoadBalancerServiceProtocol ¶
type LoadBalancerServiceProtocol string
const ( LoadBalancerServiceProtocolTCP LoadBalancerServiceProtocol = "tcp" LoadBalancerServiceProtocolHTTP LoadBalancerServiceProtocol = "http" LoadBalancerServiceProtocolHTTPS LoadBalancerServiceProtocol = "https" )
type LoadBalancerTarget ¶
type LoadBalancerTarget struct { Type LoadBalancerTargetType `json:"type"` Server *LoadBalancerTargetServer `json:"server"` Ip *LoadBalancerTargetIP `json:"ip"` LabelSelector *LoadBalancerTargetLabelSelector `json:"label_selector"` HealthStatus []LoadBalancerTargetHealthStatus `json:"health_status"` Targets []LoadBalancerTarget `json:"targets"` UsePrivateIp bool `json:"use_private_ip"` }
type LoadBalancerTargetHealthStatus ¶
type LoadBalancerTargetHealthStatus struct { ListenPort int `json:"listen_port"` Status LoadBalancerTargetHealthStatusStatus `json:"status"` }
type LoadBalancerTargetHealthStatusStatus ¶
type LoadBalancerTargetHealthStatusStatus string
const ( LoadBalancerTargetHealthStatusStatusUnknown LoadBalancerTargetHealthStatusStatus = "unknown" LoadBalancerTargetHealthStatusStatusHealthy LoadBalancerTargetHealthStatusStatus = "healthy" LoadBalancerTargetHealthStatusStatusUnhealthy LoadBalancerTargetHealthStatusStatus = "unhealthy" )
type LoadBalancerTargetIP ¶
type LoadBalancerTargetIP struct {
Ip string `json:"ip"`
}
type LoadBalancerTargetLabelSelector ¶
type LoadBalancerTargetLabelSelector struct {
Selector string `json:"selector"`
}
type LoadBalancerTargetServer ¶
type LoadBalancerTargetServer struct {
Server *Server `json:"server"`
}
type LoadBalancerTargetType ¶
type LoadBalancerTargetType string
const ( LoadBalancerTargetTypeServer LoadBalancerTargetType = "server" LoadBalancerTargetTypeLabelSelector LoadBalancerTargetType = "label_selector" LoadBalancerTargetTypeIP LoadBalancerTargetType = "ip" )
type LoadBalancerType ¶
type NetworkRoute ¶
type NetworkSubnet ¶
type NetworkSubnet struct { Type NetworkSubnetType `json:"type"` IpRange *net.IPNet `json:"ip_range"` NetworkZone NetworkZone `json:"network_zone"` Gateway net.IP `json:"gateway"` VswitchID int `json:"vswitch_id"` }
type NetworkSubnetType ¶
type NetworkSubnetType string
const ( NetworkSubnetTypeCloud NetworkSubnetType = "cloud" NetworkSubnetTypeServer NetworkSubnetType = "server" NetworkSubnetTypeVSwitch NetworkSubnetType = "vswitch" )
type NetworkZone ¶
type NetworkZone string
const ( NetworkZoneEuCentral NetworkZone = "eu-central" NetworkZoneUsEast NetworkZone = "us-east" )
type PlacementGroup ¶
type PlacementGroupType ¶
type PlacementGroupType string
const (
PlacementGroupTypeSpread PlacementGroupType = "spread"
)
type Server ¶
type Server struct { Id int `json:"id"` Name string `json:"name"` Created time.Time `json:"created"` Labels map[string]string `json:"labels"` Status ServerStatus `json:"status"` PublicNet ServerPublicNet `json:"public_net"` PrivateNet []ServerPrivateNet `json:"private_net"` ServerType *ServerType `json:"server_type"` Datacenter *Datacenter `json:"datacenter"` IncludedTraffic uint64 `json:"included_traffic"` OutgoingTraffic uint64 `json:"outgoing_traffic"` IngoingTraffic uint64 `json:"ingoing_traffic"` Iso *Iso `json:"iso"` Image *Image `json:"image"` PrimaryDiskSize int `json:"primary_disk_size"` PlacementGroup *PlacementGroup `json:"placement_group"` }
type ServerFirewallStatus ¶
type ServerFirewallStatus struct { Firewall Firewall `json:"firewall"` Status ServerFirewallStatusEnum `json:"status"` }
type ServerFirewallStatusEnum ¶
type ServerFirewallStatusEnum string
const ( ServerFirewallStatusPending ServerFirewallStatusEnum = "pending" ServerFirewallStatusApplied ServerFirewallStatusEnum = "applied" )
type ServerPrivateNet ¶
type ServerPublicNet ¶
type ServerPublicNet struct { IpV4 ServerPublicNetIpV4 `json:"ipv4"` IpV6 ServerPublicNetIpV6 `json:"ipv6"` FloatingIps []*FloatingIp `json:"floating_ips"` Firewalls []*ServerFirewallStatus `json:"firewalls"` }
type ServerPublicNetIpV4 ¶
type ServerPublicNetIpV6 ¶
type ServerStatus ¶
type ServerStatus string
const ( ServerStatusInitializing ServerStatus = "initializing" ServerStatusOff ServerStatus = "off" ServerStatusRunning ServerStatus = "running" ServerStatusStarting ServerStatus = "starting" ServerStatusStopping ServerStatus = "stopping" ServerStatusMigrating ServerStatus = "migrating" ServerStatusRebuilding ServerStatus = "rebuilding" ServerStatusDeleting ServerStatus = "deleting" ServerStatusUnknown ServerStatus = "unknown" )
type ServerType ¶
type ServerTypePrice ¶
type ServerTypePrice struct { Location string `json:"location"` PriceHourly ServerTypePriceValue `json:"price_hourly"` PriceMonthly ServerTypePriceValue `json:"price_monthly"` }
type ServerTypePriceValue ¶
type StorageType ¶
type StorageType string
const ( StorageTypeLocal StorageType = "local" StorageTypeCeph StorageType = "ceph" )
Click to show internal directories.
Click to hide internal directories.