# Terraform backends cannot contain interpolations
terraform {
  backend "s3" {
    bucket  = "orcd-terraform-state"
    key     = "prod/github/wp-bootstrap-starter-sony/terraform.tfstate"
    region  = "us-east-1"
    encrypt = "true"
  }
}

module "github_repositories" {
  source = "git@github.com:theorchard/terraform-github.git//?ref=2.1.4"
  github_repository_names = {
    wp-bootstrap-starter-sony = {
      branch_protection_enabled        = true
      branch_protection_enforce_admins = true
      repo_auto_init                   = false
      archived_repository              = false
      github_code_owner_reviews        = true
      visibility                       = "private"
      description                      = "Managed by Terraform."
      has_downloads                    = false
      homepage_url                     = ""
    }
  }

  github_pull_teams = ["apollo-team"]
  github_push_teams = ["mergers", "apollo-be-team", "apollo-fe-team"]

  allow_merge_commit = true

  branch_protection_required_status_checks = true
  github_code_owner_reviews                = true
}
