Skip to content

Commit

Permalink
supress disk image in terrafrom plan
Browse files Browse the repository at this point in the history
  • Loading branch information
uzaxirr committed Jun 18, 2024
1 parent 5856862 commit 6db4806
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions civo/instances/resource_instance.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,10 @@ func ResourceInstance() *schema.Resource {
Computed: true,
ExactlyOneOf: []string{"template", "disk_image"},
Description: "The ID for the disk image to use to build the instance",
DiffSuppressFunc: func(k, old, new string, d *schema.ResourceData) bool {
// Suppress changes if the old value is non-empty and different from the new value
return old != "" && old != new
},
},
"initial_user": {
Type: schema.TypeString,
Expand Down

0 comments on commit 6db4806

Please sign in to comment.