scaleway

package
v1.26.5 Latest Latest
Warning

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

Go to latest
Published: Jul 16, 2023 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TagClusterName           = "kops.k8s.io/cluster"
	KopsUserAgentPrefix      = "kubernetes-kops/"
	TagInstanceGroup         = "instance-group"
	TagNameRolePrefix        = "k8s.io/role"
	TagNameEtcdClusterPrefix = "k8s.io/etcd"
	TagRoleMaster            = "control-plane"
	TagRoleVolume            = "volume"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type ScwAPITarget

type ScwAPITarget struct {
	Cloud ScwCloud
}

func NewScwAPITarget

func NewScwAPITarget(cloud ScwCloud) *ScwAPITarget

func (*ScwAPITarget) DefaultCheckExisting

func (t *ScwAPITarget) DefaultCheckExisting() bool

func (ScwAPITarget) Finish

func (s ScwAPITarget) Finish(taskMap map[string]fi.CloudupTask) error

func (ScwAPITarget) ProcessDeletions

func (s ScwAPITarget) ProcessDeletions() bool

type ScwCloud

type ScwCloud interface {
	fi.Cloud

	ClusterName(tags []string) string
	DNS() (dnsprovider.Interface, error)
	ProviderID() kops.CloudProviderID
	Region() string
	Zone() string

	IamService() *iam.API
	InstanceService() *instance.API

	DeleteGroup(group *cloudinstances.CloudInstanceGroup) error
	DeleteInstance(i *cloudinstances.CloudInstance) error
	DeregisterInstance(instance *cloudinstances.CloudInstance) error
	DetachInstance(instance *cloudinstances.CloudInstance) error
	FindClusterStatus(cluster *kops.Cluster) (*kops.ClusterStatus, error)
	FindVPCInfo(id string) (*fi.VPCInfo, error)
	GetApiIngressStatus(cluster *kops.Cluster) ([]fi.ApiIngressStatus, error)
	GetCloudGroups(cluster *kops.Cluster, instancegroups []*kops.InstanceGroup, warnUnmatched bool, nodes []v1.Node) (map[string]*cloudinstances.CloudInstanceGroup, error)

	GetClusterServers(clusterName string, serverName *string) ([]*instance.Server, error)
	GetClusterSSHKeys(clusterName string) ([]*iam.SSHKey, error)
	GetClusterVolumes(clusterName string) ([]*instance.Volume, error)

	DeleteServer(server *instance.Server) error
	DeleteSSHKey(sshkey *iam.SSHKey) error
	DeleteVolume(volume *instance.Volume) error
}

ScwCloud exposes all the interfaces required to operate on Scaleway resources

func NewScwCloud

func NewScwCloud(tags map[string]string) (ScwCloud, error)

NewScwCloud returns a Cloud with a Scaleway Client using the env vars SCW_ACCESS_KEY, SCW_SECRET_KEY, SCW_DEFAULT_PROJECT_ID, SCW_DEFAULT_REGION and SCW_DEFAULT_ZONE

Jump to

Keyboard shortcuts

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