Commit Graph

4 Commits

Author SHA1 Message Date
Paul Stack e973176bb9 provider/dnsimple: Don't prompt the user for email address (#12619)
As part of the new changes to the DNSimple provider, we changed to use
the new API version. This requires a token and *not* email address

In order for backwards compatibility - we kept the email address in the
schema but we had the default as nil, meaning that Terraform was
prompting the user for it, they would enter it, then Terraform would
error out due to using a combination of token and email address

This commit makes the default email address an empty String. This means
we don't prompt the user
2017-03-13 10:07:53 +02:00
Simone Carletti 8ae31740e3 Upgrade DNSimple provider to API v2 (#10760)
* Replace DNSimple API client with the official Go client

* Upgrade DNSimple provider to use the new API v2

Acceptance tests pass:

```
=== RUN   TestProvider
--- PASS: TestProvider (0.00s)
=== RUN   TestProvider_impl
--- PASS: TestProvider_impl (0.00s)
=== RUN   TestAccDNSimpleRecord_Basic
--- PASS: TestAccDNSimpleRecord_Basic (2.67s)
=== RUN   TestAccDNSimpleRecord_Updated
--- PASS: TestAccDNSimpleRecord_Updated (1.88s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/dnsimple
```

Note that the code still has to be updated to pass the account ID
dynamically in place of "TODO-ACCOUNT".

* Refactor DNSimple provider to expose both client and config

The config is required as the new API wants to know the identifier of
the account you are operating to. The account is not stored in the
client (as the client can talk with different accounts), hence I need
to pass it as part of the config.

* Identify Terraform requests to DNSimple via UserAgent

* Upgrade to the latest dnsimple-go version

* Update docs

Provide upgrade instructions and update the docs for API v2.

* Remove rendundant type declaration
2017-03-02 05:12:34 +00:00
Jeff Mitchell f2bd1f45ab Move duplicated envDefaultFunc out of each provider and into Schema. 2015-01-16 17:25:39 +00:00
Sander van Harmelen cdee8c70ec Refactoring the DNSimple provider
With this refactor the DNSimple provider is updated to use the
schema.Provider approach released with TF 0.2.
2014-11-17 14:01:00 +01:00