Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

⚠️ Request for comments: Ability to use VCPUs #127

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions api/v1alpha1/ionoscloudmachine_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,9 @@
// AvailabilityZone is the availability zone where different cloud resources are created in.
type AvailabilityZone string

// ServerType specifies the type of server.
type ServerType string

const (
// AvailabilityZoneAuto automatically selects an availability zone.
AvailabilityZoneAuto AvailabilityZone = "AUTO"
Expand All @@ -83,6 +86,9 @@
AvailabilityZoneTwo AvailabilityZone = "ZONE_2"
// AvailabilityZoneThree zone 3.
AvailabilityZoneThree AvailabilityZone = "ZONE_3"

ServerTypeEnterprise = "ENTERPRISE"

Check failure on line 90 in api/v1alpha1/ionoscloudmachine_types.go

View workflow job for this annotation

GitHub Actions / lint

exported: exported const ServerTypeEnterprise should have comment (or a comment on this block) or be unexported (revive)
ServerTypeVCpu = "VCPU"
)

// String returns the string representation of the AvailabilityZone.
Expand Down Expand Up @@ -149,6 +155,13 @@
//+kubebuilder:validation:XValidation:rule=`self == "AUTO" || self.matches("((25[0-5]|(2[0-4]|1\\d|[1-9]|)\\d)\\.?\\b){4}$")`,message="failoverIP must be either 'AUTO' or a valid IPv4 address"
//+optional
FailoverIP *string `json:"failoverIP,omitempty"`

// Type is the server type of the VM. Can be either ENTERPRISE or VCPU.
//+kubebuilder:validation:XValidation:rule="self == oldSelf",message="type is immutable"
//+kubebuilder:validation:Enum=ENTERPRISE;VCPU
//+kubebuilder:default=ENTERPRISE
//+optional
Type ServerType `json:"type"`
}

// Networks contains a list of additional LAN IDs
Expand Down
Loading