cloud

package
v1.2.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 29, 2021 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AwsCloudInfo

type AwsCloudInfo struct {
	// contains filtered or unexported fields
}

func (*AwsCloudInfo) GetMainIPv4Address

func (a *AwsCloudInfo) GetMainIPv4Address() (string, error)

Get the main IP address used by itzo.

func (*AwsCloudInfo) GetPodIPv4Address

func (a *AwsCloudInfo) GetPodIPv4Address() (string, error)

Get the IP address assigned to the pod. We'll need something similar to this for each cloud.

type AzureCloudInfo

type AzureCloudInfo struct {
	// contains filtered or unexported fields
}

func (*AzureCloudInfo) GetMainIPv4Address

func (a *AzureCloudInfo) GetMainIPv4Address() (string, error)

Get the main IP address (first IP on the main interface).

func (*AzureCloudInfo) GetPodIPv4Address

func (a *AzureCloudInfo) GetPodIPv4Address() (string, error)

Get the IP address (second IP on the main interface) assigned to the pod.

type CloudInfo

type CloudInfo interface {
	GetPodIPv4Address() (string, error)
	GetMainIPv4Address() (string, error)
}

func NewAwsCloudInfo

func NewAwsCloudInfo() (CloudInfo, error)

func NewAzureCloudInfo

func NewAzureCloudInfo(url string) (CloudInfo, error)

func NewCloudInfo

func NewCloudInfo() (CloudInfo, error)

func NewGCECloudInfo

func NewGCECloudInfo() (CloudInfo, error)

type ComputeMetadata

type ComputeMetadata struct {
	AZEnvironment        string `json:"azEnvironment,omitempty"`
	SKU                  string `json:"sku,omitempty"`
	Name                 string `json:"name,omitempty"`
	Zone                 string `json:"zone,omitempty"`
	VMSize               string `json:"vmSize,omitempty"`
	OSType               string `json:"osType,omitempty"`
	Location             string `json:"location,omitempty"`
	PlatformFaultDomain  string `json:"platformFaultDomain,omitempty"`
	PlatformUpdateDomain string `json:"platformUpdateDomain,omitempty"`
	ResourceGroupName    string `json:"resourceGroupName,omitempty"`
	VMScaleSetName       string `json:"vmScaleSetName,omitempty"`
	SubscriptionID       string `json:"subscriptionId,omitempty"`
}

type GceCloudInfo

type GceCloudInfo struct {
	// contains filtered or unexported fields
}

func (*GceCloudInfo) GetMainIPv4Address

func (g *GceCloudInfo) GetMainIPv4Address() (string, error)

func (*GceCloudInfo) GetPodIPv4Address

func (g *GceCloudInfo) GetPodIPv4Address() (string, error)

type IPAddress

type IPAddress struct {
	PrivateIPAddress string `json:"privateIpAddress"`
	PublicIPAddress  string `json:"publicIpAddress"`
}

type InstanceMetadata

type InstanceMetadata struct {
	Compute *ComputeMetadata `json:"compute,omitempty"`
	Network *NetworkMetadata `json:"network,omitempty"`
}

InstanceMetadata represents instance information.

type NetworkData

type NetworkData struct {
	IPAddress []IPAddress `json:"ipAddress"`
	Subnet    []Subnet    `json:"subnet"`
}

type NetworkInterface

type NetworkInterface struct {
	IPv4       NetworkData `json:"ipv4"`
	IPv6       NetworkData `json:"ipv6"`
	MACAddress string      `json:"macAddress"`
}

type NetworkMetadata

type NetworkMetadata struct {
	Interface []NetworkInterface `json:"interface"`
}

type Subnet

type Subnet struct {
	Address string `json:"address"`
	Prefix  string `json:"prefix"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL