azure

package
v1.20.1 Latest Latest
Warning

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

Go to latest
Published: May 12, 2021 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

Client is an Azure client.

func NewClient

func NewClient() (*Client, error)

NewClient returns a new Client.

func (*Client) GetInternalIP

func (c *Client) GetInternalIP() net.IP

GetInternalIP returns the internal IP of the VM queried from Instance Metadata Service. This function returns nil if no internal IP is found.

func (*Client) GetName

func (c *Client) GetName() string

GetName returns the name of the VM.

func (*Client) GetTags

func (c *Client) GetTags() (map[string]string, error)

GetTags returns the tags of the VM queried from Instance Metadata Service.

func (*Client) ListVMSSNetworkInterfaces

func (c *Client) ListVMSSNetworkInterfaces(ctx context.Context, vmScaleSetName string) ([]network.Interface, error)

ListVMSSNetworkInterfaces returns the interfaces that the specified VM ScaleSet has.

func (*Client) ListVMScaleSets

func (c *Client) ListVMScaleSets(ctx context.Context) ([]compute.VirtualMachineScaleSet, error)

ListVMScaleSets returns VM ScaleSets in the resource group.

type SeedProvider

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

SeedProvider is an Azure implementation of gossip.SeedProvider.

func NewSeedProvider

func NewSeedProvider(client client, tags map[string]string) (*SeedProvider, error)

NewSeedProvider returns a new SeedProvider.

func (*SeedProvider) GetSeeds

func (p *SeedProvider) GetSeeds() ([]string, error)

GetSeeds returns a slice of strings used as seeds of Gossip. This follows the implementation of AWS and creates seeds from private IPs of VMs in the cluster.

Jump to

Keyboard shortcuts

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