Documentation ¶
Overview ¶
Package powervs contains Power VS-specific structures for installer configuration and management.
Index ¶
- Constants
- Variables
- func RegionFromZone(zone string) string
- func RegionShortNames() []string
- func VPCRegionForPowerVSRegion(region string) (string, error)
- func ValidateVPCRegion(region string) bool
- func ValidateZone(zone string) bool
- func ZoneNames() []string
- type MachinePool
- type Metadata
- type Platform
- type Region
Constants ¶
const Name string = "powervs"
Name is name for the Power VS platform.
Variables ¶
var Regions = map[string]Region{ "dal": { Description: "Dallas, USA", VPCRegion: "us-south", Zones: []string{"dal12"}, }, "eu-de": { Description: "Frankfurt, Germany", VPCRegion: "eu-de", Zones: []string{ "eu-de-1", "eu-de-2", }, }, "lon": { Description: "London, UK.", VPCRegion: "eu-gb", Zones: []string{ "lon04", "lon06", }, }, "mon": { Description: "Montreal, Canada", VPCRegion: "ca-tor", Zones: []string{"mon01"}, }, "osa": { Description: "Osaka, Japan", VPCRegion: "jp-osa", Zones: []string{"osa21"}, }, "syd": { Description: "Sydney, Australia", VPCRegion: "au-syd", Zones: []string{ "syd04", "syd05", }, }, "sao": { Description: "São Paulo, Brazil", VPCRegion: "br-sao", Zones: []string{"sao01"}, }, "tor": { Description: "Toronto, Canada", VPCRegion: "ca-tor", Zones: []string{"tor01"}, }, "tok": { Description: "Tokyo, Japan", VPCRegion: "jp-tok", Zones: []string{"tok04"}, }, "us-east": { Description: "Washington DC, USA", VPCRegion: "us-east", Zones: []string{"us-east"}, }, }
Regions holds the regions for IBM Power VS, and descriptions used during the survey.
Functions ¶
func RegionFromZone ¶
RegionFromZone returns the region name for a given zone name.
func RegionShortNames ¶
func RegionShortNames() []string
RegionShortNames returns the list of region names
func VPCRegionForPowerVSRegion ¶
VPCRegionForPowerVSRegion returns the VPC region for the specified PowerVS region.
func ValidateVPCRegion ¶
ValidateVPCRegion validates that given VPC region is known/tested.
func ValidateZone ¶
ValidateZone validates that the given zone is known/tested.
Types ¶
type MachinePool ¶
type MachinePool struct { // VolumeIDs is the list of volumes attached to the instance. // // +optional VolumeIDs []string `json:"volumeIDs,omitempty"` // memoryGiB is the size of a virtual machine's memory, in GiB. // // +optional MemoryGiB int32 `json:"memoryGiB,omitempty"` // Processors defines the processing units for the instance. // // +optional Processors intstr.IntOrString `json:"processors,omitempty"` // ProcType defines the processor sharing model for the instance. // Must be one of {Capped, Dedicated, Shared}. // // +kubebuilder:validation:Enum:="Dedicated";"Shared";"Capped";"" // +optional ProcType machinev1.PowerVSProcessorType `json:"procType,omitempty"` // SysType defines the system type for instance. // // +optional SysType string `json:"sysType,omitempty"` }
MachinePool stores the configuration for a machine pool installed on IBM Power VS.
func (*MachinePool) Set ¶
func (a *MachinePool) Set(required *MachinePool)
Set stores values from required into a
type Metadata ¶
type Metadata struct { BaseDomain string `json:"BaseDomain"` CISInstanceCRN string `json:"cisInstanceCRN"` DNSInstanceCRN string `json:"dnsInstanceCRN"` PowerVSResourceGroup string `json:"powerVSResourceGroup"` Region string `json:"region"` VPCRegion string `json:"vpcRegion"` Zone string `json:"zone"` ServiceInstanceGUID string `json:"serviceInstanceID"` }
Metadata contains Power VS metadata (e.g. for uninstalling the cluster).
type Platform ¶
type Platform struct { // ServiceInstanceID is the ID of the Power IAAS instance created from the IBM Cloud Catalog ServiceInstanceID string `json:"serviceInstanceID"` // PowerVSResourceGroup is the resource group in which Power VS resources will be created. PowerVSResourceGroup string `json:"powervsResourceGroup"` // Region specifies the IBM Cloud colo region where the cluster will be created. Region string `json:"region,omitempty"` // Zone specifies the IBM Cloud colo region where the cluster will be created. // At this time, only single-zone clusters are supported. Zone string `json:"zone"` // VPCRegion specifies the IBM Cloud region in which to create VPC resources. // Leave unset to allow installer to select the closest VPC region. // // +optional VPCRegion string `json:"vpcRegion,omitempty"` // UserID is the login for the user's IBM Cloud account. UserID string `json:"userID"` // VPCName is the name of a pre-created VPC inside IBM Cloud. // // +optional VPCName string `json:"vpcName,omitempty"` // VPCSubnets specifies existing subnets (by ID) where cluster // resources will be created. Leave unset to have the installer // create subnets in a new VPC on your behalf. // // +optional VPCSubnets []string `json:"vpcSubnets,omitempty"` // PVSNetworkName specifies an existing network within the Power VS Service Instance. // // +optional PVSNetworkName string `json:"pvsNetworkName,omitempty"` // ClusterOSImage is a pre-created Power VS boot image that overrides the // default image for cluster nodes. // // +optional ClusterOSImage string `json:"clusterOSImage,omitempty"` // DefaultMachinePlatform is the default configuration used when // installing on Power VS for machine pools which do not define their own // platform configuration. // +optional DefaultMachinePlatform *MachinePool `json:"defaultMachinePlatform,omitempty"` // CloudConnctionName is the name of an existing Power VS Cloud connection. // If empty, one is created by the installer. // +optional CloudConnectionName string `json:"cloudConnectionName,omitempty"` }
Platform stores all the global configuration that all machinesets use.