Skip to content

Commit 0eda809

Browse files
authored
Merge pull request #18 from lazzurs/feat/fedihost
feat: Add Terragrunt config for fedihost GitHub repo
2 parents afe5a2e + c041b64 commit 0eda809

1 file changed

Lines changed: 51 additions & 0 deletions

File tree

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
terraform {
2+
source = "tfr:///mineiros-io/repository/github?version=0.18.0"
3+
}
4+
5+
include "root" {
6+
path = find_in_parent_folders("root.hcl")
7+
}
8+
9+
# Indicate what region to deploy the resources into
10+
generate "provider" {
11+
path = "provider.tf"
12+
if_exists = "overwrite_terragrunt"
13+
contents = <<EOF
14+
provider "github" {
15+
owner = "${local.org_vars.github_owner}"
16+
}
17+
terraform {
18+
backend "s3" {}
19+
}
20+
EOF
21+
}
22+
23+
locals {
24+
org_vars = yamldecode(file(find_in_parent_folders("org.yaml")))
25+
repo_name = basename(get_terragrunt_dir())
26+
}
27+
28+
inputs = {
29+
name = local.repo_name
30+
vulnerability_alerts = true
31+
visibility = "public"
32+
description = "Repo for the ${local.repo_name} project"
33+
has_issues = true
34+
has_wiki = true
35+
36+
allow_squash_merge = true
37+
allow_merge_commit = false
38+
allow_rebase_merge = false
39+
40+
branch_protections_v4 = [
41+
{
42+
pattern = "main"
43+
enforce_admins = true
44+
allows_force_pushes = false
45+
allows_deletions = false
46+
required_pull_request_reviews = {
47+
dismiss_stale_reviews = true
48+
}
49+
}
50+
]
51+
}

0 commit comments

Comments
 (0)