spectrocloud

package
v0.17.4 Latest Latest
Warning

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

Go to latest
Published: Feb 6, 2024 License: MPL-2.0 Imports: 36 Imported by: 0

Documentation

Index

Constants

View Source
const APPLIANCE_HEALTH_DESC = "The health of the appliance. Supported values are: 'healthy', and 'unhealthy'. "
View Source
const APPLIANCE_STATUS_DESC = "The status of the appliance. Supported values are: 'ready', 'in-use', and 'unpaired'. "
View Source
const ARCH_DESC = "The architecture of the appliance. Supported values are: 'amd64', and  'arm64'. "
View Source
const OverlordUID = "overlordUid"
View Source
const (
	PROJECT_NAME_NUANCE = "If  the `project` context is specified, the project name will sourced from the provider configuration parameter " +
		"[`project_name`](https://registry.terraform.io/providers/spectrocloud/spectrocloud/latest/docs#schema)."
)

make a constant string describing which project will be specified.

Variables

View Source
var (
	DefaultDiskType = "Standard_LRS"
	DefaultDiskSize = 60
	NameToCloudType = map[string]string{
		"spectrocloud_cluster_aks":          "aks",
		"spectrocloud_cluster_aws":          "aws",
		"spectrocloud_cluster_azure":        "azure",
		"spectrocloud_cluster_edge_native":  "edge-native",
		"spectrocloud_cluster_eks":          "eks",
		"spectrocloud_cluster_edge_vsphere": "edge-vsphere",
		"spectrocloud_cluster_gcp":          "gcp",
		"spectrocloud_cluster_maas":         "maas",
		"spectrocloud_cluster_openstack":    "openstack",
		"spectrocloud_cluster_tke":          "tke",
		"spectrocloud_cluster_vsphere":      "vsphere",
	}
)
View Source
var NodeMaintenanceLifecycleStates = []string{
	"Completed",
	"InProgress",
	"Initiated",
	"Failed",
}

Functions

func CommonHash added in v0.11.10

func CommonHash(nodePool map[string]interface{}) *bytes.Buffer

func ExpandAddVolumeOptions added in v0.13.2

func ExpandAddVolumeOptions(addVolumeOptions []interface{}) *models.V1VMAddVolumeOptions

func FlattenAddVolumeOptions added in v0.13.2

func FlattenAddVolumeOptions(addVolumeOptions *models.V1VMAddVolumeOptions) []interface{}

func FlattenAdditionalLabelsAndTaints added in v0.11.10

func FlattenAdditionalLabelsAndTaints(labels map[string]string, intaints []*models.V1Taint, oi map[string]interface{})

func FlattenControlPlaneAndRepaveInterval added in v0.11.10

func FlattenControlPlaneAndRepaveInterval(isControlPlane *bool, oi map[string]interface{}, nodeRepaveInterval int32)

func GetAddonDeploymentDiagPacks added in v0.10.7

func GetAddonDeploymentDiagPacks(d *schema.ResourceData, err error) ([]*models.V1PackManifestEntity, diag.Diagnostics, bool)

func GetBindings added in v0.10.2

func GetClusterGroupConfig added in v0.13.1

func GetClusterGroupConfig(clusterGroupLimitConfig *models.V1ClusterGroupLimitConfig, hostClusterConfig []*models.V1ClusterGroupHostClusterConfig, endpointType, values, k8Distro string) *models.V1ClusterGroupClustersConfig

func GetCommonAccount added in v0.17.2

func GetCommonAccount(d *schema.ResourceData, c *client.V1Client) error

func GetCommonCluster added in v0.16.0

func GetCommonCluster(d *schema.ResourceData, c *client.V1Client) error

func GetCommonClusterProfile added in v0.16.1

func GetCommonClusterProfile(d *schema.ResourceData, c *client.V1Client) error

func GetDiagPacks added in v0.8.2

func GpuConfigHash added in v0.11.10

func GpuConfigHash(config map[string]interface{}) string

func HashStringMap added in v0.6.1

func HashStringMap(v interface{}) string

func HashStringMapList added in v0.6.1

func HashStringMapList(v interface{}) string

func InstanceTypeHash added in v0.11.10

func InstanceTypeHash(ins map[string]interface{}) string

func IsMapSubset added in v0.10.10

func IsMapSubset[K, V comparable](m, sub map[K]V) bool

func IsRegex added in v0.10.1

func IsRegex(name string) bool

func New

func New(_ string) func() *schema.Provider

func ParseResourceID added in v0.16.1

func ParseResourceID(d *schema.ResourceData) (string, string, error)

func ReadCommonAttributes added in v0.16.0

func ReadCommonAttributes(d *schema.ResourceData) error

func ValidateCloudType added in v0.17.2

func ValidateCloudType(resourceName string, cluster *models.V1SpectroCluster) error

func ValidateContext added in v0.15.5

func ValidateContext(context string) error

func ValidateMachinePoolChange added in v0.14.0

func ValidateMachinePoolChange(oMPool interface{}, nMPool interface{}) (bool, error)

func ValidationNodeRepaveIntervalForControlPlane added in v0.11.10

func ValidationNodeRepaveIntervalForControlPlane(nodeRepaveInterval int) error

Types

type GetMaintenanceStatus added in v0.11.10

type GetMaintenanceStatus func(string, string, string, string) (*models.V1MachineMaintenanceStatus, error)

type GetNodeStatusMap added in v0.11.10

type GetNodeStatusMap func(string, string, string) (map[string]models.V1CloudMachineStatus, error)

type ResultStat added in v0.11.0

type ResultStat struct {
	CODE_MINUS_ONE      int
	CODE_NORMAL         int
	CODE_EXPECTED       int
	CODE_INTERNAL_ERROR int
}

type Retry added in v0.11.0

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

Source Files

Jump to

Keyboard shortcuts

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