Skip to content

Commit

Permalink
enh: Change ValidateFunc for ipam_ip_addresses to allow IPv6
Browse files Browse the repository at this point in the history
  • Loading branch information
amhn committed Mar 16, 2021
1 parent 8fa2759 commit cb13d6a
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions netbox/resource_netbox_ipam_ip_addresses.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,7 @@ func resourceNetboxIpamIPAddresses() *schema.Resource {
"address": {
Type: schema.TypeString,
Required: true,
ValidateFunc: validation.StringMatch(
regexp.MustCompile("^[0-9]{1,3}.[0-9]{1,3}.[0-9]{1,3}.[0-9]{1,3}/"+
"[0-9]{1,2}$"), "Must be like 192.168.56.1/24"),
ValidateFunc: validation.IsCIDR,
},
"custom_fields": {
Type: schema.TypeMap,
Expand Down

0 comments on commit cb13d6a

Please sign in to comment.