client

package
Version: v0.17.3 Latest Latest
Warning

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

Go to latest
Published: Oct 1, 2021 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FindClusterFirewalls added in v0.15.1

func FindClusterFirewalls(client *metalgo.Driver, clusterTag, projectID string) ([]*models.V1FirewallResponse, error)

func GetEphemeralIPsFromCluster

func GetEphemeralIPsFromCluster(client *metalgo.Driver, projectID, clusterID string) ([]*models.V1IPResponse, []*models.V1IPResponse, error)

GetEphemeralIPsFromCluster return all ephemeral IPs for given project and cluster

func GetPrivateNetworkFromNodeNetwork

func GetPrivateNetworkFromNodeNetwork(client *metalgo.Driver, projectID string, nodeNetworkCIDR string) (*models.V1NetworkResponse, error)

GetPrivateNetworkFromNodeNetwork returns the private network that belongs to the given node network cidr and project.

func GetPrivateNetworksFromNodeNetwork

func GetPrivateNetworksFromNodeNetwork(client *metalgo.Driver, projectID string, nodeNetworkCIDR string) ([]*models.V1NetworkResponse, error)

GetPrivateNetworksFromNodeNetwork returns the private network that belongs to the given node network cidr and project.

func NewClient

func NewClient(ctx context.Context, k8sClient client.Client, endpoint string, secretRef *corev1.SecretReference) (*metalgo.Driver, error)

NewClient returns a new metal client with the provider credentials from a given secret reference.

func NewClientFromCredentials

func NewClientFromCredentials(endpoint string, credentials *metal.Credentials) (*metalgo.Driver, error)

NewClientFromCredentials returns a new metal client with the client constructed from the given credentials.

func ReadCredentialsFromSecretRef

func ReadCredentialsFromSecretRef(ctx context.Context, k8sClient client.Client, secretRef *corev1.SecretReference) (*metal.Credentials, error)

ReadCredentialsFromSecretRef returns metal credentials from the provider credentials from a given secret reference.

func UpdateIPInCluster

func UpdateIPInCluster(client *metalgo.Driver, ip *models.V1IPResponse, clusterID string) error

UpdateIPInCluster update the IP in the cluster to have only these tags left which are not from this cluster

Types

This section is empty.

Source Files

Jump to

Keyboard shortcuts

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