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

Make clear that ovh_domain_zone_record.subdomain can be an empty string #442

Merged
merged 1 commit into from
Aug 18, 2023

Conversation

Stoakes
Copy link
Member

@Stoakes Stoakes commented Jul 12, 2023

Description

ovh_domain_zone_record.subdomain attribute is specified as required. Yet, it can be empty.
This PR aims at saving the others a bit of time by making clear that you can create a record with the same name of the zone through Terraform.

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Improvement (improve existing resource(s) or datasource(s))
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update

How Has This Been Tested?

Manually against OVH API. Here is the snippet:

Terraform used the selected providers to generate the following execution plan. Resource actions are
indicated with the following symbols:
  + create
  ~ update in-place
-/+ destroy and then create replacement

Terraform will perform the following actions:

  # ovh_domain_zone_record.record_noprefix will be created
  + resource "ovh_domain_zone_record" "record_noprefix" {
      + fieldtype = "A"
      + id        = (known after apply)
      + target    = "111.111.111.111"
      + ttl       = 600
      + zone      = "some-domain-name-of-us.ovh"
    }

Plan: 1 to add.


Do you want to perform these actions?
  Terraform will perform the actions described above.
  Only 'yes' will be accepted to approve.

  Enter a value: yes


ovh_domain_zone_record.record_noprefix: Creating...
ovh_domain_zone_record.record_noprefix: Creation complete after 1s [id=redacted]

Apply complete! Resources: 1 added.

Test Configuration:

  • Terraform version: Terraform v1.4.2 on linux_amd64

  • Existing HCL configuration you used:

resource "ovh_domain_zone_record" "record_noprefix" {
  zone      = local.dns_zone
  subdomain = ""
  fieldtype = "A"
  ttl       = "600"
  target    = "111.111.111.111"
}

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings or issues
  • I have added acceptance tests that prove my fix is effective or that my feature works
  • New and existing acceptance tests pass locally with my changes
  • I ran succesfully go mod vendor if I added or modify go.mod file

@scraly scraly added the 0.33.0 label Aug 18, 2023
@scraly
Copy link
Collaborator

scraly commented Aug 18, 2023

Thanks :)

@scraly scraly merged commit 0fd1a66 into ovh:master Aug 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants