This repository has been archived by the owner on Dec 15, 2022. It is now read-only.
generated from crossplane-contrib/provider-jet-template
/
zz_instance_types.go
executable file
·311 lines (238 loc) · 12.7 KB
/
zz_instance_types.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
/*
Copyright 2021 The Crossplane Authors.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
// Code generated by terrajet. DO NOT EDIT.
package v1alpha2
import (
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/runtime/schema"
v1 "github.com/crossplane/crossplane-runtime/apis/common/v1"
)
type InstanceObservation struct {
CreateTime *string `json:"createTime,omitempty" tf:"create_time,omitempty"`
CurrentLocationID *string `json:"currentLocationId,omitempty" tf:"current_location_id,omitempty"`
Host *string `json:"host,omitempty" tf:"host,omitempty"`
ID *string `json:"id,omitempty" tf:"id,omitempty"`
Nodes []NodesObservation `json:"nodes,omitempty" tf:"nodes,omitempty"`
PersistenceIAMIdentity *string `json:"persistenceIamIdentity,omitempty" tf:"persistence_iam_identity,omitempty"`
Port *float64 `json:"port,omitempty" tf:"port,omitempty"`
ReadEndpoint *string `json:"readEndpoint,omitempty" tf:"read_endpoint,omitempty"`
ReadEndpointPort *float64 `json:"readEndpointPort,omitempty" tf:"read_endpoint_port,omitempty"`
ServerCACerts []ServerCACertsObservation `json:"serverCaCerts,omitempty" tf:"server_ca_certs,omitempty"`
}
type InstanceParameters struct {
// Only applicable to STANDARD_HA tier which protects the instance
// against zonal failures by provisioning it across two zones.
// If provided, it must be a different zone from the one provided in
// [locationId].
// +kubebuilder:validation:Optional
AlternativeLocationID *string `json:"alternativeLocationId,omitempty" tf:"alternative_location_id,omitempty"`
// Optional. Indicates whether OSS Redis AUTH is enabled for the
// instance. If set to "true" AUTH is enabled on the instance.
// Default value is "false" meaning AUTH is disabled.
// +kubebuilder:validation:Optional
AuthEnabled *bool `json:"authEnabled,omitempty" tf:"auth_enabled,omitempty"`
// The full name of the Google Compute Engine network to which the
// instance is connected. If left unspecified, the default network
// will be used.
// +kubebuilder:validation:Optional
AuthorizedNetwork *string `json:"authorizedNetwork,omitempty" tf:"authorized_network,omitempty"`
// The connection mode of the Redis instance. Default value: "DIRECT_PEERING" Possible values: ["DIRECT_PEERING", "PRIVATE_SERVICE_ACCESS"]
// +kubebuilder:validation:Optional
ConnectMode *string `json:"connectMode,omitempty" tf:"connect_mode,omitempty"`
// An arbitrary and optional user-provided name for the instance.
// +kubebuilder:validation:Optional
DisplayName *string `json:"displayName,omitempty" tf:"display_name,omitempty"`
// Resource labels to represent user provided metadata.
// +kubebuilder:validation:Optional
Labels map[string]*string `json:"labels,omitempty" tf:"labels,omitempty"`
// The zone where the instance will be provisioned. If not provided,
// the service will choose a zone for the instance. For STANDARD_HA tier,
// instances will be created across two zones for protection against
// zonal failures. If [alternativeLocationId] is also provided, it must
// be different from [locationId].
// +kubebuilder:validation:Optional
LocationID *string `json:"locationId,omitempty" tf:"location_id,omitempty"`
// Maintenance policy for an instance.
// +kubebuilder:validation:Optional
MaintenancePolicy []MaintenancePolicyParameters `json:"maintenancePolicy,omitempty" tf:"maintenance_policy,omitempty"`
// Upcoming maintenance schedule.
// +kubebuilder:validation:Optional
MaintenanceSchedule []MaintenanceScheduleParameters `json:"maintenanceSchedule,omitempty" tf:"maintenance_schedule,omitempty"`
// Redis memory size in GiB.
// +kubebuilder:validation:Required
MemorySizeGb *float64 `json:"memorySizeGb" tf:"memory_size_gb,omitempty"`
// +kubebuilder:validation:Optional
Project *string `json:"project,omitempty" tf:"project,omitempty"`
// Optional. Read replica mode. Can only be specified when trying to create the instance.
// If not set, Memorystore Redis backend will default to READ_REPLICAS_DISABLED.
// - READ_REPLICAS_DISABLED: If disabled, read endpoint will not be provided and the
// instance cannot scale up or down the number of replicas.
// - READ_REPLICAS_ENABLED: If enabled, read endpoint will be provided and the instance
// can scale up and down the number of replicas. Possible values: ["READ_REPLICAS_DISABLED", "READ_REPLICAS_ENABLED"]
// +kubebuilder:validation:Optional
ReadReplicasMode *string `json:"readReplicasMode,omitempty" tf:"read_replicas_mode,omitempty"`
// Redis configuration parameters, according to http://redis.io/topics/config.
// Please check Memorystore documentation for the list of supported parameters:
// https://cloud.google.com/memorystore/docs/redis/reference/rest/v1/projects.locations.instances#Instance.FIELDS.redis_configs
// +kubebuilder:validation:Optional
RedisConfigs map[string]*string `json:"redisConfigs,omitempty" tf:"redis_configs,omitempty"`
// The version of Redis software. If not provided, latest supported
// version will be used. Please check the API documentation linked
// at the top for the latest valid values.
// +kubebuilder:validation:Optional
RedisVersion *string `json:"redisVersion,omitempty" tf:"redis_version,omitempty"`
// The name of the Redis region of the instance.
// +kubebuilder:validation:Optional
Region *string `json:"region,omitempty" tf:"region,omitempty"`
// Optional. The number of replica nodes. The valid range for the Standard Tier with
// read replicas enabled is [1-5] and defaults to 2. If read replicas are not enabled
// for a Standard Tier instance, the only valid value is 1 and the default is 1.
// The valid value for basic tier is 0 and the default is also 0.
// +kubebuilder:validation:Optional
ReplicaCount *float64 `json:"replicaCount,omitempty" tf:"replica_count,omitempty"`
// The CIDR range of internal addresses that are reserved for this
// instance. If not provided, the service will choose an unused /29
// block, for example, 10.0.0.0/29 or 192.168.0.0/29. Ranges must be
// unique and non-overlapping with existing subnets in an authorized
// network.
// +kubebuilder:validation:Optional
ReservedIPRange *string `json:"reservedIpRange,omitempty" tf:"reserved_ip_range,omitempty"`
// The service tier of the instance. Must be one of these values:
//
// - BASIC: standalone instance
// - STANDARD_HA: highly available primary/replica instances Default value: "BASIC" Possible values: ["BASIC", "STANDARD_HA"]
// +kubebuilder:validation:Optional
Tier *string `json:"tier,omitempty" tf:"tier,omitempty"`
// The TLS mode of the Redis instance, If not provided, TLS is disabled for the instance.
//
// - SERVER_AUTHENTICATION: Client to Server traffic encryption enabled with server authentication Default value: "DISABLED" Possible values: ["SERVER_AUTHENTICATION", "DISABLED"]
// +kubebuilder:validation:Optional
TransitEncryptionMode *string `json:"transitEncryptionMode,omitempty" tf:"transit_encryption_mode,omitempty"`
}
type MaintenancePolicyObservation struct {
CreateTime *string `json:"createTime,omitempty" tf:"create_time,omitempty"`
UpdateTime *string `json:"updateTime,omitempty" tf:"update_time,omitempty"`
}
type MaintenancePolicyParameters struct {
// Optional. Description of what this policy is for.
// Create/Update methods return INVALID_ARGUMENT if the
// length is greater than 512.
// +kubebuilder:validation:Optional
Description *string `json:"description,omitempty" tf:"description,omitempty"`
// Optional. Maintenance window that is applied to resources covered by this policy.
// Minimum 1. For the current version, the maximum number
// of weekly_window is expected to be one.
// +kubebuilder:validation:Optional
WeeklyMaintenanceWindow []WeeklyMaintenanceWindowParameters `json:"weeklyMaintenanceWindow,omitempty" tf:"weekly_maintenance_window,omitempty"`
}
type MaintenanceScheduleObservation struct {
EndTime *string `json:"endTime,omitempty" tf:"end_time,omitempty"`
ScheduleDeadlineTime *string `json:"scheduleDeadlineTime,omitempty" tf:"schedule_deadline_time,omitempty"`
StartTime *string `json:"startTime,omitempty" tf:"start_time,omitempty"`
}
type MaintenanceScheduleParameters struct {
}
type NodesObservation struct {
ID *string `json:"id,omitempty" tf:"id,omitempty"`
Zone *string `json:"zone,omitempty" tf:"zone,omitempty"`
}
type NodesParameters struct {
}
type ServerCACertsObservation struct {
Cert *string `json:"cert,omitempty" tf:"cert,omitempty"`
CreateTime *string `json:"createTime,omitempty" tf:"create_time,omitempty"`
ExpireTime *string `json:"expireTime,omitempty" tf:"expire_time,omitempty"`
SerialNumber *string `json:"serialNumber,omitempty" tf:"serial_number,omitempty"`
Sha1Fingerprint *string `json:"sha1Fingerprint,omitempty" tf:"sha1_fingerprint,omitempty"`
}
type ServerCACertsParameters struct {
}
type StartTimeObservation struct {
}
type StartTimeParameters struct {
// Hours of day in 24 hour format. Should be from 0 to 23.
// An API may choose to allow the value "24:00:00" for scenarios like business closing time.
// +kubebuilder:validation:Optional
Hours *float64 `json:"hours,omitempty" tf:"hours,omitempty"`
// Minutes of hour of day. Must be from 0 to 59.
// +kubebuilder:validation:Optional
Minutes *float64 `json:"minutes,omitempty" tf:"minutes,omitempty"`
// Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999.
// +kubebuilder:validation:Optional
Nanos *float64 `json:"nanos,omitempty" tf:"nanos,omitempty"`
// Seconds of minutes of the time. Must normally be from 0 to 59.
// An API may allow the value 60 if it allows leap-seconds.
// +kubebuilder:validation:Optional
Seconds *float64 `json:"seconds,omitempty" tf:"seconds,omitempty"`
}
type WeeklyMaintenanceWindowObservation struct {
Duration *string `json:"duration,omitempty" tf:"duration,omitempty"`
}
type WeeklyMaintenanceWindowParameters struct {
// Required. The day of week that maintenance updates occur.
//
// - DAY_OF_WEEK_UNSPECIFIED: The day of the week is unspecified.
// - MONDAY: Monday
// - TUESDAY: Tuesday
// - WEDNESDAY: Wednesday
// - THURSDAY: Thursday
// - FRIDAY: Friday
// - SATURDAY: Saturday
// - SUNDAY: Sunday Possible values: ["DAY_OF_WEEK_UNSPECIFIED", "MONDAY", "TUESDAY", "WEDNESDAY", "THURSDAY", "FRIDAY", "SATURDAY", "SUNDAY"]
// +kubebuilder:validation:Required
Day *string `json:"day" tf:"day,omitempty"`
// Required. Start time of the window in UTC time.
// +kubebuilder:validation:Required
StartTime []StartTimeParameters `json:"startTime" tf:"start_time,omitempty"`
}
// InstanceSpec defines the desired state of Instance
type InstanceSpec struct {
v1.ResourceSpec `json:",inline"`
ForProvider InstanceParameters `json:"forProvider"`
}
// InstanceStatus defines the observed state of Instance.
type InstanceStatus struct {
v1.ResourceStatus `json:",inline"`
AtProvider InstanceObservation `json:"atProvider,omitempty"`
}
// +kubebuilder:object:root=true
// Instance is the Schema for the Instances API
// +kubebuilder:printcolumn:name="READY",type="string",JSONPath=".status.conditions[?(@.type=='Ready')].status"
// +kubebuilder:printcolumn:name="SYNCED",type="string",JSONPath=".status.conditions[?(@.type=='Synced')].status"
// +kubebuilder:printcolumn:name="EXTERNAL-NAME",type="string",JSONPath=".metadata.annotations.crossplane\\.io/external-name"
// +kubebuilder:printcolumn:name="AGE",type="date",JSONPath=".metadata.creationTimestamp"
// +kubebuilder:subresource:status
// +kubebuilder:resource:scope=Cluster,categories={crossplane,managed,gcpjet}
type Instance struct {
metav1.TypeMeta `json:",inline"`
metav1.ObjectMeta `json:"metadata,omitempty"`
Spec InstanceSpec `json:"spec"`
Status InstanceStatus `json:"status,omitempty"`
}
// +kubebuilder:object:root=true
// InstanceList contains a list of Instances
type InstanceList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata,omitempty"`
Items []Instance `json:"items"`
}
// Repository type metadata.
var (
Instance_Kind = "Instance"
Instance_GroupKind = schema.GroupKind{Group: CRDGroup, Kind: Instance_Kind}.String()
Instance_KindAPIVersion = Instance_Kind + "." + CRDGroupVersion.String()
Instance_GroupVersionKind = CRDGroupVersion.WithKind(Instance_Kind)
)
func init() {
SchemeBuilder.Register(&Instance{}, &InstanceList{})
}