Skip to content

Commit 6e6db53

Browse files
Cloudrun domain DSF (#4209) (#2700)
* Add DSF from cloudrun annotations to domain annotation * Add beta annotation to domain mapping test Signed-off-by: Modular Magician <[email protected]>
1 parent 38fed32 commit 6e6db53

File tree

4 files changed

+14
-4
lines changed

4 files changed

+14
-4
lines changed

.changelog/4209.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
```release-note:bug
2+
cloudrun: added diff suppress function for `google_cloud_run_domain_mapping` `metadata.annotations` to ignore API-set fields
3+
```

google-beta/resource_cloud_run_domain_mapping.go

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -82,10 +82,11 @@ func resourceCloudRunDomainMapping() *schema.Resource {
8282
project ID or project number.`,
8383
},
8484
"annotations": {
85-
Type: schema.TypeMap,
86-
Computed: true,
87-
Optional: true,
88-
ForceNew: true,
85+
Type: schema.TypeMap,
86+
Computed: true,
87+
Optional: true,
88+
ForceNew: true,
89+
DiffSuppressFunc: cloudrunAnnotationDiffSuppress,
8990
Description: `Annotations is a key value map stored with a resource that
9091
may be set by external tools to store and retrieve arbitrary metadata. More
9192
info: http://kubernetes.io/docs/user-guide/annotations`,

google-beta/resource_cloud_run_domain_mapping_generated_test.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,9 @@ resource "google_cloud_run_domain_mapping" "default" {
7878
7979
metadata {
8080
namespace = "%{namespace}"
81+
annotations = {
82+
"run.googleapis.com/launch-stage" = "BETA"
83+
}
8184
}
8285
8386
spec {

website/docs/r/cloud_run_domain_mapping.html.markdown

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,9 @@ resource "google_cloud_run_domain_mapping" "default" {
6464
6565
metadata {
6666
namespace = "my-project-name"
67+
annotations = {
68+
"run.googleapis.com/launch-stage" = "BETA"
69+
}
6770
}
6871
6972
spec {

0 commit comments

Comments
 (0)