Skip to content

Commit fecac64

Browse files
pre-commit fixs (#3)
1 parent 649bfc2 commit fecac64

File tree

5 files changed

+14
-15
lines changed

5 files changed

+14
-15
lines changed

app-github-runner-cd/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
# app-github-runner-ci
22

3+
<!-- markdownlint-disable -->
34
<!-- BEGINNING OF PRE-COMMIT-TERRAFORM DOCS HOOK -->
45
## Requirements
56

app-github-runner-ci/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
# app-github-runner-ci
22

3+
<!-- markdownlint-disable -->
34
<!-- BEGINNING OF PRE-COMMIT-TERRAFORM DOCS HOOK -->
45
## Requirements
56

app-github-runner-creator/README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
# app-github-runner-ci
22

3+
<!-- markdownlint-disable -->
34
<!-- BEGINNING OF PRE-COMMIT-TERRAFORM DOCS HOOK -->
45
## Requirements
56

@@ -24,6 +25,7 @@ No modules.
2425
| [azuread_application_federated_identity_credential.github_app](https://registry.terraform.io/providers/hashicorp/azuread/latest/docs/resources/application_federated_identity_credential) | resource |
2526
| [azuread_service_principal.github_app](https://registry.terraform.io/providers/hashicorp/azuread/latest/docs/resources/service_principal) | resource |
2627
| [azurerm_role_assignment.environment_runner_github_runner_rg](https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/resources/role_assignment) | resource |
28+
| [azurerm_role_assignment.pagopa_iac_reader](https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/resources/role_assignment) | resource |
2729
| [azurerm_resource_group.github_runner_rg](https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/data-sources/resource_group) | data source |
2830

2931
## Inputs

app-github-runner-creator/main.tf

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,3 +27,12 @@ resource "azurerm_role_assignment" "environment_runner_github_runner_rg" {
2727
role_definition_name = "Contributor"
2828
principal_id = azuread_service_principal.github_app.object_id
2929
}
30+
31+
#
32+
# Associate custom role
33+
#
34+
resource "azurerm_role_assignment" "pagopa_iac_reader" {
35+
scope = var.subscription_id
36+
role_definition_name = "PagoPA IaC Reader"
37+
principal_id = azuread_service_principal.github_app.object_id
38+
}

app-github-runner-creator/variables.tf

Lines changed: 1 addition & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,5 @@
11
locals {
2-
# github_app_roles = {
3-
# subscription = [
4-
# "Contributor",
5-
# "Storage Account Contributor",
6-
# "Storage Blob Data Contributor",
7-
# "Storage File Data SMB Share Contributor",
8-
# "Storage Queue Data Contributor",
9-
# "Storage Table Data Contributor",
10-
# ]
11-
# }
2+
123
}
134

145
variable "app_name" {
@@ -26,11 +17,6 @@ variable "github_repository" {
2617
description = "GitHub Repository"
2718
}
2819

29-
# variable "iac_aad_group_name" {
30-
# type = string
31-
# description = "Azure AD group name for iac sp apps (with Directory Reader permissions at leats)"
32-
# }
33-
3420
variable "subscription_id" {
3521
type = string
3622
description = "Suscription ID"

0 commit comments

Comments
 (0)