scastria / terraform-provider-apigee

Mozilla Public License 2.0
21 stars 19 forks source link

Bad Gateway 501 or Unauthorized 401 #41

Closed pysiok1983 closed 2 years ago

pysiok1983 commented 2 years ago

Hi, I am trying to use this repo but seems I have an issue using this terraform provider for APIgeeX. I generated token from the shell:

gcloud auth activate-service-account --key-file=sa.json
gcloud auth print-access-token

and using this token for the provided. All the time I am receiving the same error:

apigee_proxy.proxy_001: Creating...
╷
│ Error: Status 401: Message: Unauthorized: 
│ 
│   with apigee_proxy.proxy_001,
│   on 04_apix.tf line 159, in resource "apigee_proxy" "proxy_001":
│  159: resource "apigee_proxy" "proxy_001" {

Are you able to help?

scastria commented 2 years ago

If you set environment variable TF_LOG to TRACE, you should get a lot more detail such that you can see the actual rest api call that is failing.

scastria commented 2 years ago

Also, how are you configuring the provider? Obviously, you can obscure any secret information, if needed.

scastria commented 2 years ago

Closing due to no activity