Skip to content

Commit e3b088a

Browse files
Merge branch 'sts_path' of github.com:gurusai-voleti/magic-modules into sts_path
2 parents bedcba7 + 58089c5 commit e3b088a

73 files changed

Lines changed: 1508 additions & 93 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.ci/infra/terraform/main.tf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -306,6 +306,7 @@ module "project-services" {
306306
"migrationcenter.googleapis.com",
307307
"ml.googleapis.com",
308308
"mobilecrashreporting.googleapis.com",
309+
"modelarmor.googleapis.com",
309310
"monitoring.googleapis.com",
310311
"multiclustermetering.googleapis.com",
311312
"netapp.googleapis.com",

mmv1/api/type.go

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -296,6 +296,20 @@ type Type struct {
296296

297297
// The field is not present in CAI asset
298298
IsMissingInCai bool `yaml:"is_missing_in_cai,omitempty"`
299+
300+
// A custom expander replaces the default expander for an attribute.
301+
// It is called as part of tfplan2cai conversion if
302+
// object.input is false. It can return an object of any type,
303+
// so the function header *is* part of the custom code template.
304+
// As with flatten, `property` and `prefix` are available.
305+
CustomTgcExpand string `yaml:"custom_tgc_expand,omitempty"`
306+
307+
// A custom flattener replaces the default flattener for an attribute.
308+
// It is called as part of cai2hcl conversion. It can return an object of any type,
309+
// so the function header *is* a part of the custom code template. To help with
310+
// creating the function header, `property` and `prefix` are available,
311+
// just as they are in the standard flattener template.
312+
CustomTgcFlatten string `yaml:"custom_tgc_flatten,omitempty"`
299313
}
300314

301315
const MAX_NAME = 20

mmv1/products/bigqueryanalyticshub/DataExchange.yaml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -149,5 +149,4 @@ properties:
149149
- name: 'logLinkedDatasetQueryUserEmail'
150150
type: Boolean
151151
description:
152-
If true, subscriber email logging is enabled and all queries on the linked dataset will log the email address of the querying user.
153-
immutable: true
152+
If true, subscriber email logging is enabled and all queries on the linked dataset will log the email address of the querying user. Once enabled, this setting cannot be turned off.

mmv1/products/bigqueryanalyticshub/Listing.yaml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -240,5 +240,4 @@ properties:
240240
- name: 'logLinkedDatasetQueryUserEmail'
241241
type: Boolean
242242
description:
243-
If true, subscriber email logging is enabled and all queries on the linked dataset will log the email address of the querying user.
244-
immutable: true
243+
If true, subscriber email logging is enabled and all queries on the linked dataset will log the email address of the querying user. Once enabled, this setting cannot be turned off.

mmv1/products/cloudidentity/GroupMembership.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ timeouts:
3737
update_minutes: 20
3838
delete_minutes: 20
3939
custom_code:
40+
pre_create: templates/terraform/pre_create/cloud_identity_group_membership.go.tmpl
4041
post_create: 'templates/terraform/post_create/set_computed_name.tmpl'
4142
custom_update: 'templates/terraform/custom_update/cloud_identity_group_membership.go.tmpl'
4243
post_import: 'templates/terraform/post_import/cloud_identity_group_membership.go.tmpl'
@@ -62,6 +63,12 @@ examples:
6263
identity_user: 'IDENTITY_USER'
6364
# Has a handwritten test due to CloudIdentityGroup-related tests needing to run synchronously
6465
exclude_test: true
66+
virtual_fields:
67+
- name: 'create_ignore_already_exists'
68+
description: |
69+
If set to true, skip group member creation if a membership with the same name already exists. Defaults to false.
70+
type: Boolean
71+
default_value: false
6572
parameters:
6673
- name: 'group'
6774
type: ResourceRef

mmv1/products/cloudrunv2/Job.yaml

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,6 +125,14 @@ examples:
125125
cloud_run_job_name: 'cloudrun-job'
126126
ignore_read_extra:
127127
- 'deletion_protection'
128+
- name: 'cloudrunv2_job_gpu'
129+
min_version: 'beta'
130+
primary_resource_id: 'default'
131+
primary_resource_name: 'fmt.Sprintf("tf-test-cloudrun-job%s", context["random_suffix"])'
132+
vars:
133+
cloud_run_job_name: 'cloudrun-job'
134+
ignore_read_extra:
135+
- 'deletion_protection'
128136
virtual_fields:
129137
- name: 'deletion_protection'
130138
description: |
@@ -397,7 +405,7 @@ properties:
397405
- name: 'limits'
398406
type: KeyValuePairs
399407
description: |-
400-
Only memory and CPU are supported. Use key `cpu` for CPU limit and `memory` for memory limit. Note: The only supported values for CPU are '1', '2', '4', and '8'. Setting 4 CPU requires at least 2Gi of memory. 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
408+
Only memory, CPU, and nvidia.com/gpu are supported. Use key `cpu` for CPU limit, `memory` for memory limit, `nvidia.com/gpu` for gpu limit. Note: The only supported values for CPU are '1', '2', '4', and '8'. Setting 4 CPU requires at least 2Gi of memory. 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
401409
default_from_api: true
402410
- name: 'ports'
403411
type: Array
@@ -765,6 +773,16 @@ properties:
765773
Number of retries allowed per Task, before marking this Task failed. Defaults to 3. Minimum value is 0.
766774
send_empty_value: true
767775
default_value: 3
776+
- name: 'nodeSelector'
777+
min_version: beta
778+
type: NestedObject
779+
description: Node Selector describes the hardware requirements of the resources.
780+
properties:
781+
- name: 'accelerator'
782+
type: String
783+
description:
784+
The GPU to attach to an instance. See https://cloud.google.com/run/docs/configuring/jobs/gpu for configuring GPU.
785+
required: true
768786
- name: 'observedGeneration'
769787
type: String
770788
description: |

mmv1/products/compute/Autoscaler.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ async:
4242
result:
4343
resource_inside_response: false
4444
collection_url_key: 'items'
45+
include_in_tgc_next_DO_NOT_USE: true
4546
custom_code:
4647
sweeper:
4748
url_substitutions:
@@ -83,6 +84,8 @@ parameters:
8384
ignore_read: true
8485
default_from_api: true
8586
custom_expand: 'templates/terraform/custom_expand/resourceref_with_validation.go.tmpl'
87+
custom_tgc_flatten: 'templates/tgc_next/custom_flatten/compute_auto_scaler.go.tmpl'
88+
custom_tgc_expand: 'templates/tgc_next/custom_expand/compute_auto_scaler_zone.go.tmpl'
8689
resource: 'Zone'
8790
imports: 'name'
8891
properties:
@@ -423,5 +426,6 @@ properties:
423426
URL of the managed instance group that this autoscaler will scale.
424427
required: true
425428
custom_expand: 'templates/terraform/custom_expand/compute_full_url.tmpl'
429+
custom_tgc_expand: 'templates/tgc_next/custom_expand/compute_full_url.go.tmpl'
426430
resource: 'InstanceGroupManager'
427431
imports: 'selfLink'

mmv1/products/compute/Disk.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ examples:
7373
vars:
7474
disk_name: 'test-disk'
7575
- name: 'disk_async'
76-
primary_resource_id: 'primary'
76+
primary_resource_id: 'secondary'
7777
primary_resource_name: 'fmt.Sprintf("tf-test-test-disk%s", context["random_suffix"])'
7878
vars:
7979
disk_name: 'async-test-disk'

mmv1/products/compute/NetworkFirewallPolicy.yaml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,17 @@ properties:
5757
- name: 'description'
5858
type: String
5959
description: An optional description of this resource. Provide this property when you create the resource.
60+
- name: 'policyType'
61+
type: Enum
62+
immutable: true
63+
description: |
64+
Policy type is used to determine which resources (networks) the policy can be associated with.
65+
A policy can be associated with a network only if the network has the matching policyType in its network profile.
66+
Different policy types may support some of the Firewall Rules features.
67+
min_version: 'beta'
68+
default_from_api: true
69+
enum_values:
70+
- 'VPC_POLICY'
6071
- name: 'fingerprint'
6172
type: Fingerprint
6273
description: Fingerprint of the resource. This field is used internally during updates of this resource.

mmv1/products/compute/NetworkFirewallPolicyWithRules.yaml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,17 @@ properties:
7676
- name: 'description'
7777
type: String
7878
description: An optional description of this resource.
79+
- name: 'policyType'
80+
type: Enum
81+
immutable: true
82+
description: |
83+
Policy type is used to determine which resources (networks) the policy can be associated with.
84+
A policy can be associated with a network only if the network has the matching policyType in its network profile.
85+
Different policy types may support some of the Firewall Rules features.
86+
default_from_api: true
87+
min_version: 'beta'
88+
enum_values:
89+
- 'VPC_POLICY'
7990
- name: 'rule'
8091
type: Array
8192
description: A list of firewall policy rules.

0 commit comments

Comments
 (0)