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

Error: "context deadline exceeded (Client.Timeout exceeded while awaiting headers)" #82

Open
wesmason opened this issue Aug 16, 2022 · 1 comment

Comments

@wesmason
Copy link

I've been trying to get started with Onelogin + Terraform, but have been running into the same issue on two different computers using two different Onelogin Development accounts.

  • I've set up the provider based on the documentation (see EXAMPLE 1 below.)
  • I've exported the Client ID and Client Secret into the environment variables as documented and verified (i.e., env | grep ONELOGIN).
  • I've been able to create a user via creating it in a users.tf file (see EXAMPLE 2 below.)
  • However, I have been getting a Timeout error when running different operations (e.g., terraform apply, terraform refresh).

Any thoughts on how to translate the error message from below and resolve?

EXAMPLE 1

terraform {
  required_providers {
    onelogin = { 
      source = "onelogin/onelogin"
      version = "0.1.25"
    }   
  }
}

provider "onelogin" {
  # Configuration options
}
EXAMPLE 2

resource onelogin_users example_user {
    username  = "example"
    email     = "redacted@gmail.com"
  }
EXAMPLE 3

➜  onelogin-terraform terraform plan
onelogin_users.example_user Refreshing state... [id=12345678]
╷
│ Error: request error: context: ol http service, error_message: Post "https://api.us.onelogin.com/auth/oauth2/v2/token": context deadline exceeded (Client.Timeout exceeded while awaiting headers)
│ 
│   with onelogin_users.example_user,
│   on users.tf line 1, in resource "onelogin_users" "example_user":
│    1: resource onelogin_users example_user {
│ 
╵
@Jmfwolf
Copy link
Contributor

Jmfwolf commented Jan 19, 2023

We are in the process of standardizing our SDKs by using OpenAPI specifications.
I have an OpenAPI generated terraform-provider-onelogin in prerelease if you would like t try it out.
https://github.com/onelogin/terraform-provider-onelogin/tree/openapi

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants