Skip to content

Commit 6b2f669

Browse files
Make location required on google_cloudfunctions2_function (#8928) (#15830)
Signed-off-by: Modular Magician <[email protected]>
1 parent b19741c commit 6b2f669

File tree

3 files changed

+13
-10
lines changed

3 files changed

+13
-10
lines changed

.changelog/8928.txt

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
```release-note:breaking-change
2+
cloudfunction2: made `location` required on `google_cloudfunctions2_function`
3+
```

google/services/cloudfunctions2/resource_cloudfunctions2_function.go

+6-6
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,12 @@ func ResourceCloudfunctions2function() *schema.Resource {
5454
),
5555

5656
Schema: map[string]*schema.Schema{
57+
"location": {
58+
Type: schema.TypeString,
59+
Required: true,
60+
ForceNew: true,
61+
Description: `The location of this cloud function.`,
62+
},
5763
"name": {
5864
Type: schema.TypeString,
5965
Required: true,
@@ -273,12 +279,6 @@ It must match the pattern projects/{project}/locations/{location}/keyRings/{key_
273279
Description: `A set of key/value label pairs associated with this Cloud Function.`,
274280
Elem: &schema.Schema{Type: schema.TypeString},
275281
},
276-
"location": {
277-
Type: schema.TypeString,
278-
Optional: true,
279-
ForceNew: true,
280-
Description: `The location of this cloud function.`,
281-
},
282282
"service_config": {
283283
Type: schema.TypeList,
284284
Optional: true,

website/docs/r/cloudfunctions2_function.html.markdown

+4-4
Original file line numberDiff line numberDiff line change
@@ -769,6 +769,10 @@ The following arguments are supported:
769769
A user-defined name of the function. Function names must
770770
be unique globally and match pattern `projects/*/locations/*/functions/*`.
771771

772+
* `location` -
773+
(Required)
774+
The location of this cloud function.
775+
772776

773777
- - -
774778

@@ -803,10 +807,6 @@ The following arguments are supported:
803807
Resource name of a KMS crypto key (managed by the user) used to encrypt/decrypt function resources.
804808
It must match the pattern projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}.
805809

806-
* `location` -
807-
(Optional)
808-
The location of this cloud function.
809-
810810
* `project` - (Optional) The ID of the project in which the resource belongs.
811811
If it is not provided, the provider project is used.
812812

0 commit comments

Comments
 (0)