-
Notifications
You must be signed in to change notification settings - Fork 61
/
zz_service_types.go
executable file
·774 lines (618 loc) · 32.1 KB
/
zz_service_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
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
/*
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 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 ConfigMapRefObservation struct {
}
type ConfigMapRefParameters struct {
// The Secret to select from.
// Structure is documented below.
// +kubebuilder:validation:Optional
LocalObjectReference []LocalObjectReferenceParameters `json:"localObjectReference,omitempty" tf:"local_object_reference,omitempty"`
// Specify whether the Secret must be defined
// +kubebuilder:validation:Optional
Optional *bool `json:"optional,omitempty" tf:"optional,omitempty"`
}
type ContainersObservation struct {
}
type ContainersParameters struct {
// Arguments to the entrypoint.
// The docker image's CMD is used if this is not provided.
// Variable references $(VAR_NAME) are expanded using the container's
// environment. If a variable cannot be resolved, the reference in the input
// string will be unchanged. The $(VAR_NAME) syntax can be escaped with a
// double $$, ie: $$(VAR_NAME). Escaped references will never be expanded,
// regardless of whether the variable exists or not.
// More info:
// https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell
// +kubebuilder:validation:Optional
Args []*string `json:"args,omitempty" tf:"args,omitempty"`
// Entrypoint array. Not executed within a shell.
// The docker image's ENTRYPOINT is used if this is not provided.
// Variable references $(VAR_NAME) are expanded using the container's
// environment. If a variable cannot be resolved, the reference in the input
// string will be unchanged. The $(VAR_NAME) syntax can be escaped with a
// double $$, ie: $$(VAR_NAME). Escaped references will never be expanded,
// regardless of whether the variable exists or not.
// More info:
// https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell
// +kubebuilder:validation:Optional
Command []*string `json:"command,omitempty" tf:"command,omitempty"`
// List of environment variables to set in the container.
// Structure is documented below.
// +kubebuilder:validation:Optional
Env []EnvParameters `json:"env,omitempty" tf:"env,omitempty"`
// List of sources to populate environment variables in the container.
// All invalid keys will be reported as an event when the container is starting.
// When a key exists in multiple sources, the value associated with the last source will
// take precedence. Values defined by an Env with a duplicate key will take
// precedence.
// Structure is documented below.
// +kubebuilder:validation:Optional
EnvFrom []EnvFromParameters `json:"envFrom,omitempty" tf:"env_from,omitempty"`
// Docker image name. This is most often a reference to a container located
// in the container registry, such as gcr.io/cloudrun/hello
// More info: https://kubernetes.io/docs/concepts/containers/images
// +kubebuilder:validation:Required
Image *string `json:"image" tf:"image,omitempty"`
// List of open ports in the container.
// More Info:
// https://cloud.google.com/run/docs/reference/rest/v1/RevisionSpec#ContainerPort
// Structure is documented below.
// +kubebuilder:validation:Optional
Ports []PortsParameters `json:"ports,omitempty" tf:"ports,omitempty"`
// Compute Resources required by this container. Used to set values such as max memory
// More info:
// https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/#requests-and-limits
// Structure is documented below.
// +kubebuilder:validation:Optional
Resources []ResourcesParameters `json:"resources,omitempty" tf:"resources,omitempty"`
// Volume to mount into the container's filesystem.
// Only supports SecretVolumeSources.
// Structure is documented below.
// +kubebuilder:validation:Optional
VolumeMounts []VolumeMountsParameters `json:"volumeMounts,omitempty" tf:"volume_mounts,omitempty"`
// Container's working directory.
// If not specified, the container runtime's default will be used, which
// might be configured in the container image.
// +kubebuilder:validation:Optional
WorkingDir *string `json:"workingDir,omitempty" tf:"working_dir,omitempty"`
}
type EnvFromObservation struct {
}
type EnvFromParameters struct {
// The ConfigMap to select from.
// Structure is documented below.
// +kubebuilder:validation:Optional
ConfigMapRef []ConfigMapRefParameters `json:"configMapRef,omitempty" tf:"config_map_ref,omitempty"`
// An optional identifier to prepend to each key in the ConfigMap.
// +kubebuilder:validation:Optional
Prefix *string `json:"prefix,omitempty" tf:"prefix,omitempty"`
// The Secret to select from.
// Structure is documented below.
// +kubebuilder:validation:Optional
SecretRef []SecretRefParameters `json:"secretRef,omitempty" tf:"secret_ref,omitempty"`
}
type EnvObservation struct {
}
type EnvParameters struct {
// Volume's name.
// +kubebuilder:validation:Optional
Name *string `json:"name,omitempty" tf:"name,omitempty"`
// Variable references $(VAR_NAME) are expanded
// using the previous defined environment variables in the container and
// any route environment variables. If a variable cannot be resolved,
// the reference in the input string will be unchanged. The $(VAR_NAME)
// syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped
// references will never be expanded, regardless of whether the variable
// exists or not.
// Defaults to "".
// +kubebuilder:validation:Optional
Value *string `json:"value,omitempty" tf:"value,omitempty"`
// Source for the environment variable's value. Only supports secret_key_ref.
// Structure is documented below.
// +kubebuilder:validation:Optional
ValueFrom []ValueFromParameters `json:"valueFrom,omitempty" tf:"value_from,omitempty"`
}
type ItemsObservation struct {
}
type ItemsParameters struct {
// A Cloud Secret Manager secret version. Must be 'latest' for the latest
// version or an integer for a specific version.
// +kubebuilder:validation:Required
Key *string `json:"key" tf:"key,omitempty"`
// Mode bits to use on this file, must be a value between 0000 and 0777. If
// not specified, the volume defaultMode will be used. This might be in
// conflict with other options that affect the file mode, like fsGroup, and
// the result can be other mode bits set.
// +kubebuilder:validation:Optional
Mode *float64 `json:"mode,omitempty" tf:"mode,omitempty"`
// The relative path of the file to map the key to.
// May not be an absolute path.
// May not contain the path element '..'.
// May not start with the string '..'.
// +kubebuilder:validation:Required
Path *string `json:"path" tf:"path,omitempty"`
}
type LocalObjectReferenceObservation struct {
}
type LocalObjectReferenceParameters struct {
// Volume's name.
// +kubebuilder:validation:Required
Name *string `json:"name" tf:"name,omitempty"`
}
type PortsObservation struct {
}
type PortsParameters struct {
// Port number the container listens on. This must be a valid port number, 0 < x < 65536.
// +kubebuilder:validation:Optional
ContainerPort *float64 `json:"containerPort,omitempty" tf:"container_port,omitempty"`
// Volume's name.
// +kubebuilder:validation:Optional
Name *string `json:"name,omitempty" tf:"name,omitempty"`
// Protocol for port. Must be "TCP". Defaults to "TCP".
// +kubebuilder:validation:Optional
Protocol *string `json:"protocol,omitempty" tf:"protocol,omitempty"`
}
type ResourcesObservation struct {
}
type ResourcesParameters struct {
// Limits describes the maximum amount of compute resources allowed.
// The values of the map is string form of the 'quantity' k8s type:
// https://github.com/kubernetes/kubernetes/blob/master/staging/src/k8s.io/apimachinery/pkg/api/resource/quantity.go
// +kubebuilder:validation:Optional
Limits map[string]*string `json:"limits,omitempty" tf:"limits,omitempty"`
// Requests describes the minimum amount of compute resources required.
// If Requests is omitted for a container, it defaults to Limits if that is
// explicitly specified, otherwise to an implementation-defined value.
// The values of the map is string form of the 'quantity' k8s type:
// https://github.com/kubernetes/kubernetes/blob/master/staging/src/k8s.io/apimachinery/pkg/api/resource/quantity.go
// +kubebuilder:validation:Optional
Requests map[string]*string `json:"requests,omitempty" tf:"requests,omitempty"`
}
type SecretKeyRefObservation struct {
}
type SecretKeyRefParameters struct {
// A Cloud Secret Manager secret version. Must be 'latest' for the latest
// version or an integer for a specific version.
// +kubebuilder:validation:Required
Key *string `json:"key" tf:"key,omitempty"`
// Volume's name.
// +crossplane:generate:reference:type=github.com/upbound/provider-gcp/apis/secretmanager/v1beta1.Secret
// +kubebuilder:validation:Optional
Name *string `json:"name,omitempty" tf:"name,omitempty"`
// Reference to a Secret in secretmanager to populate name.
// +kubebuilder:validation:Optional
NameRef *v1.Reference `json:"nameRef,omitempty" tf:"-"`
// Selector for a Secret in secretmanager to populate name.
// +kubebuilder:validation:Optional
NameSelector *v1.Selector `json:"nameSelector,omitempty" tf:"-"`
}
type SecretObservation struct {
}
type SecretParameters struct {
// Mode bits to use on created files by default. Must be a value between 0000
// and 0777. Defaults to 0644. Directories within the path are not affected by
// this setting. This might be in conflict with other options that affect the
// file mode, like fsGroup, and the result can be other mode bits set.
// +kubebuilder:validation:Optional
DefaultMode *float64 `json:"defaultMode,omitempty" tf:"default_mode,omitempty"`
// If unspecified, the volume will expose a file whose name is the
// secret_name.
// If specified, the key will be used as the version to fetch from Cloud
// Secret Manager and the path will be the name of the file exposed in the
// volume. When items are defined, they must specify a key and a path.
// Structure is documented below.
// +kubebuilder:validation:Optional
Items []ItemsParameters `json:"items,omitempty" tf:"items,omitempty"`
// The name of the secret in Cloud Secret Manager. By default, the secret
// is assumed to be in the same project.
// If the secret is in another project, you must define an alias.
// An alias definition has the form:
// :projects/<project-id|project-number>/secrets/.
// If multiple alias definitions are needed, they must be separated by
// commas.
// The alias definitions must be set on the run.googleapis.com/secrets
// annotation.
// +crossplane:generate:reference:type=github.com/upbound/provider-gcp/apis/secretmanager/v1beta1.Secret
// +kubebuilder:validation:Optional
SecretName *string `json:"secretName,omitempty" tf:"secret_name,omitempty"`
// Reference to a Secret in secretmanager to populate secretName.
// +kubebuilder:validation:Optional
SecretNameRef *v1.Reference `json:"secretNameRef,omitempty" tf:"-"`
// Selector for a Secret in secretmanager to populate secretName.
// +kubebuilder:validation:Optional
SecretNameSelector *v1.Selector `json:"secretNameSelector,omitempty" tf:"-"`
}
type SecretRefLocalObjectReferenceObservation struct {
}
type SecretRefLocalObjectReferenceParameters struct {
// Volume's name.
// +kubebuilder:validation:Required
Name *string `json:"name" tf:"name,omitempty"`
}
type SecretRefObservation struct {
}
type SecretRefParameters struct {
// The Secret to select from.
// Structure is documented below.
// +kubebuilder:validation:Optional
LocalObjectReference []SecretRefLocalObjectReferenceParameters `json:"localObjectReference,omitempty" tf:"local_object_reference,omitempty"`
// Specify whether the Secret must be defined
// +kubebuilder:validation:Optional
Optional *bool `json:"optional,omitempty" tf:"optional,omitempty"`
}
type ServiceMetadataObservation struct {
// A sequence number representing a specific generation of the desired state.
Generation *float64 `json:"generation,omitempty" tf:"generation,omitempty"`
// An opaque value that represents the internal version of this object that
// can be used by clients to determine when objects have changed. May be used
// for optimistic concurrency, change detection, and the watch operation on a
// resource or set of resources. They may only be valid for a
// particular resource or set of resources.
// More info:
// https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency
ResourceVersion *string `json:"resourceVersion,omitempty" tf:"resource_version,omitempty"`
// SelfLink is a URL representing this object.
SelfLink *string `json:"selfLink,omitempty" tf:"self_link,omitempty"`
// UID is a unique id generated by the server on successful creation of a resource and is not
// allowed to change on PUT operations.
// More info: http://kubernetes.io/docs/user-guide/identifiers#uids
UID *string `json:"uid,omitempty" tf:"uid,omitempty"`
}
type ServiceMetadataParameters struct {
// Annotations is a key value map stored with a resource that
// may be set by external tools to store and retrieve arbitrary metadata. More
// info: http://kubernetes.io/docs/user-guide/annotations
// Note: The Cloud Run API may add additional annotations that were not provided in your config.ignore_changes rule to the metadata.0.annotations field.
// +kubebuilder:validation:Optional
Annotations map[string]*string `json:"annotations,omitempty" tf:"annotations,omitempty"`
// Map of string keys and values that can be used to organize and categorize
// (scope and select) objects. May match selectors of replication controllers
// and routes.
// More info: http://kubernetes.io/docs/user-guide/labels
// +kubebuilder:validation:Optional
Labels map[string]*string `json:"labels,omitempty" tf:"labels,omitempty"`
// In Cloud Run the namespace must be equal to either the
// project ID or project number. It will default to the resource's project.
// +crossplane:generate:reference:type=github.com/upbound/provider-gcp/apis/cloudplatform/v1beta1.Project
// +kubebuilder:validation:Optional
Namespace *string `json:"namespace,omitempty" tf:"namespace,omitempty"`
// Reference to a Project in cloudplatform to populate namespace.
// +kubebuilder:validation:Optional
NamespaceRef *v1.Reference `json:"namespaceRef,omitempty" tf:"-"`
// Selector for a Project in cloudplatform to populate namespace.
// +kubebuilder:validation:Optional
NamespaceSelector *v1.Selector `json:"namespaceSelector,omitempty" tf:"-"`
}
type ServiceObservation struct {
// an identifier for the resource with format locations/{{location}}/namespaces/{{project}}/services/{{name}}
ID *string `json:"id,omitempty" tf:"id,omitempty"`
// Optional metadata for this Revision, including labels and annotations.
// Name will be generated by the Configuration. To set minimum instances
// for this revision, use the "autoscaling.knative.dev/minScale" annotation
// key. To set maximum instances for this revision, use the
// "autoscaling.knative.dev/maxScale" annotation key. To set Cloud SQL
// connections for the revision, use the "run.googleapis.com/cloudsql-instances"
// annotation key.
// Structure is documented below.
// +kubebuilder:validation:Optional
Metadata []ServiceMetadataObservation `json:"metadata,omitempty" tf:"metadata,omitempty"`
// The current status of the Service.
// Structure is documented below.
Status []ServiceStatusObservation `json:"status,omitempty" tf:"status,omitempty"`
// template holds the latest specification for the Revision to
// be stamped out. The template references the container image, and may also
// include labels and annotations that should be attached to the Revision.
// To correlate a Revision, and/or to force a Revision to be created when the
// spec doesn't otherwise change, a nonce label may be provided in the
// template metadata. For more details, see:
// https://github.com/knative/serving/blob/main/docs/client-conventions.md#associate-modifications-with-revisions
// Cloud Run does not currently support referencing a build that is
// responsible for materializing the container image from source.
// Structure is documented below.
// +kubebuilder:validation:Optional
Template []TemplateObservation `json:"template,omitempty" tf:"template,omitempty"`
// Traffic specifies how to distribute traffic over a collection of Knative Revisions
// and Configurations
// Structure is documented below.
// +kubebuilder:validation:Optional
Traffic []TrafficObservation `json:"traffic,omitempty" tf:"traffic,omitempty"`
}
type ServiceParameters struct {
// If set to true, the revision name (template.metadata.name) will be omitted and
// autogenerated by Cloud Run. This cannot be set to true while template.metadata.name
// is also set.
// (For legacy support, if template.metadata.name is unset in state while
// this field is set to false, the revision name will still autogenerate.)
// +kubebuilder:validation:Optional
AutogenerateRevisionName *bool `json:"autogenerateRevisionName,omitempty" tf:"autogenerate_revision_name,omitempty"`
// The location of the cloud run instance. eg us-central1
// +kubebuilder:validation:Required
Location *string `json:"location" tf:"location,omitempty"`
// Optional metadata for this Revision, including labels and annotations.
// Name will be generated by the Configuration. To set minimum instances
// for this revision, use the "autoscaling.knative.dev/minScale" annotation
// key. To set maximum instances for this revision, use the
// "autoscaling.knative.dev/maxScale" annotation key. To set Cloud SQL
// connections for the revision, use the "run.googleapis.com/cloudsql-instances"
// annotation key.
// Structure is documented below.
// +kubebuilder:validation:Optional
Metadata []ServiceMetadataParameters `json:"metadata,omitempty" tf:"metadata,omitempty"`
// The ID of the project in which the resource belongs.
// If it is not provided, the provider project is used.
// +kubebuilder:validation:Optional
Project *string `json:"project,omitempty" tf:"project,omitempty"`
// template holds the latest specification for the Revision to
// be stamped out. The template references the container image, and may also
// include labels and annotations that should be attached to the Revision.
// To correlate a Revision, and/or to force a Revision to be created when the
// spec doesn't otherwise change, a nonce label may be provided in the
// template metadata. For more details, see:
// https://github.com/knative/serving/blob/main/docs/client-conventions.md#associate-modifications-with-revisions
// Cloud Run does not currently support referencing a build that is
// responsible for materializing the container image from source.
// Structure is documented below.
// +kubebuilder:validation:Optional
Template []TemplateParameters `json:"template,omitempty" tf:"template,omitempty"`
// Traffic specifies how to distribute traffic over a collection of Knative Revisions
// and Configurations
// Structure is documented below.
// +kubebuilder:validation:Optional
Traffic []TrafficParameters `json:"traffic,omitempty" tf:"traffic,omitempty"`
}
type ServiceStatusObservation struct {
// Array of observed Service Conditions, indicating the current ready state of the service.
// Structure is documented below.
Conditions []StatusConditionsObservation `json:"conditions,omitempty" tf:"conditions,omitempty"`
// From ConfigurationStatus. LatestCreatedRevisionName is the last revision that was created
// from this Service's Configuration. It might not be ready yet, for that use
// LatestReadyRevisionName.
LatestCreatedRevisionName *string `json:"latestCreatedRevisionName,omitempty" tf:"latest_created_revision_name,omitempty"`
// From ConfigurationStatus. LatestReadyRevisionName holds the name of the latest Revision
// stamped out from this Service's Configuration that has had its "Ready" condition become
// "True".
LatestReadyRevisionName *string `json:"latestReadyRevisionName,omitempty" tf:"latest_ready_revision_name,omitempty"`
// ObservedGeneration is the 'Generation' of the Route that was last processed by the
// controller.
// Clients polling for completed reconciliation should poll until observedGeneration =
// metadata.generation and the Ready condition's status is True or False.
ObservedGeneration *float64 `json:"observedGeneration,omitempty" tf:"observed_generation,omitempty"`
// From RouteStatus. URL holds the url that will distribute traffic over the provided traffic
// targets. It generally has the form
// https://{route-hash}-{project-hash}-{cluster-level-suffix}.a.run.app
URL *string `json:"url,omitempty" tf:"url,omitempty"`
}
type ServiceStatusParameters struct {
}
type StatusConditionsObservation struct {
// Human readable message indicating details about the current status.
Message *string `json:"message,omitempty" tf:"message,omitempty"`
// One-word CamelCase reason for the condition's current status.
Reason *string `json:"reason,omitempty" tf:"reason,omitempty"`
// The current status of the Service.
// Structure is documented below.
Status *string `json:"status,omitempty" tf:"status,omitempty"`
// Type of domain mapping condition.
Type *string `json:"type,omitempty" tf:"type,omitempty"`
}
type StatusConditionsParameters struct {
}
type TemplateMetadataObservation struct {
// A sequence number representing a specific generation of the desired state.
Generation *float64 `json:"generation,omitempty" tf:"generation,omitempty"`
// An opaque value that represents the internal version of this object that
// can be used by clients to determine when objects have changed. May be used
// for optimistic concurrency, change detection, and the watch operation on a
// resource or set of resources. They may only be valid for a
// particular resource or set of resources.
// More info:
// https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency
ResourceVersion *string `json:"resourceVersion,omitempty" tf:"resource_version,omitempty"`
// SelfLink is a URL representing this object.
SelfLink *string `json:"selfLink,omitempty" tf:"self_link,omitempty"`
// UID is a unique id generated by the server on successful creation of a resource and is not
// allowed to change on PUT operations.
// More info: http://kubernetes.io/docs/user-guide/identifiers#uids
UID *string `json:"uid,omitempty" tf:"uid,omitempty"`
}
type TemplateMetadataParameters struct {
// Annotations is a key value map stored with a resource that
// may be set by external tools to store and retrieve arbitrary metadata. More
// info: http://kubernetes.io/docs/user-guide/annotations
// Note: The Cloud Run API may add additional annotations that were not provided in your config.ignore_changes rule to the metadata.0.annotations field.
// +kubebuilder:validation:Optional
Annotations map[string]*string `json:"annotations,omitempty" tf:"annotations,omitempty"`
// Map of string keys and values that can be used to organize and categorize
// (scope and select) objects. May match selectors of replication controllers
// and routes.
// More info: http://kubernetes.io/docs/user-guide/labels
// +kubebuilder:validation:Optional
Labels map[string]*string `json:"labels,omitempty" tf:"labels,omitempty"`
// Volume's name.
// +kubebuilder:validation:Optional
Name *string `json:"name,omitempty" tf:"name,omitempty"`
// In Cloud Run the namespace must be equal to either the
// project ID or project number. It will default to the resource's project.
// +kubebuilder:validation:Optional
Namespace *string `json:"namespace,omitempty" tf:"namespace,omitempty"`
}
type TemplateObservation struct {
// Optional metadata for this Revision, including labels and annotations.
// Name will be generated by the Configuration. To set minimum instances
// for this revision, use the "autoscaling.knative.dev/minScale" annotation
// key. To set maximum instances for this revision, use the
// "autoscaling.knative.dev/maxScale" annotation key. To set Cloud SQL
// connections for the revision, use the "run.googleapis.com/cloudsql-instances"
// annotation key.
// Structure is documented below.
// +kubebuilder:validation:Optional
Metadata []TemplateMetadataObservation `json:"metadata,omitempty" tf:"metadata,omitempty"`
// RevisionSpec holds the desired state of the Revision (from the client).
// Structure is documented below.
// +kubebuilder:validation:Optional
Spec []TemplateSpecObservation `json:"spec,omitempty" tf:"spec,omitempty"`
}
type TemplateParameters struct {
// Optional metadata for this Revision, including labels and annotations.
// Name will be generated by the Configuration. To set minimum instances
// for this revision, use the "autoscaling.knative.dev/minScale" annotation
// key. To set maximum instances for this revision, use the
// "autoscaling.knative.dev/maxScale" annotation key. To set Cloud SQL
// connections for the revision, use the "run.googleapis.com/cloudsql-instances"
// annotation key.
// Structure is documented below.
// +kubebuilder:validation:Optional
Metadata []TemplateMetadataParameters `json:"metadata,omitempty" tf:"metadata,omitempty"`
// RevisionSpec holds the desired state of the Revision (from the client).
// Structure is documented below.
// +kubebuilder:validation:Optional
Spec []TemplateSpecParameters `json:"spec,omitempty" tf:"spec,omitempty"`
}
type TemplateSpecObservation struct {
// (Deprecated)
// ServingState holds a value describing the state the resources
// are in for this Revision.
// It is expected
// that the system will manipulate this based on routability and load.
ServingState *string `json:"servingState,omitempty" tf:"serving_state,omitempty"`
}
type TemplateSpecParameters struct {
// ContainerConcurrency specifies the maximum allowed in-flight (concurrent)
// requests per container of the Revision. Values are:
// +kubebuilder:validation:Optional
ContainerConcurrency *float64 `json:"containerConcurrency,omitempty" tf:"container_concurrency,omitempty"`
// Container defines the unit of execution for this Revision.
// In the context of a Revision, we disallow a number of the fields of
// this Container, including: name, ports, and volumeMounts.
// The runtime contract is documented here:
// https://github.com/knative/serving/blob/main/docs/runtime-contract.md
// Structure is documented below.
// +kubebuilder:validation:Optional
Containers []ContainersParameters `json:"containers,omitempty" tf:"containers,omitempty"`
// Email address of the IAM service account associated with the revision of the
// service. The service account represents the identity of the running revision,
// and determines what permissions the revision has. If not provided, the revision
// will use the project's default service account.
// +kubebuilder:validation:Optional
ServiceAccountName *string `json:"serviceAccountName,omitempty" tf:"service_account_name,omitempty"`
// TimeoutSeconds holds the max duration the instance is allowed for responding to a request.
// +kubebuilder:validation:Optional
TimeoutSeconds *float64 `json:"timeoutSeconds,omitempty" tf:"timeout_seconds,omitempty"`
// Volume represents a named volume in a container.
// Structure is documented below.
// +kubebuilder:validation:Optional
Volumes []VolumesParameters `json:"volumes,omitempty" tf:"volumes,omitempty"`
}
type TrafficObservation struct {
// URL displays the URL for accessing tagged traffic targets. URL is displayed in status,
// and is disallowed on spec. URL must contain a scheme (e.g. http://) and a hostname,
// but may not contain anything else (e.g. basic auth, url path, etc.)
URL *string `json:"url,omitempty" tf:"url,omitempty"`
}
type TrafficParameters struct {
// LatestRevision may be optionally provided to indicate that the latest ready
// Revision of the Configuration should be used for this traffic target. When
// provided LatestRevision must be true if RevisionName is empty; it must be
// false when RevisionName is non-empty.
// +kubebuilder:validation:Optional
LatestRevision *bool `json:"latestRevision,omitempty" tf:"latest_revision,omitempty"`
// Percent specifies percent of the traffic to this Revision or Configuration.
// +kubebuilder:validation:Required
Percent *float64 `json:"percent" tf:"percent,omitempty"`
// RevisionName of a specific revision to which to send this portion of traffic.
// +kubebuilder:validation:Optional
RevisionName *string `json:"revisionName,omitempty" tf:"revision_name,omitempty"`
// Tag is optionally used to expose a dedicated url for referencing this target exclusively.
// +kubebuilder:validation:Optional
Tag *string `json:"tag,omitempty" tf:"tag,omitempty"`
}
type ValueFromObservation struct {
}
type ValueFromParameters struct {
// Selects a key (version) of a secret in Secret Manager.
// Structure is documented below.
// +kubebuilder:validation:Required
SecretKeyRef []SecretKeyRefParameters `json:"secretKeyRef" tf:"secret_key_ref,omitempty"`
}
type VolumeMountsObservation struct {
}
type VolumeMountsParameters struct {
// Path within the container at which the volume should be mounted. Must
// not contain ':'.
// +kubebuilder:validation:Required
MountPath *string `json:"mountPath" tf:"mount_path,omitempty"`
// Volume's name.
// +kubebuilder:validation:Required
Name *string `json:"name" tf:"name,omitempty"`
}
type VolumesObservation struct {
}
type VolumesParameters struct {
// Volume's name.
// +kubebuilder:validation:Required
Name *string `json:"name" tf:"name,omitempty"`
// The secret's value will be presented as the content of a file whose
// name is defined in the item path. If no items are defined, the name of
// the file is the secret_name.
// Structure is documented below.
// +kubebuilder:validation:Required
Secret []SecretParameters `json:"secret" tf:"secret,omitempty"`
}
// ServiceSpec defines the desired state of Service
type ServiceSpec struct {
v1.ResourceSpec `json:",inline"`
ForProvider ServiceParameters `json:"forProvider"`
}
// ServiceStatus defines the observed state of Service.
type ServiceStatus struct {
v1.ResourceStatus `json:",inline"`
AtProvider ServiceObservation `json:"atProvider,omitempty"`
}
// +kubebuilder:object:root=true
// Service is the Schema for the Services API. Service acts as a top-level container that manages a set of Routes and Configurations which implement a network service.
// +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,gcp}
type Service struct {
metav1.TypeMeta `json:",inline"`
metav1.ObjectMeta `json:"metadata,omitempty"`
Spec ServiceSpec `json:"spec"`
Status ServiceStatus `json:"status,omitempty"`
}
// +kubebuilder:object:root=true
// ServiceList contains a list of Services
type ServiceList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata,omitempty"`
Items []Service `json:"items"`
}
// Repository type metadata.
var (
Service_Kind = "Service"
Service_GroupKind = schema.GroupKind{Group: CRDGroup, Kind: Service_Kind}.String()
Service_KindAPIVersion = Service_Kind + "." + CRDGroupVersion.String()
Service_GroupVersionKind = CRDGroupVersion.WithKind(Service_Kind)
)
func init() {
SchemeBuilder.Register(&Service{}, &ServiceList{})
}