mirror of
https://github.com/letic/terraform-provider-proxmox.git
synced 2024-10-05 02:01:04 +00:00
suppress diff on sensitive data when empty
This commit is contained in:
parent
9fa91fd42a
commit
821cf79a47
@ -2,13 +2,14 @@ package proxmox
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
pxapi "github.com/Telmate/proxmox-api-go/proxmox"
|
|
||||||
"github.com/hashicorp/terraform/helper/schema"
|
|
||||||
"log"
|
"log"
|
||||||
"path"
|
"path"
|
||||||
"strconv"
|
"strconv"
|
||||||
"strings"
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
|
pxapi "github.com/Telmate/proxmox-api-go/proxmox"
|
||||||
|
"github.com/hashicorp/terraform/helper/schema"
|
||||||
)
|
)
|
||||||
|
|
||||||
func resourceVmQemu() *schema.Resource {
|
func resourceVmQemu() *schema.Resource {
|
||||||
@ -110,6 +111,9 @@ func resourceVmQemu() *schema.Resource {
|
|||||||
Optional: true,
|
Optional: true,
|
||||||
Sensitive: true,
|
Sensitive: true,
|
||||||
DiffSuppressFunc: func(k, old, new string, d *schema.ResourceData) bool {
|
DiffSuppressFunc: func(k, old, new string, d *schema.ResourceData) bool {
|
||||||
|
if old == "" {
|
||||||
|
return true
|
||||||
|
}
|
||||||
return strings.TrimSpace(old) == strings.TrimSpace(new)
|
return strings.TrimSpace(old) == strings.TrimSpace(new)
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user