https://github.com/happypathway/terraform-ecs-github-runner
Terraform Module
https://github.com/happypathway/terraform-ecs-github-runner
module terraform terraform-managed
Last synced: 6 months ago
JSON representation
Terraform Module
- Host: GitHub
- URL: https://github.com/happypathway/terraform-ecs-github-runner
- Owner: HappyPathway
- Created: 2024-09-10T16:29:51.000Z (8 months ago)
- Default Branch: main
- Last Pushed: 2024-11-14T20:50:16.000Z (6 months ago)
- Last Synced: 2024-11-14T21:33:14.633Z (6 months ago)
- Topics: module, terraform, terraform-managed
- Language: HCL
- Homepage:
- Size: 123 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Codeowners: CODEOWNERS
Awesome Lists containing this project
README
[](https://github.com/HappyPathway/terraform-ecs-github-runner/actions/workflows/terraform.yaml)
## Requirements
No requirements.
## Providers
| Name | Version |
|------|---------|
| [aws](#provider\_aws) | 5.66.0 |
| [github](#provider\_github) | 6.2.3 |
| [random](#provider\_random) | 3.6.3 |## Modules
No modules.
## Resources
| Name | Type |
|------|------|
| [aws_ecs_service.github-runner](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/ecs_service) | resource |
| [aws_ecs_task_definition.runner_task_definition](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/ecs_task_definition) | resource |
| [aws_iam_policy.certs_policy](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/iam_policy) | resource |
| [aws_iam_policy.secretsmanager_policy](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/iam_policy) | resource |
| [aws_iam_role.ecs_task_execution_role](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/iam_role) | resource |
| [aws_iam_role.ecs_task_role](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/iam_role) | resource |
| [aws_iam_role_policy_attachment.ecs_task_role_certs_policy_attachment](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/iam_role_policy_attachment) | resource |
| [aws_iam_role_policy_attachment.ecs_task_role_secret_policy_attachment](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/iam_role_policy_attachment) | resource |
| [aws_iam_role_policy_attachment.github_runner_permissions](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/iam_role_policy_attachment) | resource |
| [aws_secretsmanager_secret.secret](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/secretsmanager_secret) | resource |
| [aws_secretsmanager_secret_version.secret](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/secretsmanager_secret_version) | resource |
| [github_actions_runner_group.runner_group](https://registry.terraform.io/providers/hashicorp/github/latest/docs/resources/actions_runner_group) | resource |
| [random_pet.pet](https://registry.terraform.io/providers/hashicorp/random/latest/docs/resources/pet) | resource |
| [aws_caller_identity.current](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/caller_identity) | data source |
| [aws_ecs_cluster.runner_cluster](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/ecs_cluster) | data source |
| [aws_partition.current](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/partition) | data source |
| [aws_region.current](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/region) | data source |
| [aws_s3_bucket.certs](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/s3_bucket) | data source |
| [aws_s3_object.certs](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/s3_object) | data source |
| [github_actions_organization_registration_token.token](https://registry.terraform.io/providers/hashicorp/github/latest/docs/data-sources/actions_organization_registration_token) | data source |
| [github_actions_registration_token.token](https://registry.terraform.io/providers/hashicorp/github/latest/docs/data-sources/actions_registration_token) | data source |
| [github_organization.org](https://registry.terraform.io/providers/hashicorp/github/latest/docs/data-sources/organization) | data source |
| [github_repository.repo](https://registry.terraform.io/providers/hashicorp/github/latest/docs/data-sources/repository) | data source |## Inputs
| Name | Description | Type | Default | Required |
|------|-------------|------|---------|:--------:|
| [certs](#input\_certs) | n/a |object({| `null` | no |
bucket = string,
key = string
})
| [cpu](#input\_cpu) | The number of CPU units used by the task | `string` | `2048` | no |
| [desired\_count](#input\_desired\_count) | The desired number of tasks for the ECS service | `number` | `3` | no |
| [ecs\_cluster](#input\_ecs\_cluster) | The ECS cluster name | `string` | n/a | yes |
| [extra\_environment\_vars](#input\_extra\_environment\_vars) | Additional environment variables to inject into the container definition | `map(string)` | `{}` | no |
| [github\_runner\_permissions\_arn](#input\_github\_runner\_permissions\_arn) | The ARN of the IAM role with permissions for the GitHub runner | `string` | `null` | no |
| [hostname](#input\_hostname) | The hostname for the runner | `string` | n/a | yes |
| [image](#input\_image) | The image to use for the runner | `string` | `"public.ecr.aws/h1g9x7n8/github-runner:1.22.31"` | no |
| [log\_group](#input\_log\_group) | The name of the CloudWatch log group | `string` | `null` | no |
| [memory](#input\_memory) | The amount of memory (in MiB) used by the task | `string` | `4096` | no |
| [namespace](#input\_namespace) | The namespace for the runner | `string` | n/a | yes |
| [network\_configuration](#input\_network\_configuration) | The list of security groups for the ECS service |object({| `{}` | no |
security_groups = optional(list(string), [])
subnets = optional(list(string), [])
assign_public_ip = optional(bool, false)
})
| [repo\_name](#input\_repo\_name) | The name of the repository | `string` | `null` | no |
| [repo\_org](#input\_repo\_org) | The organization of the repository | `string` | `null` | no |
| [runner\_group](#input\_runner\_group) | Configuration for the GitHub runner group, including name, visibility, selected workflows, selected repository IDs, and whether public repositories are allowed. |object({| `{}` | no |
name = optional(string)
visibility = optional(string, "selected")
selected_workflows = optional(list(string), [])
restricted_to_workflows = optional(bool, false)
selected_repository_ids = optional(list(string), [])
allows_public_repositories = optional(bool, false)
create = optional(bool, false)
})
| [runner\_labels](#input\_runner\_labels) | The labels for the runner | `list(string)` | n/a | yes |
| [server\_url](#input\_server\_url) | The URL of the GitHub server | `string` | `""` | no |
| [tag](#input\_tag) | The tag for the runner | `string` | n/a | yes |## Outputs
| Name | Description |
|------|-------------|
| [runner\_group](#output\_runner\_group) | n/a |
| [runner\_task\_definition](#output\_runner\_task\_definition) | n/a |
| [token](#output\_token) | n/a |
| [url](#output\_url) | n/a |