1apiVersion: apiextensions.k8s.io/v1
2kind: CustomResourceDefinition
3metadata:
4 annotations:
5 cnrm.cloud.google.com/version: 0.0.0-dev
6 creationTimestamp: null
7 labels:
8 cnrm.cloud.google.com/managed-by-kcc: "true"
9 cnrm.cloud.google.com/stability-level: stable
10 cnrm.cloud.google.com/system: "true"
11 cnrm.cloud.google.com/tf2crd: "true"
12 name: sqlinstances.sql.cnrm.cloud.google.com
13spec:
14 group: sql.cnrm.cloud.google.com
15 names:
16 categories:
17 - gcp
18 kind: SQLInstance
19 plural: sqlinstances
20 shortNames:
21 - gcpsqlinstance
22 - gcpsqlinstances
23 singular: sqlinstance
24 preserveUnknownFields: false
25 scope: Namespaced
26 versions:
27 - additionalPrinterColumns:
28 - jsonPath: .metadata.creationTimestamp
29 name: Age
30 type: date
31 - description: When 'True', the most recent reconcile of the resource succeeded
32 jsonPath: .status.conditions[?(@.type=='Ready')].status
33 name: Ready
34 type: string
35 - description: The reason for the value in 'Ready'
36 jsonPath: .status.conditions[?(@.type=='Ready')].reason
37 name: Status
38 type: string
39 - description: The last transition time for the value in 'Status'
40 jsonPath: .status.conditions[?(@.type=='Ready')].lastTransitionTime
41 name: Status Age
42 type: date
43 name: v1beta1
44 schema:
45 openAPIV3Schema:
46 properties:
47 apiVersion:
48 description: 'apiVersion defines the versioned schema of this representation
49 of an object. Servers should convert recognized schemas to the latest
50 internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources'
51 type: string
52 kind:
53 description: 'kind is a string value representing the REST resource this
54 object represents. Servers may infer this from the endpoint the client
55 submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds'
56 type: string
57 metadata:
58 type: object
59 spec:
60 properties:
61 databaseVersion:
62 default: MYSQL_5_6
63 description: The MySQL, PostgreSQL or SQL Server (beta) version to
64 use. Supported values include MYSQL_5_6, MYSQL_5_7, MYSQL_8_0, POSTGRES_9_6,
65 POSTGRES_10, POSTGRES_11, POSTGRES_12, POSTGRES_13, POSTGRES_14,
66 SQLSERVER_2017_STANDARD, SQLSERVER_2017_ENTERPRISE, SQLSERVER_2017_EXPRESS,
67 SQLSERVER_2017_WEB. Database Version Policies includes an up-to-date
68 reference of supported versions.
69 type: string
70 encryptionKMSCryptoKeyRef:
71 oneOf:
72 - not:
73 required:
74 - external
75 required:
76 - name
77 - not:
78 anyOf:
79 - required:
80 - name
81 - required:
82 - namespace
83 required:
84 - external
85 properties:
86 external:
87 description: 'Allowed value: The `selfLink` field of a `KMSCryptoKey`
88 resource.'
89 type: string
90 name:
91 description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
92 type: string
93 namespace:
94 description: 'Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/'
95 type: string
96 type: object
97 instanceType:
98 description: The type of the instance. The valid values are:- 'SQL_INSTANCE_TYPE_UNSPECIFIED',
99 'CLOUD_SQL_INSTANCE', 'ON_PREMISES_INSTANCE' and 'READ_REPLICA_INSTANCE'.
100 type: string
101 maintenanceVersion:
102 description: Maintenance version.
103 type: string
104 masterInstanceRef:
105 oneOf:
106 - not:
107 required:
108 - external
109 required:
110 - name
111 - not:
112 anyOf:
113 - required:
114 - name
115 - required:
116 - namespace
117 required:
118 - external
119 properties:
120 external:
121 description: 'Allowed value: The `name` field of a `SQLInstance`
122 resource.'
123 type: string
124 name:
125 description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
126 type: string
127 namespace:
128 description: 'Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/'
129 type: string
130 type: object
131 region:
132 description: Immutable. The region the instance will sit in. Note,
133 Cloud SQL is not available in all regions. A valid region must be
134 provided to use this resource. If a region is not provided in the
135 resource definition, the provider region will be used instead, but
136 this will be an apply-time error for instances if the provider region
137 is not supported with Cloud SQL. If you choose not to provide the
138 region argument for this resource, make sure you understand this.
139 type: string
140 replicaConfiguration:
141 description: The configuration for replication.
142 properties:
143 caCertificate:
144 description: Immutable. PEM representation of the trusted CA's
145 x509 certificate.
146 type: string
147 clientCertificate:
148 description: Immutable. PEM representation of the replica's x509
149 certificate.
150 type: string
151 clientKey:
152 description: Immutable. PEM representation of the replica's private
153 key. The corresponding public key in encoded in the client_certificate.
154 type: string
155 connectRetryInterval:
156 description: Immutable. The number of seconds between connect
157 retries. MySQL's default is 60 seconds.
158 type: integer
159 dumpFilePath:
160 description: Immutable. Path to a SQL file in Google Cloud Storage
161 from which replica instances are created. Format is gs://bucket/filename.
162 type: string
163 failoverTarget:
164 description: Immutable. Specifies if the replica is the failover
165 target. If the field is set to true the replica will be designated
166 as a failover replica. If the master instance fails, the replica
167 instance will be promoted as the new master instance.
168 type: boolean
169 masterHeartbeatPeriod:
170 description: Immutable. Time in ms between replication heartbeats.
171 type: integer
172 password:
173 description: Immutable. Password for the replication connection.
174 oneOf:
175 - not:
176 required:
177 - valueFrom
178 required:
179 - value
180 - not:
181 required:
182 - value
183 required:
184 - valueFrom
185 properties:
186 value:
187 description: Value of the field. Cannot be used if 'valueFrom'
188 is specified.
189 type: string
190 valueFrom:
191 description: Source for the field's value. Cannot be used
192 if 'value' is specified.
193 properties:
194 secretKeyRef:
195 description: Reference to a value with the given key in
196 the given Secret in the resource's namespace.
197 properties:
198 key:
199 description: Key that identifies the value to be extracted.
200 type: string
201 name:
202 description: Name of the Secret to extract a value
203 from.
204 type: string
205 required:
206 - name
207 - key
208 type: object
209 type: object
210 type: object
211 sslCipher:
212 description: Immutable. Permissible ciphers for use in SSL encryption.
213 type: string
214 username:
215 description: Immutable. Username for replication connection.
216 type: string
217 verifyServerCertificate:
218 description: Immutable. True if the master's common name value
219 is checked during the SSL handshake.
220 type: boolean
221 type: object
222 resourceID:
223 description: Immutable. Optional. The name of the resource. Used for
224 creation and acquisition. When unset, the value of `metadata.name`
225 is used as the default.
226 type: string
227 rootPassword:
228 description: Initial root password. Required for MS SQL Server.
229 oneOf:
230 - not:
231 required:
232 - valueFrom
233 required:
234 - value
235 - not:
236 required:
237 - value
238 required:
239 - valueFrom
240 properties:
241 value:
242 description: Value of the field. Cannot be used if 'valueFrom'
243 is specified.
244 type: string
245 valueFrom:
246 description: Source for the field's value. Cannot be used if 'value'
247 is specified.
248 properties:
249 secretKeyRef:
250 description: Reference to a value with the given key in the
251 given Secret in the resource's namespace.
252 properties:
253 key:
254 description: Key that identifies the value to be extracted.
255 type: string
256 name:
257 description: Name of the Secret to extract a value from.
258 type: string
259 required:
260 - name
261 - key
262 type: object
263 type: object
264 type: object
265 settings:
266 description: The settings to use for the database. The configuration
267 is detailed below.
268 properties:
269 activationPolicy:
270 description: This specifies when the instance should be active.
271 Can be either ALWAYS, NEVER or ON_DEMAND.
272 type: string
273 activeDirectoryConfig:
274 properties:
275 domain:
276 description: Domain name of the Active Directory for SQL Server
277 (e.g., mydomain.com).
278 type: string
279 required:
280 - domain
281 type: object
282 advancedMachineFeatures:
283 properties:
284 threadsPerCore:
285 description: The number of threads per physical core. Can
286 be 1 or 2.
287 type: integer
288 type: object
289 authorizedGaeApplications:
290 description: |-
291 DEPRECATED. This property is only applicable to First Generation instances, and First Generation instances are now deprecated. see https://cloud.google.com/sql/docs/mysql/deprecation-notice for information on how to upgrade to Second Generation instances.
292 Specifying this field has no-ops; it's recommended to remove this field from your configuration.
293 items:
294 type: string
295 type: array
296 availabilityType:
297 description: |-
298 The availability type of the Cloud SQL instance, high availability
299 (REGIONAL) or single zone (ZONAL). For all instances, ensure that
300 settings.backup_configuration.enabled is set to true.
301 For MySQL instances, ensure that settings.backup_configuration.binary_log_enabled is set to true.
302 For Postgres instances, ensure that settings.backup_configuration.point_in_time_recovery_enabled
303 is set to true. Defaults to ZONAL.
304 type: string
305 backupConfiguration:
306 properties:
307 backupRetentionSettings:
308 properties:
309 retainedBackups:
310 description: Number of backups to retain.
311 type: integer
312 retentionUnit:
313 description: The unit that 'retainedBackups' represents.
314 Defaults to COUNT.
315 type: string
316 required:
317 - retainedBackups
318 type: object
319 binaryLogEnabled:
320 description: True if binary logging is enabled. If settings.backup_configuration.enabled
321 is false, this must be as well. Can only be used with MySQL.
322 type: boolean
323 enabled:
324 description: True if backup configuration is enabled.
325 type: boolean
326 location:
327 description: Location of the backup configuration.
328 type: string
329 pointInTimeRecoveryEnabled:
330 description: True if Point-in-time recovery is enabled.
331 type: boolean
332 startTime:
333 description: HH:MM format time indicating when backup configuration
334 starts.
335 type: string
336 transactionLogRetentionDays:
337 description: The number of days of transaction logs we retain
338 for point in time restore, from 1-7.
339 type: integer
340 type: object
341 collation:
342 description: Immutable. The name of server instance collation.
343 type: string
344 connectorEnforcement:
345 description: Specifies if connections must use Cloud SQL connectors.
346 type: string
347 crashSafeReplication:
348 description: |-
349 DEPRECATED. This property is only applicable to First Generation instances, and First Generation instances are now deprecated. see https://cloud.google.com/sql/docs/mysql/deprecation-notice for information on how to upgrade to Second Generation instances.
350 Specifying this field has no-ops; it's recommended to remove this field from your configuration.
351 type: boolean
352 databaseFlags:
353 items:
354 properties:
355 name:
356 description: Name of the flag.
357 type: string
358 value:
359 description: Value of the flag.
360 type: string
361 required:
362 - name
363 - value
364 type: object
365 type: array
366 deletionProtectionEnabled:
367 description: Configuration to protect against accidental instance
368 deletion.
369 type: boolean
370 denyMaintenancePeriod:
371 properties:
372 endDate:
373 description: End date before which maintenance will not take
374 place. The date is in format yyyy-mm-dd i.e., 2020-11-01,
375 or mm-dd, i.e., 11-01.
376 type: string
377 startDate:
378 description: Start date after which maintenance will not take
379 place. The date is in format yyyy-mm-dd i.e., 2020-11-01,
380 or mm-dd, i.e., 11-01.
381 type: string
382 time:
383 description: 'Time in UTC when the "deny maintenance period"
384 starts on start_date and ends on end_date. The time is in
385 format: HH:mm:SS, i.e., 00:00:00.'
386 type: string
387 required:
388 - endDate
389 - startDate
390 - time
391 type: object
392 diskAutoresize:
393 description: Enables auto-resizing of the storage size. Defaults
394 to true.
395 type: boolean
396 diskAutoresizeLimit:
397 description: The maximum size, in GB, to which storage capacity
398 can be automatically increased. The default value is 0, which
399 specifies that there is no limit.
400 type: integer
401 diskSize:
402 description: The size of data disk, in GB. Size of a running instance
403 cannot be reduced but can be increased. The minimum value is
404 10GB.
405 type: integer
406 diskType:
407 description: 'Immutable. The type of data disk: PD_SSD or PD_HDD.
408 Defaults to PD_SSD.'
409 type: string
410 insightsConfig:
411 description: Configuration of Query Insights.
412 properties:
413 queryInsightsEnabled:
414 description: True if Query Insights feature is enabled.
415 type: boolean
416 queryPlansPerMinute:
417 description: Number of query execution plans captured by Insights
418 per minute for all queries combined. Between 0 and 20. Default
419 to 5.
420 type: integer
421 queryStringLength:
422 description: Maximum query length stored in bytes. Between
423 256 and 4500. Default to 1024.
424 type: integer
425 recordApplicationTags:
426 description: True if Query Insights will record application
427 tags from query when enabled.
428 type: boolean
429 recordClientAddress:
430 description: True if Query Insights will record client address
431 when enabled.
432 type: boolean
433 type: object
434 ipConfiguration:
435 properties:
436 allocatedIpRange:
437 description: 'The name of the allocated ip range for the private
438 ip CloudSQL instance. For example: "google-managed-services-default".
439 If set, the instance ip will be created in the allocated
440 range. The range name must comply with RFC 1035. Specifically,
441 the name must be 1-63 characters long and match the regular
442 expression [a-z]([-a-z0-9]*[a-z0-9])?.'
443 type: string
444 authorizedNetworks:
445 items:
446 properties:
447 expirationTime:
448 type: string
449 name:
450 type: string
451 value:
452 type: string
453 required:
454 - value
455 type: object
456 type: array
457 enablePrivatePathForGoogleCloudServices:
458 description: Whether Google Cloud services such as BigQuery
459 are allowed to access data in this Cloud SQL instance over
460 a private IP connection. SQLSERVER database type is not
461 supported.
462 type: boolean
463 ipv4Enabled:
464 description: Whether this Cloud SQL instance should be assigned
465 a public IPV4 address. At least ipv4_enabled must be enabled
466 or a private_network must be configured.
467 type: boolean
468 privateNetworkRef:
469 oneOf:
470 - not:
471 required:
472 - external
473 required:
474 - name
475 - not:
476 anyOf:
477 - required:
478 - name
479 - required:
480 - namespace
481 required:
482 - external
483 properties:
484 external:
485 description: 'Allowed value: The `selfLink` field of a
486 `ComputeNetwork` resource.'
487 type: string
488 name:
489 description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
490 type: string
491 namespace:
492 description: 'Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/'
493 type: string
494 type: object
495 requireSsl:
496 type: boolean
497 type: object
498 locationPreference:
499 properties:
500 followGaeApplication:
501 description: A Google App Engine application whose zone to
502 remain in. Must be in the same region as this instance.
503 type: string
504 secondaryZone:
505 description: The preferred Compute Engine zone for the secondary/failover.
506 type: string
507 zone:
508 description: The preferred compute engine zone.
509 type: string
510 type: object
511 maintenanceWindow:
512 description: Declares a one-hour maintenance window when an Instance
513 can automatically restart to apply updates. The maintenance
514 window is specified in UTC time.
515 properties:
516 day:
517 description: Day of week (1-7), starting on Monday.
518 type: integer
519 hour:
520 description: Hour of day (0-23), ignored if day not set.
521 type: integer
522 updateTrack:
523 description: Receive updates earlier (canary) or later (stable).
524 type: string
525 type: object
526 passwordValidationPolicy:
527 properties:
528 complexity:
529 description: Password complexity.
530 type: string
531 disallowUsernameSubstring:
532 description: Disallow username as a part of the password.
533 type: boolean
534 enablePasswordPolicy:
535 description: Whether the password policy is enabled or not.
536 type: boolean
537 minLength:
538 description: Minimum number of characters allowed.
539 type: integer
540 passwordChangeInterval:
541 description: Minimum interval after which the password can
542 be changed. This flag is only supported for PostgresSQL.
543 type: string
544 reuseInterval:
545 description: Number of previous passwords that cannot be reused.
546 type: integer
547 required:
548 - enablePasswordPolicy
549 type: object
550 pricingPlan:
551 description: Pricing plan for this instance, can only be PER_USE.
552 type: string
553 replicationType:
554 description: |-
555 DEPRECATED. This property is only applicable to First Generation instances, and First Generation instances are now deprecated. see https://cloud.google.com/sql/docs/mysql/deprecation-notice for information on how to upgrade to Second Generation instances.
556 Specifying this field has no-ops; it's recommended to remove this field from your configuration.
557 type: string
558 sqlServerAuditConfig:
559 properties:
560 bucketRef:
561 description: The name of the destination bucket (e.g., gs://mybucket).
562 oneOf:
563 - not:
564 required:
565 - external
566 required:
567 - name
568 - not:
569 anyOf:
570 - required:
571 - name
572 - required:
573 - namespace
574 required:
575 - external
576 properties:
577 external:
578 description: 'Allowed value: The `url` field of a `StorageBucket`
579 resource.'
580 type: string
581 name:
582 description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
583 type: string
584 namespace:
585 description: 'Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/'
586 type: string
587 type: object
588 retentionInterval:
589 description: 'How long to keep generated audit files. A duration
590 in seconds with up to nine fractional digits, terminated
591 by ''s''. Example: "3.5s"..'
592 type: string
593 uploadInterval:
594 description: 'How often to upload generated audit files. A
595 duration in seconds with up to nine fractional digits, terminated
596 by ''s''. Example: "3.5s".'
597 type: string
598 type: object
599 tier:
600 description: The machine type to use. See tiers for more details
601 and supported versions. Postgres supports only shared-core machine
602 types, and custom machine types such as db-custom-2-13312. See
603 the Custom Machine Type Documentation to learn about specifying
604 custom machine types.
605 type: string
606 timeZone:
607 description: Immutable. The time_zone to be used by the database
608 engine (supported only for SQL Server), in SQL Server timezone
609 format.
610 type: string
611 required:
612 - tier
613 type: object
614 required:
615 - settings
616 type: object
617 status:
618 properties:
619 availableMaintenanceVersions:
620 description: Available Maintenance versions.
621 items:
622 type: string
623 type: array
624 conditions:
625 description: Conditions represent the latest available observation
626 of the resource's current state.
627 items:
628 properties:
629 lastTransitionTime:
630 description: Last time the condition transitioned from one status
631 to another.
632 type: string
633 message:
634 description: Human-readable message indicating details about
635 last transition.
636 type: string
637 reason:
638 description: Unique, one-word, CamelCase reason for the condition's
639 last transition.
640 type: string
641 status:
642 description: Status is the status of the condition. Can be True,
643 False, Unknown.
644 type: string
645 type:
646 description: Type is the type of the condition.
647 type: string
648 type: object
649 type: array
650 connectionName:
651 description: The connection name of the instance to be used in connection
652 strings. For example, when connecting with Cloud SQL Proxy.
653 type: string
654 firstIpAddress:
655 type: string
656 instanceType:
657 description: The type of the instance. The valid values are:- 'SQL_INSTANCE_TYPE_UNSPECIFIED',
658 'CLOUD_SQL_INSTANCE', 'ON_PREMISES_INSTANCE' and 'READ_REPLICA_INSTANCE'.
659 type: string
660 ipAddress:
661 items:
662 properties:
663 ipAddress:
664 type: string
665 timeToRetire:
666 type: string
667 type:
668 type: string
669 type: object
670 type: array
671 observedGeneration:
672 description: ObservedGeneration is the generation of the resource
673 that was most recently observed by the Config Connector controller.
674 If this is equal to metadata.generation, then that means that the
675 current reported status reflects the most recent desired state of
676 the resource.
677 type: integer
678 privateIpAddress:
679 type: string
680 publicIpAddress:
681 type: string
682 selfLink:
683 description: The URI of the created resource.
684 type: string
685 serverCaCert:
686 properties:
687 cert:
688 description: The CA Certificate used to connect to the SQL Instance
689 via SSL.
690 type: string
691 commonName:
692 description: The CN valid for the CA Cert.
693 type: string
694 createTime:
695 description: Creation time of the CA Cert.
696 type: string
697 expirationTime:
698 description: Expiration time of the CA Cert.
699 type: string
700 sha1Fingerprint:
701 description: SHA Fingerprint of the CA Cert.
702 type: string
703 type: object
704 serviceAccountEmailAddress:
705 description: The service account email address assigned to the instance.
706 type: string
707 type: object
708 required:
709 - spec
710 type: object
711 served: true
712 storage: true
713 subresources:
714 status: {}
715status:
716 acceptedNames:
717 kind: ""
718 plural: ""
719 conditions: []
720 storedVersions: []
View as plain text