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

providers/cloudflare: record can manage apex records #6449

Merged
merged 3 commits into from
May 3, 2016

Conversation

mitchellh
Copy link
Contributor

Apex records must be created by specifying "@" as the name, but this caused Refresh and Delete errors since after create the "@" is stripped from the API results. This modifies the resource to automatically strip this when looking for the record.

Test included.

@catsby
Copy link
Contributor

catsby commented May 3, 2016

LGTM, think we may have a test account record conflict with our nightly acceptance tests to sort out though

@mitchellh
Copy link
Contributor Author

In the course of testing this, @clint found a huge issue with the provider. Due to the way it looks up records, it is capable of finding (and deleting!) incorrect records. This is caused by the fact that it looks up records by name, rather than by unique ID that Cloudflare returns. Upon further investigation, the library that we use and the official Cloudflare Go library don't support getting that ID. I've forked and made a PR to the official Cloudflare repo to do this.

This PR is now updated to use a new lib (my fork of the official Cloudflare Go lib) so that we properly use record IDs. This cleans up the code a lot. All prior tests pass:

2016-05-03 at 9 46 am

Apex records must be created by specifying "@" as the name, but this
caused Refresh and Delete errors.
The most improtant change is using record IDs as identifiers.
@catsby
Copy link
Contributor

catsby commented May 3, 2016

Checks out 👍

@ghost
Copy link

ghost commented Apr 26, 2020

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@ghost ghost locked and limited conversation to collaborators Apr 26, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants