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

[BUG]: this resource can only be used in the context of an organization, "xxx" is a user #2280

Open
1 task done
ljw4010 opened this issue Jun 3, 2024 · 1 comment
Open
1 task done
Labels
Status: Up for grabs Issues that are ready to be worked on by anyone Type: Bug Something isn't working as documented

Comments

@ljw4010
Copy link

ljw4010 commented Jun 3, 2024

Expected Behavior

after creating a new ORG on Enterprise git, we can set up org settings direcrtly

Actual Behavior

│ Error: this resource can only be used in the context of an organization, "xxx" is a user

│ with .github_team.create_team_to_org["xxxx"],

Terraform Version

1.5.x

Affected Resource(s)

Resources related to organizational configuration:
github_organization_settings
github_team
...

Terraform Configuration Files

data "github_enterprise" "get_enterprise" {}
resource "github_enterprise_organization" "create_org" {}
resource "github_organization_settings" "update_org_settings" {}
resource "github_team" "create_team_to_org" {}

Steps to Reproduce

terrform apply

Debug Output

No response

Panic Output

│ Error: this resource can only be used in the context of an organization, "xxx" is a user
│ 
│   with .github_team.create_team_to_org["xxxx"],

Code of Conduct

  • I agree to follow this project's Code of Conduct
@ljw4010 ljw4010 added Status: Triage This is being looked at and prioritized Type: Bug Something isn't working as documented labels Jun 3, 2024
@ljw4010
Copy link
Author

ljw4010 commented Jun 3, 2024

after the github_enterprise_organization called, the new ORG will be set up, but for a new org, the IsOrganization still is false, this field seems only to be initial in the begin instead of after creating the new org

@nickfloyd nickfloyd added Status: Up for grabs Issues that are ready to be worked on by anyone and removed Status: Triage This is being looked at and prioritized labels Jun 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Up for grabs Issues that are ready to be worked on by anyone Type: Bug Something isn't working as documented
Projects
None yet
Development

No branches or pull requests

2 participants