-
Notifications
You must be signed in to change notification settings - Fork 117
/
zz_fleet_types.go
executable file
·334 lines (244 loc) · 15.7 KB
/
zz_fleet_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
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
/*
Copyright 2022 Upbound Inc.
*/
// Code generated by upjet. DO NOT EDIT.
package v1beta1
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 CertificateConfigurationObservation struct {
// Indicates whether a TLS/SSL certificate is generated for a fleet. Valid values are DISABLED and GENERATED. Default value is DISABLED.
CertificateType *string `json:"certificateType,omitempty" tf:"certificate_type,omitempty"`
}
type CertificateConfigurationParameters struct {
// Indicates whether a TLS/SSL certificate is generated for a fleet. Valid values are DISABLED and GENERATED. Default value is DISABLED.
// +kubebuilder:validation:Optional
CertificateType *string `json:"certificateType,omitempty" tf:"certificate_type,omitempty"`
}
type EC2InboundPermissionObservation struct {
// Starting value for a range of allowed port numbers.
FromPort *float64 `json:"fromPort,omitempty" tf:"from_port,omitempty"`
// Range of allowed IP addresses expressed in CIDR notationE.g., 000.000.000.000/[subnet mask] or 0.0.0.0/[subnet mask].
IPRange *string `json:"ipRange,omitempty" tf:"ip_range,omitempty"`
// Network communication protocol used by the fleetE.g., TCP or UDP
Protocol *string `json:"protocol,omitempty" tf:"protocol,omitempty"`
// Ending value for a range of allowed port numbers. Port numbers are end-inclusive. This value must be higher than from_port.
ToPort *float64 `json:"toPort,omitempty" tf:"to_port,omitempty"`
}
type EC2InboundPermissionParameters struct {
// Starting value for a range of allowed port numbers.
// +kubebuilder:validation:Required
FromPort *float64 `json:"fromPort" tf:"from_port,omitempty"`
// Range of allowed IP addresses expressed in CIDR notationE.g., 000.000.000.000/[subnet mask] or 0.0.0.0/[subnet mask].
// +kubebuilder:validation:Required
IPRange *string `json:"ipRange" tf:"ip_range,omitempty"`
// Network communication protocol used by the fleetE.g., TCP or UDP
// +kubebuilder:validation:Required
Protocol *string `json:"protocol" tf:"protocol,omitempty"`
// Ending value for a range of allowed port numbers. Port numbers are end-inclusive. This value must be higher than from_port.
// +kubebuilder:validation:Required
ToPort *float64 `json:"toPort" tf:"to_port,omitempty"`
}
type FleetObservation struct {
// Fleet ARN.
Arn *string `json:"arn,omitempty" tf:"arn,omitempty"`
// Build ARN.
BuildArn *string `json:"buildArn,omitempty" tf:"build_arn,omitempty"`
// ID of the GameLift Build to be deployed on the fleet.
BuildID *string `json:"buildId,omitempty" tf:"build_id,omitempty"`
// Prompts GameLift to generate a TLS/SSL certificate for the fleet. See certificate_configuration.
CertificateConfiguration []CertificateConfigurationObservation `json:"certificateConfiguration,omitempty" tf:"certificate_configuration,omitempty"`
// Human-readable description of the fleet.
Description *string `json:"description,omitempty" tf:"description,omitempty"`
// Range of IP addresses and port settings that permit inbound traffic to access server processes running on the fleet. See below.
EC2InboundPermission []EC2InboundPermissionObservation `json:"ec2InboundPermission,omitempty" tf:"ec2_inbound_permission,omitempty"`
// Name of an EC2 instance typeE.g., t2.micro
EC2InstanceType *string `json:"ec2InstanceType,omitempty" tf:"ec2_instance_type,omitempty"`
// Type of fleet. This value must be ON_DEMAND or SPOT. Defaults to ON_DEMAND.
FleetType *string `json:"fleetType,omitempty" tf:"fleet_type,omitempty"`
// Fleet ID.
ID *string `json:"id,omitempty" tf:"id,omitempty"`
// ARN of an IAM role that instances in the fleet can assume.
InstanceRoleArn *string `json:"instanceRoleArn,omitempty" tf:"instance_role_arn,omitempty"`
LogPaths []*string `json:"logPaths,omitempty" tf:"log_paths,omitempty"`
// List of names of metric groups to add this fleet to. A metric group tracks metrics across all fleets in the group. Defaults to default.
MetricGroups []*string `json:"metricGroups,omitempty" tf:"metric_groups,omitempty"`
// The name of the fleet.
Name *string `json:"name,omitempty" tf:"name,omitempty"`
// Game session protection policy to apply to all instances in this fleetE.g., FullProtection. Defaults to NoProtection.
NewGameSessionProtectionPolicy *string `json:"newGameSessionProtectionPolicy,omitempty" tf:"new_game_session_protection_policy,omitempty"`
// Operating system of the fleet's computing resources.
OperatingSystem *string `json:"operatingSystem,omitempty" tf:"operating_system,omitempty"`
// Policy that limits the number of game sessions an individual player can create over a span of time for this fleet. See below.
ResourceCreationLimitPolicy []ResourceCreationLimitPolicyObservation `json:"resourceCreationLimitPolicy,omitempty" tf:"resource_creation_limit_policy,omitempty"`
// Instructions for launching server processes on each instance in the fleet. See below.
RuntimeConfiguration []RuntimeConfigurationObservation `json:"runtimeConfiguration,omitempty" tf:"runtime_configuration,omitempty"`
// Script ARN.
ScriptArn *string `json:"scriptArn,omitempty" tf:"script_arn,omitempty"`
// ID of the GameLift Script to be deployed on the fleet.
ScriptID *string `json:"scriptId,omitempty" tf:"script_id,omitempty"`
// Key-value map of resource tags.
Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"`
// A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.
TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"`
}
type FleetParameters struct {
// ID of the GameLift Build to be deployed on the fleet.
// +crossplane:generate:reference:type=Build
// +kubebuilder:validation:Optional
BuildID *string `json:"buildId,omitempty" tf:"build_id,omitempty"`
// Reference to a Build to populate buildId.
// +kubebuilder:validation:Optional
BuildIDRef *v1.Reference `json:"buildIdRef,omitempty" tf:"-"`
// Selector for a Build to populate buildId.
// +kubebuilder:validation:Optional
BuildIDSelector *v1.Selector `json:"buildIdSelector,omitempty" tf:"-"`
// Prompts GameLift to generate a TLS/SSL certificate for the fleet. See certificate_configuration.
// +kubebuilder:validation:Optional
CertificateConfiguration []CertificateConfigurationParameters `json:"certificateConfiguration,omitempty" tf:"certificate_configuration,omitempty"`
// Human-readable description of the fleet.
// +kubebuilder:validation:Optional
Description *string `json:"description,omitempty" tf:"description,omitempty"`
// Range of IP addresses and port settings that permit inbound traffic to access server processes running on the fleet. See below.
// +kubebuilder:validation:Optional
EC2InboundPermission []EC2InboundPermissionParameters `json:"ec2InboundPermission,omitempty" tf:"ec2_inbound_permission,omitempty"`
// Name of an EC2 instance typeE.g., t2.micro
// +kubebuilder:validation:Optional
EC2InstanceType *string `json:"ec2InstanceType,omitempty" tf:"ec2_instance_type,omitempty"`
// Type of fleet. This value must be ON_DEMAND or SPOT. Defaults to ON_DEMAND.
// +kubebuilder:validation:Optional
FleetType *string `json:"fleetType,omitempty" tf:"fleet_type,omitempty"`
// ARN of an IAM role that instances in the fleet can assume.
// +crossplane:generate:reference:type=github.com/upbound/provider-aws/apis/iam/v1beta1.Role
// +crossplane:generate:reference:extractor=github.com/upbound/provider-aws/config/common.ARNExtractor()
// +kubebuilder:validation:Optional
InstanceRoleArn *string `json:"instanceRoleArn,omitempty" tf:"instance_role_arn,omitempty"`
// Reference to a Role in iam to populate instanceRoleArn.
// +kubebuilder:validation:Optional
InstanceRoleArnRef *v1.Reference `json:"instanceRoleArnRef,omitempty" tf:"-"`
// Selector for a Role in iam to populate instanceRoleArn.
// +kubebuilder:validation:Optional
InstanceRoleArnSelector *v1.Selector `json:"instanceRoleArnSelector,omitempty" tf:"-"`
// List of names of metric groups to add this fleet to. A metric group tracks metrics across all fleets in the group. Defaults to default.
// +kubebuilder:validation:Optional
MetricGroups []*string `json:"metricGroups,omitempty" tf:"metric_groups,omitempty"`
// The name of the fleet.
// +kubebuilder:validation:Optional
Name *string `json:"name,omitempty" tf:"name,omitempty"`
// Game session protection policy to apply to all instances in this fleetE.g., FullProtection. Defaults to NoProtection.
// +kubebuilder:validation:Optional
NewGameSessionProtectionPolicy *string `json:"newGameSessionProtectionPolicy,omitempty" tf:"new_game_session_protection_policy,omitempty"`
// Region is the region you'd like your resource to be created in.
// +upjet:crd:field:TFTag=-
// +kubebuilder:validation:Required
Region *string `json:"region" tf:"-"`
// Policy that limits the number of game sessions an individual player can create over a span of time for this fleet. See below.
// +kubebuilder:validation:Optional
ResourceCreationLimitPolicy []ResourceCreationLimitPolicyParameters `json:"resourceCreationLimitPolicy,omitempty" tf:"resource_creation_limit_policy,omitempty"`
// Instructions for launching server processes on each instance in the fleet. See below.
// +kubebuilder:validation:Optional
RuntimeConfiguration []RuntimeConfigurationParameters `json:"runtimeConfiguration,omitempty" tf:"runtime_configuration,omitempty"`
// ID of the GameLift Script to be deployed on the fleet.
// +kubebuilder:validation:Optional
ScriptID *string `json:"scriptId,omitempty" tf:"script_id,omitempty"`
// Key-value map of resource tags.
// +kubebuilder:validation:Optional
Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"`
}
type ResourceCreationLimitPolicyObservation struct {
// Maximum number of game sessions that an individual can create during the policy period.
NewGameSessionsPerCreator *float64 `json:"newGameSessionsPerCreator,omitempty" tf:"new_game_sessions_per_creator,omitempty"`
// Time span used in evaluating the resource creation limit policy.
PolicyPeriodInMinutes *float64 `json:"policyPeriodInMinutes,omitempty" tf:"policy_period_in_minutes,omitempty"`
}
type ResourceCreationLimitPolicyParameters struct {
// Maximum number of game sessions that an individual can create during the policy period.
// +kubebuilder:validation:Optional
NewGameSessionsPerCreator *float64 `json:"newGameSessionsPerCreator,omitempty" tf:"new_game_sessions_per_creator,omitempty"`
// Time span used in evaluating the resource creation limit policy.
// +kubebuilder:validation:Optional
PolicyPeriodInMinutes *float64 `json:"policyPeriodInMinutes,omitempty" tf:"policy_period_in_minutes,omitempty"`
}
type RuntimeConfigurationObservation struct {
// Maximum amount of time (in seconds) that a game session can remain in status ACTIVATING.
GameSessionActivationTimeoutSeconds *float64 `json:"gameSessionActivationTimeoutSeconds,omitempty" tf:"game_session_activation_timeout_seconds,omitempty"`
// Maximum number of game sessions with status ACTIVATING to allow on an instance simultaneously.
MaxConcurrentGameSessionActivations *float64 `json:"maxConcurrentGameSessionActivations,omitempty" tf:"max_concurrent_game_session_activations,omitempty"`
// Collection of server process configurations that describe which server processes to run on each instance in a fleet. See below.
ServerProcess []ServerProcessObservation `json:"serverProcess,omitempty" tf:"server_process,omitempty"`
}
type RuntimeConfigurationParameters struct {
// Maximum amount of time (in seconds) that a game session can remain in status ACTIVATING.
// +kubebuilder:validation:Optional
GameSessionActivationTimeoutSeconds *float64 `json:"gameSessionActivationTimeoutSeconds,omitempty" tf:"game_session_activation_timeout_seconds,omitempty"`
// Maximum number of game sessions with status ACTIVATING to allow on an instance simultaneously.
// +kubebuilder:validation:Optional
MaxConcurrentGameSessionActivations *float64 `json:"maxConcurrentGameSessionActivations,omitempty" tf:"max_concurrent_game_session_activations,omitempty"`
// Collection of server process configurations that describe which server processes to run on each instance in a fleet. See below.
// +kubebuilder:validation:Optional
ServerProcess []ServerProcessParameters `json:"serverProcess,omitempty" tf:"server_process,omitempty"`
}
type ServerProcessObservation struct {
// Number of server processes using this configuration to run concurrently on an instance.
ConcurrentExecutions *float64 `json:"concurrentExecutions,omitempty" tf:"concurrent_executions,omitempty"`
// Location of the server executable in a game build. All game builds are installed on instances at the root : for Windows instances C:\game, and for Linux instances /local/game.
LaunchPath *string `json:"launchPath,omitempty" tf:"launch_path,omitempty"`
// Optional list of parameters to pass to the server executable on launch.
Parameters *string `json:"parameters,omitempty" tf:"parameters,omitempty"`
}
type ServerProcessParameters struct {
// Number of server processes using this configuration to run concurrently on an instance.
// +kubebuilder:validation:Required
ConcurrentExecutions *float64 `json:"concurrentExecutions" tf:"concurrent_executions,omitempty"`
// Location of the server executable in a game build. All game builds are installed on instances at the root : for Windows instances C:\game, and for Linux instances /local/game.
// +kubebuilder:validation:Required
LaunchPath *string `json:"launchPath" tf:"launch_path,omitempty"`
// Optional list of parameters to pass to the server executable on launch.
// +kubebuilder:validation:Optional
Parameters *string `json:"parameters,omitempty" tf:"parameters,omitempty"`
}
// FleetSpec defines the desired state of Fleet
type FleetSpec struct {
v1.ResourceSpec `json:",inline"`
ForProvider FleetParameters `json:"forProvider"`
}
// FleetStatus defines the observed state of Fleet.
type FleetStatus struct {
v1.ResourceStatus `json:",inline"`
AtProvider FleetObservation `json:"atProvider,omitempty"`
}
// +kubebuilder:object:root=true
// Fleet is the Schema for the Fleets API. Provides a GameLift Fleet resource.
// +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,aws},path=fleet
type Fleet struct {
metav1.TypeMeta `json:",inline"`
metav1.ObjectMeta `json:"metadata,omitempty"`
// +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.ec2InstanceType)",message="ec2InstanceType is a required parameter"
// +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.name)",message="name is a required parameter"
Spec FleetSpec `json:"spec"`
Status FleetStatus `json:"status,omitempty"`
}
// +kubebuilder:object:root=true
// FleetList contains a list of Fleets
type FleetList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata,omitempty"`
Items []Fleet `json:"items"`
}
// Repository type metadata.
var (
Fleet_Kind = "Fleet"
Fleet_GroupKind = schema.GroupKind{Group: CRDGroup, Kind: Fleet_Kind}.String()
Fleet_KindAPIVersion = Fleet_Kind + "." + CRDGroupVersion.String()
Fleet_GroupVersionKind = CRDGroupVersion.WithKind(Fleet_Kind)
)
func init() {
SchemeBuilder.Register(&Fleet{}, &FleetList{})
}