Add or remove a team member using a tfe_organization_membership.
Basic usage:
resource "tfe_team" "test" {
name = "my-team-name"
organization = "my-org-name"
}
resource "tfe_organization_membership" "test" {
organization = "my-org-name"
email = "example@hashicorp.com"
}
resource "tfe_team_organization_member" "test" {
team_id = tfe_team.test.id
organization_membership_id = tfe_organization_membership.test.id
}
The following arguments are supported:
team_id
- (Required) ID of the team.organization_membership_id
- (Required) ID of the organization membership.A team member can be imported; use <TEAM ID>/<ORGANIZATION MEMBERSHIP ID>
or <ORGANIZATION NAME>/<USER EMAIL>/<TEAM NAME>
as the import ID. For example:
terraform import tfe_team_organization_member.test team-47qC3LmA47piVan7/ou-2342390sdf0jj
or
terraform import tfe_team_organization_member.test my-org-name/user@company.com/my-team-name