nscloud

package
v0.0.78 Latest Latest
Warning

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

Go to latest
Published: Nov 3, 2022 License: Apache-2.0 Imports: 38 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DefaultKeychain oci.Keychain = defaultKeychain{}
View Source
var File_internal_providers_nscloud_provider_proto protoreflect.FileDescriptor

Functions

func DestroyCluster

func DestroyCluster(ctx context.Context, clusterId string) error

func RegisterClusterProvider

func RegisterClusterProvider()

func RegisterRegistry

func RegisterRegistry()

func UserSSHKeys

func UserSSHKeys() (compute.Computable[[]string], error)

Types

type ClusterShape

type ClusterShape struct {
	VirtualCpu      int32 `json:"virtual_cpu,omitempty"`
	MemoryMegabytes int32 `json:"memory_megabytes,omitempty"`
}

type CreateClusterResult

type CreateClusterResult struct {
	ClusterId string
	Cluster   *KubernetesCluster
	Registry  *ImageRegistry
	Deadline  *time.Time
}

func CreateAndWaitCluster

func CreateAndWaitCluster(ctx context.Context, machineType string, ephemeral bool, purpose string) (*CreateClusterResult, error)

func WaitCluster

func WaitCluster(ctx context.Context, clusterId string) (*CreateClusterResult, error)

type CreateKubernetesClusterRequest

type CreateKubernetesClusterRequest struct {
	OpaqueUserAuth    []byte   `json:"opaque_user_auth,omitempty"`
	Ephemeral         bool     `json:"ephemeral,omitempty"`
	DocumentedPurpose string   `json:"documented_purpose,omitempty"`
	AuthorizedSshKeys []string `json:"authorized_ssh_keys,omitempty"`
	MachineType       string   `json:"machine_type,omitempty"`
}

type CreateKubernetesClusterResponse

type CreateKubernetesClusterResponse struct {
	Status    string             `json:"status,omitempty"`
	ClusterId string             `json:"cluster_id,omitempty"`
	Cluster   *KubernetesCluster `json:"cluster,omitempty"`
	Registry  *ImageRegistry     `json:"registry,omitempty"`
	Deadline  string             `json:"deadline,omitempty"`
}

type DestroyKubernetesClusterRequest

type DestroyKubernetesClusterRequest struct {
	OpaqueUserAuth []byte `json:"opaque_user_auth,omitempty"`
	ClusterId      string `json:"cluster_id,omitempty"`
}

type GetKubernetesClusterRequest

type GetKubernetesClusterRequest struct {
	OpaqueUserAuth []byte `json:"opaque_user_auth,omitempty"`
	ClusterId      string `json:"cluster_id,omitempty"`
}

type GetKubernetesClusterResponse

type GetKubernetesClusterResponse struct {
	Cluster  *KubernetesCluster `json:"cluster,omitempty"`
	Registry *ImageRegistry     `json:"registry,omitempty"`
	Deadline string             `json:"deadline,omitempty"`
}

type ImageRegistry

type ImageRegistry struct {
	EndpointAddress string `json:"endpoint_address,omitempty"`
}

type KubernetesCluster

type KubernetesCluster struct {
	ClusterId         string        `json:"cluster_id,omitempty"`
	Created           string        `json:"created,omitempty"`
	Deadline          string        `json:"deadline,omitempty"`
	SSHProxyEndpoint  string        `json:"ssh_proxy_endpoint,omitempty"`
	SshPrivateKey     []byte        `json:"ssh_private_key,omitempty"`
	DocumentedPurpose string        `json:"documented_purpose,omitempty"`
	Shape             *ClusterShape `json:"shape,omitempty"`

	EndpointAddress          string `json:"endpoint_address,omitempty"`
	CertificateAuthorityData []byte `json:"certificate_authority_data,omitempty"`
	ClientCertificateData    []byte `json:"client_certificate_data,omitempty"`
	ClientKeyData            []byte `json:"client_key_data,omitempty"`

	KubernetesDistribution string   `json:"kubernetes_distribution,omitempty"`
	Platform               []string `json:"platform,omitempty"`

	IngressDomain string `json:"ingress_domain,omitempty"`

	Label []*LabelEntry `json:"label,omitempty"`
}

func CreateCluster

func CreateCluster(ctx context.Context, machineType string, ephemeral bool, purpose string) (*KubernetesCluster, error)

func GetCluster

func GetCluster(ctx context.Context, clusterId string) (*KubernetesCluster, error)

type KubernetesClusterList

type KubernetesClusterList struct {
	Clusters []KubernetesCluster `json:"cluster"`
}

func ListClusters

func ListClusters(ctx context.Context) (*KubernetesClusterList, error)

type LabelEntry

type LabelEntry struct {
	Name  string `json:"name,omitempty"`
	Value string `json:"value,omitempty"`
}

type ListKubernetesClustersRequest

type ListKubernetesClustersRequest struct {
	OpaqueUserAuth []byte `json:"opaque_user_auth,omitempty"`
}

type PrebuiltCluster

type PrebuiltCluster struct {
	ClusterId        string `protobuf:"bytes,1,opt,name=cluster_id,json=clusterId,proto3" json:"cluster_id,omitempty"`
	SerializedConfig []byte `protobuf:"bytes,2,opt,name=serialized_config,json=serializedConfig,proto3" json:"serialized_config,omitempty"` // Deprecated, always fetched now.
	Ephemeral        bool   `protobuf:"varint,3,opt,name=ephemeral,proto3" json:"ephemeral,omitempty"`
	// contains filtered or unexported fields
}

func (*PrebuiltCluster) Descriptor deprecated

func (*PrebuiltCluster) Descriptor() ([]byte, []int)

Deprecated: Use PrebuiltCluster.ProtoReflect.Descriptor instead.

func (*PrebuiltCluster) GetClusterId

func (x *PrebuiltCluster) GetClusterId() string

func (*PrebuiltCluster) GetEphemeral

func (x *PrebuiltCluster) GetEphemeral() bool

func (*PrebuiltCluster) GetSerializedConfig

func (x *PrebuiltCluster) GetSerializedConfig() []byte

func (*PrebuiltCluster) ProtoMessage

func (*PrebuiltCluster) ProtoMessage()

func (*PrebuiltCluster) ProtoReflect

func (x *PrebuiltCluster) ProtoReflect() protoreflect.Message

func (*PrebuiltCluster) Reset

func (x *PrebuiltCluster) Reset()

func (*PrebuiltCluster) String

func (x *PrebuiltCluster) String() string

type StartCreateKubernetesClusterResponse

type StartCreateKubernetesClusterResponse struct {
	ClusterId       string             `json:"cluster_id,omitempty"`
	ClusterFragment *KubernetesCluster `json:"cluster_fragment,omitempty"`
}

type Token

type Token struct {
	Token string `json:"token"`
}

type WaitKubernetesClusterRequest

type WaitKubernetesClusterRequest struct {
	OpaqueUserAuth []byte `json:"opaque_user_auth,omitempty"`
	ClusterId      string `json:"cluster_id,omitempty"`
}

Jump to

Keyboard shortcuts

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