From 562f16fa49ef05c6a5fe1555a29c9bd8ebbfda96 Mon Sep 17 00:00:00 2001 From: SDK Generator Bot Date: Thu, 1 Oct 2026 15:07:01 +0000 Subject: [PATCH] Generate ske --- services/ske/go.mod | 2 +- services/ske/go.sum | 4 +- services/ske/model_access_scope.go | 2 +- services/ske/model_cluster_status.go | 118 +++++++++++++ services/ske/model_cluster_status_state.go | 2 +- services/ske/model_cri.go | 58 ++++++ services/ske/model_kata.go | 150 ++++++++++++++++ services/ske/model_kata_test.go | 11 ++ services/ske/model_maintenance.go | 51 +++--- services/ske/model_network.go | 118 +++++++++++++ services/ske/oas_commit | 2 +- .../ske/v1api/model_cluster_status_state.go | 2 +- services/ske/v1api/model_maintenance.go | 91 +++++----- services/ske/v2api/model_access_scope.go | 2 +- services/ske/v2api/model_cluster_status.go | 76 ++++++++ .../ske/v2api/model_cluster_status_state.go | 2 +- services/ske/v2api/model_cri.go | 37 ++++ services/ske/v2api/model_kata.go | 167 ++++++++++++++++++ services/ske/v2api/model_maintenance.go | 91 +++++----- services/ske/v2api/model_network.go | 82 ++++++++- 20 files changed, 938 insertions(+), 130 deletions(-) create mode 100644 services/ske/model_kata.go create mode 100644 services/ske/model_kata_test.go create mode 100644 services/ske/v2api/model_kata.go diff --git a/services/ske/go.mod b/services/ske/go.mod index 2588a6f723..f3d49c8d9f 100644 --- a/services/ske/go.mod +++ b/services/ske/go.mod @@ -4,7 +4,7 @@ go 1.25 require ( github.com/google/go-cmp v0.7.0 - github.com/stackitcloud/stackit-sdk-go/core v0.27.0 + github.com/stackitcloud/stackit-sdk-go/core v0.27.1 ) require ( diff --git a/services/ske/go.sum b/services/ske/go.sum index 042f4a71a5..5bae1d1250 100644 --- a/services/ske/go.sum +++ b/services/ske/go.sum @@ -4,5 +4,5 @@ github.com/google/go-cmp v0.7.0 h1:wk8382ETsv4JYUZwIsn6YpYiWiBsYLSJiTsyBybVuN8= github.com/google/go-cmp v0.7.0/go.mod h1:pXiqmnSA92OHEEa9HXL2W4E7lf9JzCmGVUdgjX3N/iU= github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0= github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/stackitcloud/stackit-sdk-go/core v0.27.0 h1:7lc6qStcFDFf8zHP4ORPa9joybw+Sa2LtB6BVjKQ+ek= -github.com/stackitcloud/stackit-sdk-go/core v0.27.0/go.mod h1:WU1hhxnjXw2EV7CYa1nlEvNpMiRY6CvmIOaHuL3pOaA= +github.com/stackitcloud/stackit-sdk-go/core v0.27.1 h1:k7SrqqMoHjkvHbx6n6nV3Lt51itp8nNplht6vGHkPhw= +github.com/stackitcloud/stackit-sdk-go/core v0.27.1/go.mod h1:WU1hhxnjXw2EV7CYa1nlEvNpMiRY6CvmIOaHuL3pOaA= diff --git a/services/ske/model_access_scope.go b/services/ske/model_access_scope.go index b075ae8689..797407b1a0 100644 --- a/services/ske/model_access_scope.go +++ b/services/ske/model_access_scope.go @@ -16,7 +16,7 @@ import ( "fmt" ) -// AccessScope The access scope of the Control Plane. It defines if the Kubernetes control plane is public or only available inside a STACKIT Network Area. This field is immutable. ⚠️ Note: This feature is in private preview. Supplying this object is only permitted for enabled accounts. If your account does not have access, the request will be rejected. +// AccessScope The access scope of the Control Plane. It defines if the Kubernetes control plane is public or only available inside a STACKIT Network Area. ⚠️ Warning: Changing the access scope on an existing cluster directly impacts its network exposure (e.g., making a private cluster publicly accessible) ⚠️ Note: This feature is in private preview. Supplying this object is only permitted for enabled accounts. If your account does not have access, the request will be rejected. // Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead type AccessScope string diff --git a/services/ske/model_cluster_status.go b/services/ske/model_cluster_status.go index d3eefdf826..c9974a7fab 100644 --- a/services/ske/model_cluster_status.go +++ b/services/ske/model_cluster_status.go @@ -262,6 +262,33 @@ type ClusterStatusGetIdentityArgType = string // Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead type ClusterStatusGetIdentityRetType = string +/* + types and functions for nodeAddressRanges +*/ + +// isArray +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ClusterStatusGetNodeAddressRangesAttributeType = *[]string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ClusterStatusGetNodeAddressRangesArgType = []string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ClusterStatusGetNodeAddressRangesRetType = []string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func getClusterStatusGetNodeAddressRangesAttributeTypeOk(arg ClusterStatusGetNodeAddressRangesAttributeType) (ret ClusterStatusGetNodeAddressRangesRetType, ok bool) { + if arg == nil { + return ret, false + } + return *arg, true +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func setClusterStatusGetNodeAddressRangesAttributeType(arg *ClusterStatusGetNodeAddressRangesAttributeType, val ClusterStatusGetNodeAddressRangesRetType) { + *arg = &val +} + /* types and functions for podAddressRanges */ @@ -316,6 +343,33 @@ type ClusterStatusGetServiceAccountIssuerArgType = string // Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead type ClusterStatusGetServiceAccountIssuerRetType = string +/* + types and functions for serviceAddressRanges +*/ + +// isArray +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ClusterStatusGetServiceAddressRangesAttributeType = *[]string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ClusterStatusGetServiceAddressRangesArgType = []string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ClusterStatusGetServiceAddressRangesRetType = []string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func getClusterStatusGetServiceAddressRangesAttributeTypeOk(arg ClusterStatusGetServiceAddressRangesAttributeType) (ret ClusterStatusGetServiceAddressRangesRetType, ok bool) { + if arg == nil { + return ret, false + } + return *arg, true +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func setClusterStatusGetServiceAddressRangesAttributeType(arg *ClusterStatusGetServiceAddressRangesAttributeType, val ClusterStatusGetServiceAddressRangesRetType) { + *arg = &val +} + // ClusterStatus struct for ClusterStatus // Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead type ClusterStatus struct { @@ -330,9 +384,13 @@ type ClusterStatus struct { Expiration ClusterStatusGetExpirationAttributeType `json:"expiration,omitempty"` Hibernated ClusterStatusgetHibernatedAttributeType `json:"hibernated,omitempty"` Identity ClusterStatusGetIdentityAttributeType `json:"identity,omitempty"` + // The network ranges (in CIDR notation) used by nodes of the cluster. + NodeAddressRanges ClusterStatusGetNodeAddressRangesAttributeType `json:"nodeAddressRanges,omitempty"` // The network ranges (in CIDR notation) used by pods of the cluster. PodAddressRanges ClusterStatusGetPodAddressRangesAttributeType `json:"podAddressRanges,omitempty"` ServiceAccountIssuer ClusterStatusGetServiceAccountIssuerAttributeType `json:"serviceAccountIssuer,omitempty"` + // The network ranges (in CIDR notation) used by services of the cluster. + ServiceAddressRanges ClusterStatusGetServiceAddressRangesAttributeType `json:"serviceAddressRanges,omitempty"` } // NewClusterStatus instantiates a new ClusterStatus object @@ -597,6 +655,33 @@ func (o *ClusterStatus) SetIdentity(v ClusterStatusGetIdentityRetType) { setClusterStatusGetIdentityAttributeType(&o.Identity, v) } +// GetNodeAddressRanges returns the NodeAddressRanges field value if set, zero value otherwise. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *ClusterStatus) GetNodeAddressRanges() (res ClusterStatusGetNodeAddressRangesRetType) { + res, _ = o.GetNodeAddressRangesOk() + return +} + +// GetNodeAddressRangesOk returns a tuple with the NodeAddressRanges field value if set, nil otherwise +// and a boolean to check if the value has been set. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *ClusterStatus) GetNodeAddressRangesOk() (ret ClusterStatusGetNodeAddressRangesRetType, ok bool) { + return getClusterStatusGetNodeAddressRangesAttributeTypeOk(o.NodeAddressRanges) +} + +// HasNodeAddressRanges returns a boolean if a field has been set. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *ClusterStatus) HasNodeAddressRanges() bool { + _, ok := o.GetNodeAddressRangesOk() + return ok +} + +// SetNodeAddressRanges gets a reference to the given []string and assigns it to the NodeAddressRanges field. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *ClusterStatus) SetNodeAddressRanges(v ClusterStatusGetNodeAddressRangesRetType) { + setClusterStatusGetNodeAddressRangesAttributeType(&o.NodeAddressRanges, v) +} + // GetPodAddressRanges returns the PodAddressRanges field value if set, zero value otherwise. // Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead func (o *ClusterStatus) GetPodAddressRanges() (res ClusterStatusGetPodAddressRangesRetType) { @@ -651,6 +736,33 @@ func (o *ClusterStatus) SetServiceAccountIssuer(v ClusterStatusGetServiceAccount setClusterStatusGetServiceAccountIssuerAttributeType(&o.ServiceAccountIssuer, v) } +// GetServiceAddressRanges returns the ServiceAddressRanges field value if set, zero value otherwise. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *ClusterStatus) GetServiceAddressRanges() (res ClusterStatusGetServiceAddressRangesRetType) { + res, _ = o.GetServiceAddressRangesOk() + return +} + +// GetServiceAddressRangesOk returns a tuple with the ServiceAddressRanges field value if set, nil otherwise +// and a boolean to check if the value has been set. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *ClusterStatus) GetServiceAddressRangesOk() (ret ClusterStatusGetServiceAddressRangesRetType, ok bool) { + return getClusterStatusGetServiceAddressRangesAttributeTypeOk(o.ServiceAddressRanges) +} + +// HasServiceAddressRanges returns a boolean if a field has been set. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *ClusterStatus) HasServiceAddressRanges() bool { + _, ok := o.GetServiceAddressRangesOk() + return ok +} + +// SetServiceAddressRanges gets a reference to the given []string and assigns it to the ServiceAddressRanges field. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *ClusterStatus) SetServiceAddressRanges(v ClusterStatusGetServiceAddressRangesRetType) { + setClusterStatusGetServiceAddressRangesAttributeType(&o.ServiceAddressRanges, v) +} + // Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead func (o ClusterStatus) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} @@ -681,12 +793,18 @@ func (o ClusterStatus) ToMap() (map[string]interface{}, error) { if val, ok := getClusterStatusGetIdentityAttributeTypeOk(o.Identity); ok { toSerialize["Identity"] = val } + if val, ok := getClusterStatusGetNodeAddressRangesAttributeTypeOk(o.NodeAddressRanges); ok { + toSerialize["NodeAddressRanges"] = val + } if val, ok := getClusterStatusGetPodAddressRangesAttributeTypeOk(o.PodAddressRanges); ok { toSerialize["PodAddressRanges"] = val } if val, ok := getClusterStatusGetServiceAccountIssuerAttributeTypeOk(o.ServiceAccountIssuer); ok { toSerialize["ServiceAccountIssuer"] = val } + if val, ok := getClusterStatusGetServiceAddressRangesAttributeTypeOk(o.ServiceAddressRanges); ok { + toSerialize["ServiceAddressRanges"] = val + } return toSerialize, nil } diff --git a/services/ske/model_cluster_status_state.go b/services/ske/model_cluster_status_state.go index 5ec3af0bd8..89af29e0d2 100644 --- a/services/ske/model_cluster_status_state.go +++ b/services/ske/model_cluster_status_state.go @@ -16,7 +16,7 @@ import ( "fmt" ) -// ClusterStatusState the model 'ClusterStatusState' +// ClusterStatusState ClusterStatusState holds information about the current state of the Cluster // Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead type ClusterStatusState string diff --git a/services/ske/model_cri.go b/services/ske/model_cri.go index e6dc83e29e..c6e5b6554a 100644 --- a/services/ske/model_cri.go +++ b/services/ske/model_cri.go @@ -19,6 +19,33 @@ import ( // checks if the CRI type satisfies the MappedNullable interface at compile time var _ MappedNullable = &CRI{} +/* + types and functions for kata +*/ + +// isModel +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type CRIGetKataAttributeType = *Kata + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type CRIGetKataArgType = Kata + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type CRIGetKataRetType = Kata + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func getCRIGetKataAttributeTypeOk(arg CRIGetKataAttributeType) (ret CRIGetKataRetType, ok bool) { + if arg == nil { + return ret, false + } + return *arg, true +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func setCRIGetKataAttributeType(arg *CRIGetKataAttributeType, val CRIGetKataRetType) { + *arg = &val +} + /* types and functions for name */ @@ -166,6 +193,7 @@ func setCRIGetNameAttributeType(arg *CRIGetNameAttributeType, val CRIGetNameRetT // CRI struct for CRI // Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead type CRI struct { + Kata CRIGetKataAttributeType `json:"kata,omitempty"` Name CRIGetNameAttributeType `json:"name,omitempty"` } @@ -188,6 +216,33 @@ func NewCRIWithDefaults() *CRI { return &this } +// GetKata returns the Kata field value if set, zero value otherwise. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *CRI) GetKata() (res CRIGetKataRetType) { + res, _ = o.GetKataOk() + return +} + +// GetKataOk returns a tuple with the Kata field value if set, nil otherwise +// and a boolean to check if the value has been set. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *CRI) GetKataOk() (ret CRIGetKataRetType, ok bool) { + return getCRIGetKataAttributeTypeOk(o.Kata) +} + +// HasKata returns a boolean if a field has been set. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *CRI) HasKata() bool { + _, ok := o.GetKataOk() + return ok +} + +// SetKata gets a reference to the given Kata and assigns it to the Kata field. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *CRI) SetKata(v CRIGetKataRetType) { + setCRIGetKataAttributeType(&o.Kata, v) +} + // GetName returns the Name field value if set, zero value otherwise. // Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead func (o *CRI) GetName() (res CRIGetNameRetType) { @@ -218,6 +273,9 @@ func (o *CRI) SetName(v CRIGetNameRetType) { // Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead func (o CRI) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} + if val, ok := getCRIGetKataAttributeTypeOk(o.Kata); ok { + toSerialize["Kata"] = val + } if val, ok := getCRIGetNameAttributeTypeOk(o.Name); ok { toSerialize["Name"] = val } diff --git a/services/ske/model_kata.go b/services/ske/model_kata.go new file mode 100644 index 0000000000..87af65dfed --- /dev/null +++ b/services/ske/model_kata.go @@ -0,0 +1,150 @@ +/* +STACKIT Kubernetes Engine API + +The SKE API provides endpoints to create, update or delete clusters within STACKIT projects and to trigger further cluster management tasks. + +API version: 2.0 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +package ske + +import ( + "encoding/json" +) + +// checks if the Kata type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &Kata{} + +/* + types and functions for enabled +*/ + +// isBoolean +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type KatagetEnabledAttributeType = *bool + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type KatagetEnabledArgType = bool + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type KatagetEnabledRetType = bool + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func getKatagetEnabledAttributeTypeOk(arg KatagetEnabledAttributeType) (ret KatagetEnabledRetType, ok bool) { + if arg == nil { + return ret, false + } + return *arg, true +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func setKatagetEnabledAttributeType(arg *KatagetEnabledAttributeType, val KatagetEnabledRetType) { + *arg = &val +} + +// Kata struct for Kata +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type Kata struct { + // Enable workload isolation via Kata Containers for pods scheduled on this node pool. ⚠️ Note: This feature is in private preview. Enabling is only possible for enabled accounts. Otherwise the request will be rejected. + // REQUIRED + Enabled KatagetEnabledAttributeType `json:"enabled" required:"true"` +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type _Kata Kata + +// NewKata instantiates a new Kata object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func NewKata(enabled KatagetEnabledArgType) *Kata { + this := Kata{} + setKatagetEnabledAttributeType(&this.Enabled, enabled) + return &this +} + +// NewKataWithDefaults instantiates a new Kata object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func NewKataWithDefaults() *Kata { + this := Kata{} + return &this +} + +// GetEnabled returns the Enabled field value +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *Kata) GetEnabled() (ret KatagetEnabledRetType) { + ret, _ = o.GetEnabledOk() + return ret +} + +// GetEnabledOk returns a tuple with the Enabled field value +// and a boolean to check if the value has been set. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *Kata) GetEnabledOk() (ret KatagetEnabledRetType, ok bool) { + return getKatagetEnabledAttributeTypeOk(o.Enabled) +} + +// SetEnabled sets field value +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *Kata) SetEnabled(v KatagetEnabledRetType) { + setKatagetEnabledAttributeType(&o.Enabled, v) +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o Kata) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if val, ok := getKatagetEnabledAttributeTypeOk(o.Enabled); ok { + toSerialize["Enabled"] = val + } + return toSerialize, nil +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type NullableKata struct { + value *Kata + isSet bool +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (v NullableKata) Get() *Kata { + return v.value +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (v *NullableKata) Set(val *Kata) { + v.value = val + v.isSet = true +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (v NullableKata) IsSet() bool { + return v.isSet +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (v *NullableKata) Unset() { + v.value = nil + v.isSet = false +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func NewNullableKata(val *Kata) *NullableKata { + return &NullableKata{value: val, isSet: true} +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (v NullableKata) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (v *NullableKata) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/ske/model_kata_test.go b/services/ske/model_kata_test.go new file mode 100644 index 0000000000..be50da75a4 --- /dev/null +++ b/services/ske/model_kata_test.go @@ -0,0 +1,11 @@ +/* +STACKIT Kubernetes Engine API + +The SKE API provides endpoints to create, update or delete clusters within STACKIT projects and to trigger further cluster management tasks. + +API version: 2.0 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package ske diff --git a/services/ske/model_maintenance.go b/services/ske/model_maintenance.go index ecaa519d4b..3c1e99e8c2 100644 --- a/services/ske/model_maintenance.go +++ b/services/ske/model_maintenance.go @@ -75,24 +75,17 @@ func setMaintenanceGetTimeWindowAttributeType(arg *MaintenanceGetTimeWindowAttri // Maintenance struct for Maintenance // Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead type Maintenance struct { - // REQUIRED - AutoUpdate MaintenanceGetAutoUpdateAttributeType `json:"autoUpdate" required:"true"` - // REQUIRED - TimeWindow MaintenanceGetTimeWindowAttributeType `json:"timeWindow" required:"true"` + AutoUpdate MaintenanceGetAutoUpdateAttributeType `json:"autoUpdate,omitempty"` + TimeWindow MaintenanceGetTimeWindowAttributeType `json:"timeWindow,omitempty"` } -// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead -type _Maintenance Maintenance - // NewMaintenance instantiates a new Maintenance object // This constructor will assign default values to properties that have it defined, // and makes sure properties required by API are set, but the set of arguments // will change when the set of required properties is changed // Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead -func NewMaintenance(autoUpdate MaintenanceGetAutoUpdateArgType, timeWindow MaintenanceGetTimeWindowArgType) *Maintenance { +func NewMaintenance() *Maintenance { this := Maintenance{} - setMaintenanceGetAutoUpdateAttributeType(&this.AutoUpdate, autoUpdate) - setMaintenanceGetTimeWindowAttributeType(&this.TimeWindow, timeWindow) return &this } @@ -105,41 +98,55 @@ func NewMaintenanceWithDefaults() *Maintenance { return &this } -// GetAutoUpdate returns the AutoUpdate field value +// GetAutoUpdate returns the AutoUpdate field value if set, zero value otherwise. // Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead -func (o *Maintenance) GetAutoUpdate() (ret MaintenanceGetAutoUpdateRetType) { - ret, _ = o.GetAutoUpdateOk() - return ret +func (o *Maintenance) GetAutoUpdate() (res MaintenanceGetAutoUpdateRetType) { + res, _ = o.GetAutoUpdateOk() + return } -// GetAutoUpdateOk returns a tuple with the AutoUpdate field value +// GetAutoUpdateOk returns a tuple with the AutoUpdate field value if set, nil otherwise // and a boolean to check if the value has been set. // Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead func (o *Maintenance) GetAutoUpdateOk() (ret MaintenanceGetAutoUpdateRetType, ok bool) { return getMaintenanceGetAutoUpdateAttributeTypeOk(o.AutoUpdate) } -// SetAutoUpdate sets field value +// HasAutoUpdate returns a boolean if a field has been set. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *Maintenance) HasAutoUpdate() bool { + _, ok := o.GetAutoUpdateOk() + return ok +} + +// SetAutoUpdate gets a reference to the given MaintenanceAutoUpdate and assigns it to the AutoUpdate field. // Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead func (o *Maintenance) SetAutoUpdate(v MaintenanceGetAutoUpdateRetType) { setMaintenanceGetAutoUpdateAttributeType(&o.AutoUpdate, v) } -// GetTimeWindow returns the TimeWindow field value +// GetTimeWindow returns the TimeWindow field value if set, zero value otherwise. // Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead -func (o *Maintenance) GetTimeWindow() (ret MaintenanceGetTimeWindowRetType) { - ret, _ = o.GetTimeWindowOk() - return ret +func (o *Maintenance) GetTimeWindow() (res MaintenanceGetTimeWindowRetType) { + res, _ = o.GetTimeWindowOk() + return } -// GetTimeWindowOk returns a tuple with the TimeWindow field value +// GetTimeWindowOk returns a tuple with the TimeWindow field value if set, nil otherwise // and a boolean to check if the value has been set. // Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead func (o *Maintenance) GetTimeWindowOk() (ret MaintenanceGetTimeWindowRetType, ok bool) { return getMaintenanceGetTimeWindowAttributeTypeOk(o.TimeWindow) } -// SetTimeWindow sets field value +// HasTimeWindow returns a boolean if a field has been set. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *Maintenance) HasTimeWindow() bool { + _, ok := o.GetTimeWindowOk() + return ok +} + +// SetTimeWindow gets a reference to the given TimeWindow and assigns it to the TimeWindow field. // Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead func (o *Maintenance) SetTimeWindow(v MaintenanceGetTimeWindowRetType) { setMaintenanceGetTimeWindowAttributeType(&o.TimeWindow, v) diff --git a/services/ske/model_network.go b/services/ske/model_network.go index f2d660dbaf..c54d2aa0d9 100644 --- a/services/ske/model_network.go +++ b/services/ske/model_network.go @@ -99,12 +99,70 @@ type NetworkGetIdArgType = string // Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead type NetworkGetIdRetType = string +/* + types and functions for podAddressRanges +*/ + +// isArray +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type NetworkGetPodAddressRangesAttributeType = *[]string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type NetworkGetPodAddressRangesArgType = []string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type NetworkGetPodAddressRangesRetType = []string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func getNetworkGetPodAddressRangesAttributeTypeOk(arg NetworkGetPodAddressRangesAttributeType) (ret NetworkGetPodAddressRangesRetType, ok bool) { + if arg == nil { + return ret, false + } + return *arg, true +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func setNetworkGetPodAddressRangesAttributeType(arg *NetworkGetPodAddressRangesAttributeType, val NetworkGetPodAddressRangesRetType) { + *arg = &val +} + +/* + types and functions for serviceAddressRanges +*/ + +// isArray +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type NetworkGetServiceAddressRangesAttributeType = *[]string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type NetworkGetServiceAddressRangesArgType = []string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type NetworkGetServiceAddressRangesRetType = []string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func getNetworkGetServiceAddressRangesAttributeTypeOk(arg NetworkGetServiceAddressRangesAttributeType) (ret NetworkGetServiceAddressRangesRetType, ok bool) { + if arg == nil { + return ret, false + } + return *arg, true +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func setNetworkGetServiceAddressRangesAttributeType(arg *NetworkGetServiceAddressRangesAttributeType, val NetworkGetServiceAddressRangesRetType) { + *arg = &val +} + // Network struct for Network // Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead type Network struct { Cni NetworkGetCniAttributeType `json:"cni,omitempty"` ControlPlane NetworkGetControlPlaneAttributeType `json:"controlPlane,omitempty"` Id NetworkGetIdAttributeType `json:"id,omitempty"` + // PodAddressRanges contains the CIDRs that are used to allocate Pod IPs from. Currently only 1 range is allowed. Immutable after creation. + PodAddressRanges NetworkGetPodAddressRangesAttributeType `json:"podAddressRanges,omitempty"` + // ServiceAddressRanges contains the CIDRs that are used to allocate Service ClusterIPs from. Currently only 1 range is allowed. Immutable after creation. + ServiceAddressRanges NetworkGetServiceAddressRangesAttributeType `json:"serviceAddressRanges,omitempty"` } // NewNetwork instantiates a new Network object @@ -207,6 +265,60 @@ func (o *Network) SetId(v NetworkGetIdRetType) { setNetworkGetIdAttributeType(&o.Id, v) } +// GetPodAddressRanges returns the PodAddressRanges field value if set, zero value otherwise. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *Network) GetPodAddressRanges() (res NetworkGetPodAddressRangesRetType) { + res, _ = o.GetPodAddressRangesOk() + return +} + +// GetPodAddressRangesOk returns a tuple with the PodAddressRanges field value if set, nil otherwise +// and a boolean to check if the value has been set. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *Network) GetPodAddressRangesOk() (ret NetworkGetPodAddressRangesRetType, ok bool) { + return getNetworkGetPodAddressRangesAttributeTypeOk(o.PodAddressRanges) +} + +// HasPodAddressRanges returns a boolean if a field has been set. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *Network) HasPodAddressRanges() bool { + _, ok := o.GetPodAddressRangesOk() + return ok +} + +// SetPodAddressRanges gets a reference to the given []string and assigns it to the PodAddressRanges field. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *Network) SetPodAddressRanges(v NetworkGetPodAddressRangesRetType) { + setNetworkGetPodAddressRangesAttributeType(&o.PodAddressRanges, v) +} + +// GetServiceAddressRanges returns the ServiceAddressRanges field value if set, zero value otherwise. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *Network) GetServiceAddressRanges() (res NetworkGetServiceAddressRangesRetType) { + res, _ = o.GetServiceAddressRangesOk() + return +} + +// GetServiceAddressRangesOk returns a tuple with the ServiceAddressRanges field value if set, nil otherwise +// and a boolean to check if the value has been set. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *Network) GetServiceAddressRangesOk() (ret NetworkGetServiceAddressRangesRetType, ok bool) { + return getNetworkGetServiceAddressRangesAttributeTypeOk(o.ServiceAddressRanges) +} + +// HasServiceAddressRanges returns a boolean if a field has been set. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *Network) HasServiceAddressRanges() bool { + _, ok := o.GetServiceAddressRangesOk() + return ok +} + +// SetServiceAddressRanges gets a reference to the given []string and assigns it to the ServiceAddressRanges field. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *Network) SetServiceAddressRanges(v NetworkGetServiceAddressRangesRetType) { + setNetworkGetServiceAddressRangesAttributeType(&o.ServiceAddressRanges, v) +} + // Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead func (o Network) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} @@ -219,6 +331,12 @@ func (o Network) ToMap() (map[string]interface{}, error) { if val, ok := getNetworkGetIdAttributeTypeOk(o.Id); ok { toSerialize["Id"] = val } + if val, ok := getNetworkGetPodAddressRangesAttributeTypeOk(o.PodAddressRanges); ok { + toSerialize["PodAddressRanges"] = val + } + if val, ok := getNetworkGetServiceAddressRangesAttributeTypeOk(o.ServiceAddressRanges); ok { + toSerialize["ServiceAddressRanges"] = val + } return toSerialize, nil } diff --git a/services/ske/oas_commit b/services/ske/oas_commit index 69bfa80b38..2ea49f464d 100644 --- a/services/ske/oas_commit +++ b/services/ske/oas_commit @@ -1 +1 @@ -864bdad12a54f612df8fcdb6e41dd2933e94c3af +348a79bbb21981a9b864e9b0636f56624df5f55c diff --git a/services/ske/v1api/model_cluster_status_state.go b/services/ske/v1api/model_cluster_status_state.go index 87ac8357ee..99416d4943 100644 --- a/services/ske/v1api/model_cluster_status_state.go +++ b/services/ske/v1api/model_cluster_status_state.go @@ -15,7 +15,7 @@ import ( "fmt" ) -// ClusterStatusState the model 'ClusterStatusState' +// ClusterStatusState aggregated state of the cluster type ClusterStatusState string // List of ClusterStatusState diff --git a/services/ske/v1api/model_maintenance.go b/services/ske/v1api/model_maintenance.go index 95f846af23..db1f76f07b 100644 --- a/services/ske/v1api/model_maintenance.go +++ b/services/ske/v1api/model_maintenance.go @@ -12,7 +12,6 @@ package v1api import ( "encoding/json" - "fmt" ) // checks if the Maintenance type satisfies the MappedNullable interface at compile time @@ -20,8 +19,8 @@ var _ MappedNullable = &Maintenance{} // Maintenance struct for Maintenance type Maintenance struct { - AutoUpdate MaintenanceAutoUpdate `json:"autoUpdate"` - TimeWindow TimeWindow `json:"timeWindow"` + AutoUpdate *MaintenanceAutoUpdate `json:"autoUpdate,omitempty"` + TimeWindow *TimeWindow `json:"timeWindow,omitempty"` AdditionalProperties map[string]interface{} } @@ -31,10 +30,8 @@ type _Maintenance Maintenance // This constructor will assign default values to properties that have it defined, // and makes sure properties required by API are set, but the set of arguments // will change when the set of required properties is changed -func NewMaintenance(autoUpdate MaintenanceAutoUpdate, timeWindow TimeWindow) *Maintenance { +func NewMaintenance() *Maintenance { this := Maintenance{} - this.AutoUpdate = autoUpdate - this.TimeWindow = timeWindow return &this } @@ -46,52 +43,68 @@ func NewMaintenanceWithDefaults() *Maintenance { return &this } -// GetAutoUpdate returns the AutoUpdate field value +// GetAutoUpdate returns the AutoUpdate field value if set, zero value otherwise. func (o *Maintenance) GetAutoUpdate() MaintenanceAutoUpdate { - if o == nil { + if o == nil || IsNil(o.AutoUpdate) { var ret MaintenanceAutoUpdate return ret } - - return o.AutoUpdate + return *o.AutoUpdate } -// GetAutoUpdateOk returns a tuple with the AutoUpdate field value +// GetAutoUpdateOk returns a tuple with the AutoUpdate field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *Maintenance) GetAutoUpdateOk() (*MaintenanceAutoUpdate, bool) { - if o == nil { + if o == nil || IsNil(o.AutoUpdate) { return nil, false } - return &o.AutoUpdate, true + return o.AutoUpdate, true +} + +// HasAutoUpdate returns a boolean if a field has been set. +func (o *Maintenance) HasAutoUpdate() bool { + if o != nil && !IsNil(o.AutoUpdate) { + return true + } + + return false } -// SetAutoUpdate sets field value +// SetAutoUpdate gets a reference to the given MaintenanceAutoUpdate and assigns it to the AutoUpdate field. func (o *Maintenance) SetAutoUpdate(v MaintenanceAutoUpdate) { - o.AutoUpdate = v + o.AutoUpdate = &v } -// GetTimeWindow returns the TimeWindow field value +// GetTimeWindow returns the TimeWindow field value if set, zero value otherwise. func (o *Maintenance) GetTimeWindow() TimeWindow { - if o == nil { + if o == nil || IsNil(o.TimeWindow) { var ret TimeWindow return ret } - - return o.TimeWindow + return *o.TimeWindow } -// GetTimeWindowOk returns a tuple with the TimeWindow field value +// GetTimeWindowOk returns a tuple with the TimeWindow field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *Maintenance) GetTimeWindowOk() (*TimeWindow, bool) { - if o == nil { + if o == nil || IsNil(o.TimeWindow) { return nil, false } - return &o.TimeWindow, true + return o.TimeWindow, true } -// SetTimeWindow sets field value +// HasTimeWindow returns a boolean if a field has been set. +func (o *Maintenance) HasTimeWindow() bool { + if o != nil && !IsNil(o.TimeWindow) { + return true + } + + return false +} + +// SetTimeWindow gets a reference to the given TimeWindow and assigns it to the TimeWindow field. func (o *Maintenance) SetTimeWindow(v TimeWindow) { - o.TimeWindow = v + o.TimeWindow = &v } func (o Maintenance) MarshalJSON() ([]byte, error) { @@ -104,8 +117,12 @@ func (o Maintenance) MarshalJSON() ([]byte, error) { func (o Maintenance) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} - toSerialize["autoUpdate"] = o.AutoUpdate - toSerialize["timeWindow"] = o.TimeWindow + if !IsNil(o.AutoUpdate) { + toSerialize["autoUpdate"] = o.AutoUpdate + } + if !IsNil(o.TimeWindow) { + toSerialize["timeWindow"] = o.TimeWindow + } for key, value := range o.AdditionalProperties { toSerialize[key] = value @@ -115,28 +132,6 @@ func (o Maintenance) ToMap() (map[string]interface{}, error) { } func (o *Maintenance) UnmarshalJSON(data []byte) (err error) { - // This validates that all required properties are included in the JSON object - // by unmarshalling the object into a generic map with string keys and checking - // that every required field exists as a key in the generic map. - requiredProperties := []string{ - "autoUpdate", - "timeWindow", - } - - allProperties := make(map[string]interface{}) - - err = json.Unmarshal(data, &allProperties) - - if err != nil { - return err - } - - for _, requiredProperty := range requiredProperties { - if _, exists := allProperties[requiredProperty]; !exists { - return fmt.Errorf("no value given for required property %v", requiredProperty) - } - } - varMaintenance := _Maintenance{} err = json.Unmarshal(data, &varMaintenance) diff --git a/services/ske/v2api/model_access_scope.go b/services/ske/v2api/model_access_scope.go index 02b7161970..1f53a154a4 100644 --- a/services/ske/v2api/model_access_scope.go +++ b/services/ske/v2api/model_access_scope.go @@ -15,7 +15,7 @@ import ( "fmt" ) -// AccessScope The access scope of the Control Plane. It defines if the Kubernetes control plane is public or only available inside a STACKIT Network Area. This field is immutable. ⚠️ Note: This feature is in private preview. Supplying this object is only permitted for enabled accounts. If your account does not have access, the request will be rejected. +// AccessScope The access scope of the Control Plane. It defines if the Kubernetes control plane is public or only available inside a STACKIT Network Area. ⚠️ Warning: Changing the access scope on an existing cluster directly impacts its network exposure (e.g., making a private cluster publicly accessible) ⚠️ Note: This feature is in private preview. Supplying this object is only permitted for enabled accounts. If your account does not have access, the request will be rejected. type AccessScope string // List of AccessScope diff --git a/services/ske/v2api/model_cluster_status.go b/services/ske/v2api/model_cluster_status.go index edffd4c095..d3634c6f62 100644 --- a/services/ske/v2api/model_cluster_status.go +++ b/services/ske/v2api/model_cluster_status.go @@ -31,9 +31,13 @@ type ClusterStatus struct { Expiration *ExpirationStatus `json:"expiration,omitempty"` Hibernated *bool `json:"hibernated,omitempty"` Identity *string `json:"identity,omitempty"` + // The network ranges (in CIDR notation) used by nodes of the cluster. + NodeAddressRanges []string `json:"nodeAddressRanges,omitempty"` // The network ranges (in CIDR notation) used by pods of the cluster. PodAddressRanges []string `json:"podAddressRanges,omitempty"` ServiceAccountIssuer *string `json:"serviceAccountIssuer,omitempty"` + // The network ranges (in CIDR notation) used by services of the cluster. + ServiceAddressRanges []string `json:"serviceAddressRanges,omitempty"` AdditionalProperties map[string]interface{} } @@ -344,6 +348,38 @@ func (o *ClusterStatus) SetIdentity(v string) { o.Identity = &v } +// GetNodeAddressRanges returns the NodeAddressRanges field value if set, zero value otherwise. +func (o *ClusterStatus) GetNodeAddressRanges() []string { + if o == nil || IsNil(o.NodeAddressRanges) { + var ret []string + return ret + } + return o.NodeAddressRanges +} + +// GetNodeAddressRangesOk returns a tuple with the NodeAddressRanges field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ClusterStatus) GetNodeAddressRangesOk() ([]string, bool) { + if o == nil || IsNil(o.NodeAddressRanges) { + return nil, false + } + return o.NodeAddressRanges, true +} + +// HasNodeAddressRanges returns a boolean if a field has been set. +func (o *ClusterStatus) HasNodeAddressRanges() bool { + if o != nil && !IsNil(o.NodeAddressRanges) { + return true + } + + return false +} + +// SetNodeAddressRanges gets a reference to the given []string and assigns it to the NodeAddressRanges field. +func (o *ClusterStatus) SetNodeAddressRanges(v []string) { + o.NodeAddressRanges = v +} + // GetPodAddressRanges returns the PodAddressRanges field value if set, zero value otherwise. func (o *ClusterStatus) GetPodAddressRanges() []string { if o == nil || IsNil(o.PodAddressRanges) { @@ -408,6 +444,38 @@ func (o *ClusterStatus) SetServiceAccountIssuer(v string) { o.ServiceAccountIssuer = &v } +// GetServiceAddressRanges returns the ServiceAddressRanges field value if set, zero value otherwise. +func (o *ClusterStatus) GetServiceAddressRanges() []string { + if o == nil || IsNil(o.ServiceAddressRanges) { + var ret []string + return ret + } + return o.ServiceAddressRanges +} + +// GetServiceAddressRangesOk returns a tuple with the ServiceAddressRanges field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ClusterStatus) GetServiceAddressRangesOk() ([]string, bool) { + if o == nil || IsNil(o.ServiceAddressRanges) { + return nil, false + } + return o.ServiceAddressRanges, true +} + +// HasServiceAddressRanges returns a boolean if a field has been set. +func (o *ClusterStatus) HasServiceAddressRanges() bool { + if o != nil && !IsNil(o.ServiceAddressRanges) { + return true + } + + return false +} + +// SetServiceAddressRanges gets a reference to the given []string and assigns it to the ServiceAddressRanges field. +func (o *ClusterStatus) SetServiceAddressRanges(v []string) { + o.ServiceAddressRanges = v +} + func (o ClusterStatus) MarshalJSON() ([]byte, error) { toSerialize, err := o.ToMap() if err != nil { @@ -445,12 +513,18 @@ func (o ClusterStatus) ToMap() (map[string]interface{}, error) { if !IsNil(o.Identity) { toSerialize["identity"] = o.Identity } + if !IsNil(o.NodeAddressRanges) { + toSerialize["nodeAddressRanges"] = o.NodeAddressRanges + } if !IsNil(o.PodAddressRanges) { toSerialize["podAddressRanges"] = o.PodAddressRanges } if !IsNil(o.ServiceAccountIssuer) { toSerialize["serviceAccountIssuer"] = o.ServiceAccountIssuer } + if !IsNil(o.ServiceAddressRanges) { + toSerialize["serviceAddressRanges"] = o.ServiceAddressRanges + } for key, value := range o.AdditionalProperties { toSerialize[key] = value @@ -482,8 +556,10 @@ func (o *ClusterStatus) UnmarshalJSON(data []byte) (err error) { delete(additionalProperties, "expiration") delete(additionalProperties, "hibernated") delete(additionalProperties, "identity") + delete(additionalProperties, "nodeAddressRanges") delete(additionalProperties, "podAddressRanges") delete(additionalProperties, "serviceAccountIssuer") + delete(additionalProperties, "serviceAddressRanges") o.AdditionalProperties = additionalProperties } diff --git a/services/ske/v2api/model_cluster_status_state.go b/services/ske/v2api/model_cluster_status_state.go index ba2b80086b..d31be23bf6 100644 --- a/services/ske/v2api/model_cluster_status_state.go +++ b/services/ske/v2api/model_cluster_status_state.go @@ -15,7 +15,7 @@ import ( "fmt" ) -// ClusterStatusState the model 'ClusterStatusState' +// ClusterStatusState ClusterStatusState holds information about the current state of the Cluster type ClusterStatusState string // List of ClusterStatusState diff --git a/services/ske/v2api/model_cri.go b/services/ske/v2api/model_cri.go index 75b553e396..77b9b30c61 100644 --- a/services/ske/v2api/model_cri.go +++ b/services/ske/v2api/model_cri.go @@ -19,6 +19,7 @@ var _ MappedNullable = &CRI{} // CRI struct for CRI type CRI struct { + Kata *Kata `json:"kata,omitempty"` Name *NameOfTheCriLibrary `json:"name,omitempty"` AdditionalProperties map[string]interface{} } @@ -42,6 +43,38 @@ func NewCRIWithDefaults() *CRI { return &this } +// GetKata returns the Kata field value if set, zero value otherwise. +func (o *CRI) GetKata() Kata { + if o == nil || IsNil(o.Kata) { + var ret Kata + return ret + } + return *o.Kata +} + +// GetKataOk returns a tuple with the Kata field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CRI) GetKataOk() (*Kata, bool) { + if o == nil || IsNil(o.Kata) { + return nil, false + } + return o.Kata, true +} + +// HasKata returns a boolean if a field has been set. +func (o *CRI) HasKata() bool { + if o != nil && !IsNil(o.Kata) { + return true + } + + return false +} + +// SetKata gets a reference to the given Kata and assigns it to the Kata field. +func (o *CRI) SetKata(v Kata) { + o.Kata = &v +} + // GetName returns the Name field value if set, zero value otherwise. func (o *CRI) GetName() NameOfTheCriLibrary { if o == nil || IsNil(o.Name) { @@ -84,6 +117,9 @@ func (o CRI) MarshalJSON() ([]byte, error) { func (o CRI) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} + if !IsNil(o.Kata) { + toSerialize["kata"] = o.Kata + } if !IsNil(o.Name) { toSerialize["name"] = o.Name } @@ -109,6 +145,7 @@ func (o *CRI) UnmarshalJSON(data []byte) (err error) { additionalProperties := make(map[string]interface{}) if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "kata") delete(additionalProperties, "name") o.AdditionalProperties = additionalProperties } diff --git a/services/ske/v2api/model_kata.go b/services/ske/v2api/model_kata.go new file mode 100644 index 0000000000..ca5a67eac0 --- /dev/null +++ b/services/ske/v2api/model_kata.go @@ -0,0 +1,167 @@ +/* +STACKIT Kubernetes Engine API + +The SKE API provides endpoints to create, update or delete clusters within STACKIT projects and to trigger further cluster management tasks. + +API version: 2.0 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package v2api + +import ( + "encoding/json" + "fmt" +) + +// checks if the Kata type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &Kata{} + +// Kata struct for Kata +type Kata struct { + // Enable workload isolation via Kata Containers for pods scheduled on this node pool. ⚠️ Note: This feature is in private preview. Enabling is only possible for enabled accounts. Otherwise the request will be rejected. + Enabled bool `json:"enabled"` + AdditionalProperties map[string]interface{} +} + +type _Kata Kata + +// NewKata instantiates a new Kata object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewKata(enabled bool) *Kata { + this := Kata{} + this.Enabled = enabled + return &this +} + +// NewKataWithDefaults instantiates a new Kata object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewKataWithDefaults() *Kata { + this := Kata{} + return &this +} + +// GetEnabled returns the Enabled field value +func (o *Kata) GetEnabled() bool { + if o == nil { + var ret bool + return ret + } + + return o.Enabled +} + +// GetEnabledOk returns a tuple with the Enabled field value +// and a boolean to check if the value has been set. +func (o *Kata) GetEnabledOk() (*bool, bool) { + if o == nil { + return nil, false + } + return &o.Enabled, true +} + +// SetEnabled sets field value +func (o *Kata) SetEnabled(v bool) { + o.Enabled = v +} + +func (o Kata) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o Kata) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["enabled"] = o.Enabled + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *Kata) UnmarshalJSON(data []byte) (err error) { + // This validates that all required properties are included in the JSON object + // by unmarshalling the object into a generic map with string keys and checking + // that every required field exists as a key in the generic map. + requiredProperties := []string{ + "enabled", + } + + allProperties := make(map[string]interface{}) + + err = json.Unmarshal(data, &allProperties) + + if err != nil { + return err + } + + for _, requiredProperty := range requiredProperties { + if _, exists := allProperties[requiredProperty]; !exists { + return fmt.Errorf("no value given for required property %v", requiredProperty) + } + } + + varKata := _Kata{} + + err = json.Unmarshal(data, &varKata) + + if err != nil { + return err + } + + *o = Kata(varKata) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "enabled") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableKata struct { + value *Kata + isSet bool +} + +func (v NullableKata) Get() *Kata { + return v.value +} + +func (v *NullableKata) Set(val *Kata) { + v.value = val + v.isSet = true +} + +func (v NullableKata) IsSet() bool { + return v.isSet +} + +func (v *NullableKata) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableKata(val *Kata) *NullableKata { + return &NullableKata{value: val, isSet: true} +} + +func (v NullableKata) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableKata) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/ske/v2api/model_maintenance.go b/services/ske/v2api/model_maintenance.go index b3870db1c3..2c12faf062 100644 --- a/services/ske/v2api/model_maintenance.go +++ b/services/ske/v2api/model_maintenance.go @@ -12,7 +12,6 @@ package v2api import ( "encoding/json" - "fmt" ) // checks if the Maintenance type satisfies the MappedNullable interface at compile time @@ -20,8 +19,8 @@ var _ MappedNullable = &Maintenance{} // Maintenance struct for Maintenance type Maintenance struct { - AutoUpdate MaintenanceAutoUpdate `json:"autoUpdate"` - TimeWindow TimeWindow `json:"timeWindow"` + AutoUpdate *MaintenanceAutoUpdate `json:"autoUpdate,omitempty"` + TimeWindow *TimeWindow `json:"timeWindow,omitempty"` AdditionalProperties map[string]interface{} } @@ -31,10 +30,8 @@ type _Maintenance Maintenance // This constructor will assign default values to properties that have it defined, // and makes sure properties required by API are set, but the set of arguments // will change when the set of required properties is changed -func NewMaintenance(autoUpdate MaintenanceAutoUpdate, timeWindow TimeWindow) *Maintenance { +func NewMaintenance() *Maintenance { this := Maintenance{} - this.AutoUpdate = autoUpdate - this.TimeWindow = timeWindow return &this } @@ -46,52 +43,68 @@ func NewMaintenanceWithDefaults() *Maintenance { return &this } -// GetAutoUpdate returns the AutoUpdate field value +// GetAutoUpdate returns the AutoUpdate field value if set, zero value otherwise. func (o *Maintenance) GetAutoUpdate() MaintenanceAutoUpdate { - if o == nil { + if o == nil || IsNil(o.AutoUpdate) { var ret MaintenanceAutoUpdate return ret } - - return o.AutoUpdate + return *o.AutoUpdate } -// GetAutoUpdateOk returns a tuple with the AutoUpdate field value +// GetAutoUpdateOk returns a tuple with the AutoUpdate field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *Maintenance) GetAutoUpdateOk() (*MaintenanceAutoUpdate, bool) { - if o == nil { + if o == nil || IsNil(o.AutoUpdate) { return nil, false } - return &o.AutoUpdate, true + return o.AutoUpdate, true +} + +// HasAutoUpdate returns a boolean if a field has been set. +func (o *Maintenance) HasAutoUpdate() bool { + if o != nil && !IsNil(o.AutoUpdate) { + return true + } + + return false } -// SetAutoUpdate sets field value +// SetAutoUpdate gets a reference to the given MaintenanceAutoUpdate and assigns it to the AutoUpdate field. func (o *Maintenance) SetAutoUpdate(v MaintenanceAutoUpdate) { - o.AutoUpdate = v + o.AutoUpdate = &v } -// GetTimeWindow returns the TimeWindow field value +// GetTimeWindow returns the TimeWindow field value if set, zero value otherwise. func (o *Maintenance) GetTimeWindow() TimeWindow { - if o == nil { + if o == nil || IsNil(o.TimeWindow) { var ret TimeWindow return ret } - - return o.TimeWindow + return *o.TimeWindow } -// GetTimeWindowOk returns a tuple with the TimeWindow field value +// GetTimeWindowOk returns a tuple with the TimeWindow field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *Maintenance) GetTimeWindowOk() (*TimeWindow, bool) { - if o == nil { + if o == nil || IsNil(o.TimeWindow) { return nil, false } - return &o.TimeWindow, true + return o.TimeWindow, true } -// SetTimeWindow sets field value +// HasTimeWindow returns a boolean if a field has been set. +func (o *Maintenance) HasTimeWindow() bool { + if o != nil && !IsNil(o.TimeWindow) { + return true + } + + return false +} + +// SetTimeWindow gets a reference to the given TimeWindow and assigns it to the TimeWindow field. func (o *Maintenance) SetTimeWindow(v TimeWindow) { - o.TimeWindow = v + o.TimeWindow = &v } func (o Maintenance) MarshalJSON() ([]byte, error) { @@ -104,8 +117,12 @@ func (o Maintenance) MarshalJSON() ([]byte, error) { func (o Maintenance) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} - toSerialize["autoUpdate"] = o.AutoUpdate - toSerialize["timeWindow"] = o.TimeWindow + if !IsNil(o.AutoUpdate) { + toSerialize["autoUpdate"] = o.AutoUpdate + } + if !IsNil(o.TimeWindow) { + toSerialize["timeWindow"] = o.TimeWindow + } for key, value := range o.AdditionalProperties { toSerialize[key] = value @@ -115,28 +132,6 @@ func (o Maintenance) ToMap() (map[string]interface{}, error) { } func (o *Maintenance) UnmarshalJSON(data []byte) (err error) { - // This validates that all required properties are included in the JSON object - // by unmarshalling the object into a generic map with string keys and checking - // that every required field exists as a key in the generic map. - requiredProperties := []string{ - "autoUpdate", - "timeWindow", - } - - allProperties := make(map[string]interface{}) - - err = json.Unmarshal(data, &allProperties) - - if err != nil { - return err - } - - for _, requiredProperty := range requiredProperties { - if _, exists := allProperties[requiredProperty]; !exists { - return fmt.Errorf("no value given for required property %v", requiredProperty) - } - } - varMaintenance := _Maintenance{} err = json.Unmarshal(data, &varMaintenance) diff --git a/services/ske/v2api/model_network.go b/services/ske/v2api/model_network.go index 19edd35f4b..ffc9d341e7 100644 --- a/services/ske/v2api/model_network.go +++ b/services/ske/v2api/model_network.go @@ -19,9 +19,13 @@ var _ MappedNullable = &Network{} // Network struct for Network type Network struct { - Cni *CNI `json:"cni,omitempty"` - ControlPlane *V2ControlPlaneNetwork `json:"controlPlane,omitempty"` - Id *string `json:"id,omitempty"` + Cni *CNI `json:"cni,omitempty"` + ControlPlane *V2ControlPlaneNetwork `json:"controlPlane,omitempty"` + Id *string `json:"id,omitempty"` + // PodAddressRanges contains the CIDRs that are used to allocate Pod IPs from. Currently only 1 range is allowed. Immutable after creation. + PodAddressRanges []string `json:"podAddressRanges,omitempty"` + // ServiceAddressRanges contains the CIDRs that are used to allocate Service ClusterIPs from. Currently only 1 range is allowed. Immutable after creation. + ServiceAddressRanges []string `json:"serviceAddressRanges,omitempty"` AdditionalProperties map[string]interface{} } @@ -140,6 +144,70 @@ func (o *Network) SetId(v string) { o.Id = &v } +// GetPodAddressRanges returns the PodAddressRanges field value if set, zero value otherwise. +func (o *Network) GetPodAddressRanges() []string { + if o == nil || IsNil(o.PodAddressRanges) { + var ret []string + return ret + } + return o.PodAddressRanges +} + +// GetPodAddressRangesOk returns a tuple with the PodAddressRanges field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Network) GetPodAddressRangesOk() ([]string, bool) { + if o == nil || IsNil(o.PodAddressRanges) { + return nil, false + } + return o.PodAddressRanges, true +} + +// HasPodAddressRanges returns a boolean if a field has been set. +func (o *Network) HasPodAddressRanges() bool { + if o != nil && !IsNil(o.PodAddressRanges) { + return true + } + + return false +} + +// SetPodAddressRanges gets a reference to the given []string and assigns it to the PodAddressRanges field. +func (o *Network) SetPodAddressRanges(v []string) { + o.PodAddressRanges = v +} + +// GetServiceAddressRanges returns the ServiceAddressRanges field value if set, zero value otherwise. +func (o *Network) GetServiceAddressRanges() []string { + if o == nil || IsNil(o.ServiceAddressRanges) { + var ret []string + return ret + } + return o.ServiceAddressRanges +} + +// GetServiceAddressRangesOk returns a tuple with the ServiceAddressRanges field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Network) GetServiceAddressRangesOk() ([]string, bool) { + if o == nil || IsNil(o.ServiceAddressRanges) { + return nil, false + } + return o.ServiceAddressRanges, true +} + +// HasServiceAddressRanges returns a boolean if a field has been set. +func (o *Network) HasServiceAddressRanges() bool { + if o != nil && !IsNil(o.ServiceAddressRanges) { + return true + } + + return false +} + +// SetServiceAddressRanges gets a reference to the given []string and assigns it to the ServiceAddressRanges field. +func (o *Network) SetServiceAddressRanges(v []string) { + o.ServiceAddressRanges = v +} + func (o Network) MarshalJSON() ([]byte, error) { toSerialize, err := o.ToMap() if err != nil { @@ -159,6 +227,12 @@ func (o Network) ToMap() (map[string]interface{}, error) { if !IsNil(o.Id) { toSerialize["id"] = o.Id } + if !IsNil(o.PodAddressRanges) { + toSerialize["podAddressRanges"] = o.PodAddressRanges + } + if !IsNil(o.ServiceAddressRanges) { + toSerialize["serviceAddressRanges"] = o.ServiceAddressRanges + } for key, value := range o.AdditionalProperties { toSerialize[key] = value @@ -184,6 +258,8 @@ func (o *Network) UnmarshalJSON(data []byte) (err error) { delete(additionalProperties, "cni") delete(additionalProperties, "controlPlane") delete(additionalProperties, "id") + delete(additionalProperties, "podAddressRanges") + delete(additionalProperties, "serviceAddressRanges") o.AdditionalProperties = additionalProperties }