Skip to content

Commit b11a1c0

Browse files
Adding delegatingServiceAccount to output (#14067) (#23094)
[upstream:13e8bd8141c71bb01ccc5eece83499e8ff1985fb] Signed-off-by: Modular Magician <[email protected]>
1 parent 704cc9e commit b11a1c0

File tree

4 files changed

+19
-0
lines changed

4 files changed

+19
-0
lines changed

.changelog/14067.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
```release-note:enhancement
2+
beyondcorp: added `delegatingServiceAccount` fields to `SecurityGateway` resource
3+
```

google/services/beyondcorp/resource_beyondcorp_security_gateway.go

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,11 @@ as a key.`,
118118
Computed: true,
119119
Description: `Output only. Timestamp when the resource was created.`,
120120
},
121+
"delegating_service_account": {
122+
Type: schema.TypeString,
123+
Computed: true,
124+
Description: `Service account used for operations that involve resources in consumer projects.`,
125+
},
121126
"external_ips": {
122127
Type: schema.TypeList,
123128
Computed: true,
@@ -301,6 +306,9 @@ func resourceBeyondcorpSecurityGatewayRead(d *schema.ResourceData, meta interfac
301306
if err := d.Set("name", flattenBeyondcorpSecurityGatewayName(res["name"], d, config)); err != nil {
302307
return fmt.Errorf("Error reading SecurityGateway: %s", err)
303308
}
309+
if err := d.Set("delegating_service_account", flattenBeyondcorpSecurityGatewayDelegatingServiceAccount(res["delegatingServiceAccount"], d, config)); err != nil {
310+
return fmt.Errorf("Error reading SecurityGateway: %s", err)
311+
}
304312

305313
return nil
306314
}
@@ -525,6 +533,10 @@ func flattenBeyondcorpSecurityGatewayName(v interface{}, d *schema.ResourceData,
525533
return v
526534
}
527535

536+
func flattenBeyondcorpSecurityGatewayDelegatingServiceAccount(v interface{}, d *schema.ResourceData, config *transport_tpg.Config) interface{} {
537+
return v
538+
}
539+
528540
func expandBeyondcorpSecurityGatewayHubs(v interface{}, d tpgresource.TerraformResourceData, config *transport_tpg.Config) (map[string]interface{}, error) {
529541
if v == nil {
530542
return map[string]interface{}{}, nil

google/services/beyondcorp/resource_beyondcorp_security_gateway_generated_meta.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ api_resource_type_kind: 'SecurityGateway'
77
autogen_status: true
88
fields:
99
- field: 'create_time'
10+
- field: 'delegating_service_account'
1011
- field: 'display_name'
1112
- field: 'external_ips'
1213
- field: 'hubs.hub.internet_gateway.assigned_ips'

website/docs/r/beyondcorp_security_gateway.html.markdown

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,9 @@ In addition to the arguments listed above, the following computed attributes are
124124
* `name` -
125125
Identifier. Name of the resource.
126126

127+
* `delegating_service_account` -
128+
Service account used for operations that involve resources in consumer projects.
129+
127130

128131
## Timeouts
129132

0 commit comments

Comments
 (0)