File tree Expand file tree Collapse file tree 4 files changed +9
-14
lines changed
private-repository-with-team
public-repository-complete-example Expand file tree Collapse file tree 4 files changed +9
-14
lines changed Original file line number Diff line number Diff line change @@ -189,14 +189,14 @@ Use a template repository to create this resource.
189189See [ Template Object Attributes] ( #template-object-attributes ) below for details.
190190
191191##### Teams Configuration
192- Teams need to exist beforehand. Your can use non-computed
192+ Your can use non-computed
193193(known at ` terraform plan ` ) team names or slugs
194- (` *_teams ` Attributes; ** recommended ** )
194+ (` *_teams ` Attributes)
195195or computed (only known in ` terraform apply ` phase) team IDs
196196(` *_team_ids ` Attributes).
197- When using non-computed names/slugs make sure to add the actual team resources as
198- indirect dependencies in ` module_depends_on ` as explained in
199- [ Module Configuration ] ( #module-configuration ) above .
197+ ** When using non-computed names/slugs teams need to exist before running plan. **
198+ This is due to some terraform limitation and we will update the module once terraform
199+ removed thislimitation .
200200
201201- ** ` pull_teams ` ** or ** ` pull_team_ids ` ** : * (Optional ` list(string) ` )*
202202A list of teams to grant pull (read-only) permission.
Original file line number Diff line number Diff line change @@ -36,8 +36,8 @@ module "repository" {
3636 archived = false
3737 topics = [" terraform" , " integration-test" ]
3838
39- admin_teams = [
40- var . team_name
39+ admin_team_ids = [
40+ github_team . team . id
4141 ]
4242
4343 branch_protections = [
Original file line number Diff line number Diff line change @@ -60,8 +60,8 @@ module "repository" {
6060 archived = false
6161 topics = var. topics
6262
63- admin_teams = [
64- var . team_name
63+ admin_team_ids = [
64+ github_team . team . id
6565 ]
6666
6767 branch_protections = [
Original file line number Diff line number Diff line change @@ -331,11 +331,6 @@ data "github_team" "teams" {
331331 for_each = local. teams
332332
333333 slug = each. value . slug
334-
335- depends_on = [
336- var . module_depends_on ,
337- github_repository . repository ,
338- ]
339334}
340335
341336resource "github_team_repository" "team_repository_by_slug" {
You can’t perform that action at this time.
0 commit comments