Skip to content

Commit

Permalink
promote min_node_cpus to GA for instance templates (#4701) (#8921)
Browse files Browse the repository at this point in the history
Signed-off-by: Modular Magician <[email protected]>
  • Loading branch information
modular-magician authored Apr 15, 2021
1 parent 6ca8113 commit 1fb0b93
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .changelog/4701.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:none

```
7 changes: 7 additions & 0 deletions google/resource_compute_instance_template.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ var (
"scheduling.0.automatic_restart",
"scheduling.0.preemptible",
"scheduling.0.node_affinities",
"scheduling.0.min_node_cpus",
}

shieldedInstanceTemplateConfigKeys = []string{
Expand Down Expand Up @@ -452,6 +453,12 @@ func resourceComputeInstanceTemplate() *schema.Resource {
DiffSuppressFunc: emptyOrDefaultStringSuppress(""),
Description: `Specifies node affinities or anti-affinities to determine which sole-tenant nodes your instances and managed instance groups will use as host systems.`,
},
"min_node_cpus": {
Type: schema.TypeInt,
Optional: true,
AtLeastOneOf: schedulingInstTemplateKeys,
Description: `Minimum number of cpus for the instance.`,
},
},
},
},
Expand Down
1 change: 1 addition & 0 deletions google/resource_compute_instance_template_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2129,6 +2129,7 @@ resource "google_compute_instance_template" "foobar" {
values = ["testinstancetemplate"]
}
min_node_cpus = 2
}
service_account {
Expand Down

0 comments on commit 1fb0b93

Please sign in to comment.