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

Custom Domains Cannot be Imported without subsequent recreation #844

Closed
quantumew opened this issue Dec 3, 2021 · 2 comments · Fixed by #845
Closed

Custom Domains Cannot be Imported without subsequent recreation #844

quantumew opened this issue Dec 3, 2021 · 2 comments · Fixed by #845

Comments

@quantumew
Copy link
Contributor

quantumew commented Dec 3, 2021

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Terraform Version

v1.0.3

Affected Resource(s)

  • okta_domain

Terraform Configuration Files

Simple okta_domain as outlined in documentation.

Debug Output

Panic Output

Expected Behavior

Import a domain, and it not be recreated on subsequent runs

Actual Behavior

Domain requires recreation due to the name property not being set on import or refresh

Steps to Reproduce

  1. terraform import existing custom domain
  2. Run a plan, notice it will be recreated

Important Factoids

References

I noticed I cannot import an existing custom domain without subsequent applies recreating it. It appears to be due to the fact that the read function does not set the name property. The name property should be sync'd in the read function.

https://github.com/okta/terraform-provider-okta/blob/master/okta/resource_okta_domain.go#L89

@quantumew
Copy link
Contributor Author

Anyway we could get this in a patch release? Thanks!

@bogdanprodan-okta
Copy link
Contributor

yes, I think I can make a minor release today. I just need some PRs to be merged first.

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

Successfully merging a pull request may close this issue.

2 participants