Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Validator on IPv4 only fields #107

Open
mburtless opened this issue Jan 22, 2020 · 2 comments
Open

Validator on IPv4 only fields #107

mburtless opened this issue Jan 22, 2020 · 2 comments

Comments

@mburtless
Copy link
Contributor

Terraform Version

All versions

Affected Resource(s)

ns1_zone

Terraform Configuration Files

resource "ns1_zone" "secondary_zone" {
    zone                   = "foo.com"
    primary                = "2620:78:2000:0e00::ffff"
    additional_primaries   = ["2620:78:2000:0e00::fffe"]
}

Debug Output

Panic Output

Expected Behavior

Config should fail with validation warning on IPv6 addresses in IPv4 only fields primary and additional_primaries. NS1 does not currently support IPv6 values for these fields.

Actual Behavior

Error: PUT https://api.nsone.net/v1/zones/0.2.3.0.0.0.2.8.7.0.0.0.2.6.2.ip6.arpa: 400 Input validation failed (Value u'2620:78:2000:0e00::ffff' for field '<obj>.secondary.primary_ip' does not match regular expression '^(?:[0-9]{1,3}\.){3}[0-9]{1,3}$')

  on modules/zone/secondary_zone/main.tf line 4, in resource "ns1_zone" "secondary_zone":
   4: resource "ns1_zone" "secondary_zone" {

Steps to Reproduce

Please list the steps required to reproduce the issue, for example:

  1. terraform apply

Important Factoids

References

@chris-zenfolio
Copy link

I opened NS1 Support Ticket 23797 for a feature request to support IPv6 in the API. I will comment when I have a reference to the actual feature request.

@chris-zenfolio
Copy link

The intent of the feature request info being here is not to track the feature as part of the TF provider, but to communicate with the TF Provider developers (aka "you") that a request was submitted and that you can track that stuff internally for later story development. Not fully-supporting IPv6 is a major shortcoming of NS1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants