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

provider credential source #112

Open
rjhornsby opened this issue Apr 3, 2023 · 5 comments
Open

provider credential source #112

rjhornsby opened this issue Apr 3, 2023 · 5 comments

Comments

@rjhornsby
Copy link
Contributor

The provider's new openapi-based design presently requires a separate, manual REST operation to obtain an API token from your OL API credentials (client_id/client_secret).

The provider should obtain the token it needs by using the values of the env vars ONELOGIN_CLIENT_ID and ONELOGIN_CLIENT_SECRET.

@Jmfwolf
Copy link
Contributor

Jmfwolf commented Apr 6, 2023

Thank you for expounding upon this part of the README

I am aware of the issue and it is being worked on. Given the requests for more features and bug fixes, I am only able to manage so many things at once. I will keep you updated as things progress. If you have any recommendations on the specification changes for the provider tooling, I am more than willing to review PR's

@rjhornsby
Copy link
Contributor Author

For anyone else facing this, there is a workaround by using a separate provider to get the oauth token svenhamers/oauth.

data.tf:

data "oauth_token" "onelogin" {
  client_id      = var.u_onelogin_client_id
  client_secret  = var.u_onelogin_client_secret
  token_endpoint = var.onelogin_oauth_token_url
}

onelogin_oauth_token_url is https://<your_domain>.onelogin.com/auth/oauth2/v2/token

providers.tf:

provider "onelogin" {
  apikey_auth = data.oauth_token.onelogin.token
}

@Jmfwolf
Copy link
Contributor

Jmfwolf commented May 30, 2023

@rjhornsby I am going to address this and the other issues you have brought up in the new implementation

@rjhornsby
Copy link
Contributor Author

sounds good. thanks for the update

@Jmfwolf
Copy link
Contributor

Jmfwolf commented Jun 2, 2023

@rjhornsby In order to resolve the SAML issues in the terraform provider I need to create a new Go SDK. As a contributor to both repos your insight is appreciated

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