Skip to content

Commit

Permalink
Add morph (#10)
Browse files Browse the repository at this point in the history
* add morph

* make fix

* removing tf lock
  • Loading branch information
gomez385 committed Aug 16, 2024
1 parent 205ce05 commit a5baded
Show file tree
Hide file tree
Showing 4 changed files with 55 additions and 71 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# Local .terraform directories
**/.terraform/*
plans/*

# .tfstate files
*.tfstate
Expand Down Expand Up @@ -35,4 +36,6 @@ override.tf.json
# Ignore CLI configuration files
.terraformrc
terraform.rc

.terraform.lock.hcl
plans
70 changes: 0 additions & 70 deletions .terraform.lock.hcl

This file was deleted.

3 changes: 2 additions & 1 deletion main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@ locals {
gomez385 = "push"
}
pull_request_bypassers = [
"arnol377"
"arnol377",
"gomez385"
]
}

Expand Down
50 changes: 50 additions & 0 deletions morpheus.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
locals {
morpheus_repos = [
"morpheus-clouds",
]
}


module "morpheus_repos" {
for_each = toset(local.morpheus_repos)
source = "HappyPathway/repo/github"
#github_codeowners_team = "CSVD"
github_repo_description = "Repo for morpheus cloud"
repo_org = "CSVD"
name = each.value
github_repo_topics = [
"terraform",
"morpheus",
]
force_name = true
create_codeowners = false
enforce_prs = true
collaborators = { gomez385 = "admin", arnol377 = "admin" }
pull_request_bypassers = local.pull_request_bypassers
managed_extra_files = [
{
path = ".github/workflows/terraform-plan.yaml"
content = templatefile(
"${path.module}/workflows/terraform-plan.yaml.tpl",
{
repo_name = each.value
directory = null
git_owner = {
name = "gomez385"
email = "james.f.gomez@census.gov"
}
}
)
},
{
path = ".github/workflows/terraform-apply.yaml"
content = templatefile(
"${path.module}/workflows/terraform-apply.yaml.tpl",
{
repo_name = each.value
directory = null
}
)
}
]
}

0 comments on commit a5baded

Please sign in to comment.