[BUG]: data "github_user_external_identity" does not return saml_identity for organisation owner
Opened this issue · 1 comments
Expected Behavior
output "user_saml_identity" {
value = data.github_user_external_identity.myuser.saml_identity
}
returning saml_identity for the user in the organisation, provided that organisation owner is making this request.
It is accessible for the organisation owner in the GitHub UI, but same information is not accessible in the github terraform provider. GitHub organisation is a part of GitHub Enterprise Account with enabled SAML and SSO.
Actual Behavior
Error: there was no external identity found for username "someuser" in Organization "someorganisation"
│
│ with data.github_user_external_identity.myuser,
│ on main.tf line 2, in data "github_user_external_identity" "myuser":
│ 2: data "github_user_external_identity" "myuser" {
"someuser" and "someorganisation" are sanitized values for actual existing user and organisation used in real config
Terraform Version
Terraform v1.9.7
Affected Resource(s)
- data.github_user_external_identity
Terraform Configuration Files
data "github_user_external_identity" "myuser" {
username = "someuser"
}
output "user_saml_identity" {
value = data.github_user_external_identity.myuser.saml_identity
}
output "user_scim_identity" {
value = data.github_user_external_identity.myuser.scim_identity
}
Steps to Reproduce
$ terraform plan
Debug Output
data.github_user_external_identity.myuser: Reading...
Terraform used the selected providers to generate the following execution
plan. Resource actions are indicated with the following symbols:
+ create
Terraform planned the following actions, but then encountered a problem:
...
╷
│ Error: there was no external identity found for username "someuser" in Organization "someoranisation"
│
│ with data.github_user_external_identity.myuser,
│ on main.tf line 2, in data "github_user_external_identity" "myuser":
│ 2: data "github_user_external_identity" "myuser" {
│
╵
Panic Output
No response
Code of Conduct
- I agree to follow this project's Code of Conduct
Hey @zaMedvedem thanks for tracking this down and sorry for the trouble. Let us know if you'd be interested in fixing the issue and submitting a PR. For now I have labeled this as "Up For Grabs" so that the community can take a stab at getting this fixed as well. ❤️