diff --git a/.github/workflows/pre-commit-and-tests.yml b/.github/workflows/pre-commit-and-tests.yml index 77a9c21..673490f 100644 --- a/.github/workflows/pre-commit-and-tests.yml +++ b/.github/workflows/pre-commit-and-tests.yml @@ -51,7 +51,7 @@ jobs: - name: Install requirements run: | - python -m venv .venv + python3 -m venv .venv source .venv/bin/activate if [ -f requirements.txt ]; then pip install -r requirements.txt diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 8e8424e..baf3703 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -22,7 +22,7 @@ repos: hooks: - id: Terraform docs name: Terraform docs - entry: python examples/terraform-docs.py + entry: python3 examples/terraform-docs.py language: system types: [python] always_run: true diff --git a/examples/addition-iam-policies/iam.tf b/examples/addition-iam-policies/iam.tf index 8027915..749b6df 100644 --- a/examples/addition-iam-policies/iam.tf +++ b/examples/addition-iam-policies/iam.tf @@ -5,7 +5,7 @@ data "aws_iam_policy_document" "secrets_manager" { "secretsmanager:GetSecretValue" ] resources = [ - "arn:aws:secretsmanager:${data.aws_region.current.name}:${data.aws_caller_identity.current.account_id}:secret:github-runner-example" + "arn:aws:secretsmanager:${data.aws_region.current.region}:${data.aws_caller_identity.current.account_id}:secret:github-runner-example" ] } } diff --git a/examples/multiple-runners/README.md b/examples/multiple-runners/README.md index 1471b8c..c8ab412 100644 --- a/examples/multiple-runners/README.md +++ b/examples/multiple-runners/README.md @@ -29,7 +29,7 @@ module "runners" { | Name | Description | Type | Default | Required | |------|-------------|------|---------|:--------:| | [github\_personal\_access\_token\_ssm\_parameter](#input\_github\_personal\_access\_token\_ssm\_parameter) | The GitHub personal access token to use for accessing the repository | `string` | n/a | yes | -| [source\_locations](#input\_source\_locations) | Map of source locations to use when creating runners |
map(object({
source_location = string
source_name = string
})) | {
"example-1": {
"source_location": "https://github.com/my-org/example-1.git",
"source_name": "example-1"
},
"example-2": {
"source_location": "https://github.com/my-org/example-2.git",
"source_name": "example-2"
}
} | no |
+| [source\_locations](#input\_source\_locations) | Map of source locations to use when creating runners | map(object({
source_location = string
source_name = string
})) | {
"example-1": {
"source_location": "https://github.com/my-org/example-1.git",
"source_name": "example-1"
},
"example-2": {
"source_location": "https://github.com/my-org/example-2.git",
"source_name": "example-2"
}
} | no |
| [subnet\_ids](#input\_subnet\_ids) | The list of Subnet IDs for AWS Codebuild to launch ephemeral EC2 instances in. | `list(string)` | n/a | yes |
| [vpc\_id](#input\_vpc\_id) | The VPC ID for AWS Codebuild to launch ephemeral instances in. | `string` | n/a | yes |
diff --git a/locals.tf b/locals.tf
index a909c50..e87ce5b 100644
--- a/locals.tf
+++ b/locals.tf
@@ -1,7 +1,7 @@
locals {
aws_account_id = data.aws_caller_identity.current.account_id
- aws_region = data.aws_region.current.name
+ aws_region = data.aws_region.current.region
has_s3_log_bucket = var.s3_logs_bucket_name != null