cf-terraforming icon indicating copy to clipboard operation
cf-terraforming copied to clipboard

Configuration is Invalid Error with valid configuration

Open AliSajid opened this issue 3 years ago • 0 comments

Confirmation

  • [X] My issue isn't already found on the issue tracker.
  • [X] I have replicated my issue using the latest version of the library and it is still present.

cf-terraforming version

cf-terraforming v0.8.4

Expected outcome

I am trying to run an import with

cf-terraforming generate --resource-type cloudflare_zone -v -a "<ACCOUNT_ID>"

I would expect this to succeed. However, that does not happen. The CLOUDFLARE_API_TOKEN env var is set to the correct value and I can use it to access the cloudflare API using curl or insomnia easily.

The terraform configuration is valid as reported by terraform validate and I can plan and apply it without issue as well.

Actual outcome

cf-terraforming generate --resource-type cloudflare_zone -v -a "<ACCOUNT_ID>"
   
DEBU[0000] initializing cloudflare-go with API Token     account_Id=<ACCOUNT_ID> zone_id=

DEBU[0000] configuring Cloudflare API with account       account_id=<ACCOUNT_ID>

DEBU[0035] initializing Terraform in .                  

FATA[0036] configuration is invalid

Steps to reproduce

  1. Set the CLOUDFLARE_API_TOKEN variable
  2. run cf-terraforming generate --resource-type cloudflare_zone -v -a "<ACCOUNT_ID>"
  3. Error

References

No response

AliSajid avatar Oct 17 '22 18:10 AliSajid