-
Notifications
You must be signed in to change notification settings - Fork 179
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
401 Unauthorised when importing Organization, but other resources import successfully #1622
Comments
Thanks for opening this issue! Please make sure you've followed our guidelines when opening the issue. In short, to help us reproduce the issue we need:
The ticket INTMDB-1288 was created for internal tracking. |
Hello @seddy, thank you for the details provided. I was able to reproduce the error, and identified an issue with how we are handling the import logic in this resource. We will keep you updated with any progress made in INTMDB-1288. |
Hello @seddy, I wanted to follow up on this issue to gain more understanding on your use case for importing this resource. |
Nothing too crazy @AgustinBettati as there's not tons to manage on this resource. What I'm interested in is:
|
With regards to being able to reference We have recently updated our documentation in #1806 to clarify the limitation, this will be present the coming release. |
Terraform CLI and Terraform MongoDB Atlas Provider Version
Terraform Configuration File
Steps to Reproduce
We're attempting to import an existing
Organization
into the state. This fails on a 401. However, other state imports (e.g. of projects) work fine. The API key being used has all permissions, we've tried with multiple different keys and it's the same behaviour each time.For this example, we can just use following configuration:
The API key we're using has all permissions at the Organization level and all permissions at the Project level. The behaviour is the same if it just has the
Owner
permission on both.I've used the same API key to get the organization details using the API and it returns successfully, so I'm reasonably certain this is not a configuration issue with permissions on the API key.
Expected Behavior
Running both of these two commands should succeed:
Both should succeed with:
Actual Behavior
The Project import works fine, the Organization import fails with:
References
This is very similar to the issue outlined in #385, however that was two years ago and resolved outside of github. There were no potential fixes in there, so I'm re-raising it as a separate issue.
The text was updated successfully, but these errors were encountered: