Skip to content

Commit

Permalink
fix: Allow ipv6 addresses for data.netbox_ipam_ip_addresses
Browse files Browse the repository at this point in the history
Fixes #107
  • Loading branch information
amhn committed May 4, 2022
1 parent 61362d7 commit c54cab7
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions netbox/data_netbox_ipam_ip_addresses.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package netbox

import (
"fmt"
"regexp"
"strconv"

"github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema"
Expand All @@ -19,9 +18,7 @@ func dataNetboxIpamIPAddresses() *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,
},
},
}
Expand Down

0 comments on commit c54cab7

Please sign in to comment.