Skip to content

Commit

Permalink
Update var to be optional (#19)
Browse files Browse the repository at this point in the history
  • Loading branch information
wayne-root authored Nov 2, 2023
1 parent 4626312 commit 0d6c2a2
Show file tree
Hide file tree
Showing 7 changed files with 21 additions and 5 deletions.
12 changes: 11 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,17 +61,27 @@ No resources.
| <a name="input_service_map"></a> [service\_map](#input\_service\_map) | A map of services to deploy | `map(any)` | `{}` | no |
| <a name="input_service_max_capacity"></a> [service\_max\_capacity](#input\_service\_max\_capacity) | Maximum capacity of ECS autoscaling target, cannot be less than min\_capacity | `number` | `4` | no |
| <a name="input_service_min_capacity"></a> [service\_min\_capacity](#input\_service\_min\_capacity) | Minimum capacity of ECS autoscaling target, cannot be more than max\_capacity | `number` | `1` | no |
| <a name="input_service_scale_in_cooldown"></a> [service\_scale\_in\_cooldown](#input\_service\_scale\_in\_cooldown) | Time between scale in action | `number` | `300` | no |
| <a name="input_service_scale_out_cooldown"></a> [service\_scale\_out\_cooldown](#input\_service\_scale\_out\_cooldown) | Time between scale out action | `number` | `300` | no |
| <a name="input_service_security_groups"></a> [service\_security\_groups](#input\_service\_security\_groups) | Security group IDs to attach to your ECS Service | `list(string)` | `[]` | no |
| <a name="input_service_subnets"></a> [service\_subnets](#input\_service\_subnets) | Private subnets for ECS | `list(string)` | `[]` | no |
| <a name="input_service_target_cpu_value"></a> [service\_target\_cpu\_value](#input\_service\_target\_cpu\_value) | Autoscale when CPU Usage value over the specified value. Must be specified if `enable_cpu_based_autoscaling` is `true`. | `number` | `70` | no |
| <a name="input_service_task_execution_role_arn"></a> [service\_task\_execution\_role\_arn](#input\_service\_task\_execution\_role\_arn) | Default IAM role for ECS execution | `string` | n/a | yes |
| <a name="input_service_task_execution_role_arn"></a> [service\_task\_execution\_role\_arn](#input\_service\_task\_execution\_role\_arn) | Default IAM role for ECS execution | `string` | `""` | no |
| <a name="input_service_task_role_arn"></a> [service\_task\_role\_arn](#input\_service\_task\_role\_arn) | Default IAM role for ECS task | `string` | `""` | no |

## Outputs

| Name | Description |
|------|-------------|
| <a name="output_aws_ecs_task_definition"></a> [aws\_ecs\_task\_definition](#output\_aws\_ecs\_task\_definition) | ARN of the ECS service |
| <a name="output_ecs_cloudwatch_log_group_arn"></a> [ecs\_cloudwatch\_log\_group\_arn](#output\_ecs\_cloudwatch\_log\_group\_arn) | The cloudwatch log group to be used by the cluster |
| <a name="output_ecs_cloudwatch_log_group_name"></a> [ecs\_cloudwatch\_log\_group\_name](#output\_ecs\_cloudwatch\_log\_group\_name) | The cloudwatch log group to be used by the cluster |
| <a name="output_ecs_cluster_arn"></a> [ecs\_cluster\_arn](#output\_ecs\_cluster\_arn) | ARN of the ECS Cluster |
| <a name="output_ecs_cluster_id"></a> [ecs\_cluster\_id](#output\_ecs\_cluster\_id) | ID of the ECS Cluster |
| <a name="output_ecs_cluster_kms_arn"></a> [ecs\_cluster\_kms\_arn](#output\_ecs\_cluster\_kms\_arn) | The AWS Key Management Service key ID to encrypt the data between the local client and the container |
| <a name="output_ecs_cluster_name"></a> [ecs\_cluster\_name](#output\_ecs\_cluster\_name) | The name of the ECS cluster |
| <a name="output_ecs_service_arn"></a> [ecs\_service\_arn](#output\_ecs\_service\_arn) | ARN of the ECS service |
| <a name="output_ecs_service_name"></a> [ecs\_service\_name](#output\_ecs\_service\_name) | The name of the ECS service |
<!-- END OF PRE-COMMIT-TERRAFORM DOCS HOOK -->

<!-- BEGIN_TF_DOCS -->
Expand Down
6 changes: 4 additions & 2 deletions examples/fargate/README.MD
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
| [aws_security_group_rule.lb_sg_allow_all](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/security_group_rule) | resource |
| [aws_caller_identity.current](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/caller_identity) | data source |
| [aws_iam_policy_document.execution_custom_policy](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/iam_policy_document) | data source |
| [aws_iam_policy_document.task_custom_policy](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/iam_policy_document) | data source |
| [aws_iam_policy_document.task_ecs_exec_policy](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/iam_policy_document) | data source |
| [aws_region.current](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/region) | data source |
| [aws_subnets.private](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/subnets) | data source |
| [aws_subnets.public](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/subnets) | data source |
Expand All @@ -46,5 +46,7 @@

## Outputs

No outputs.
| Name | Description |
|------|-------------|
| <a name="output_ecs_cluster_kms_arn"></a> [ecs\_cluster\_kms\_arn](#output\_ecs\_cluster\_kms\_arn) | The AWS Key Management Service key ID to encrypt the data between the local client and the container |
<!-- END OF PRE-COMMIT-TERRAFORM DOCS HOOK -->
1 change: 1 addition & 0 deletions modules/autoscaling-group/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ No resources.
| <a name="input_launch_template_description"></a> [launch\_template\_description](#input\_launch\_template\_description) | Description of the launch template | `string` | `null` | no |
| <a name="input_launch_type"></a> [launch\_type](#input\_launch\_type) | Launch type | `string` | `"EC2"` | no |
| <a name="input_max_size"></a> [max\_size](#input\_max\_size) | The maximum size of the autoscaling group | `number` | `null` | no |
| <a name="input_metadata_options"></a> [metadata\_options](#input\_metadata\_options) | Customize the metadata options (IMDS) for the instance | <pre>object({<br> http_endpoint = string<br> http_tokens = string<br> http_put_response_hop_limit = number<br> instance_metadata_tags = string<br> })</pre> | <pre>{<br> "http_endpoint": "enabled",<br> "http_put_response_hop_limit": 1,<br> "http_tokens": "required",<br> "instance_metadata_tags": "disabled"<br>}</pre> | no |
| <a name="input_min_size"></a> [min\_size](#input\_min\_size) | The minimum size of the autoscaling group | `number` | `null` | no |
| <a name="input_name"></a> [name](#input\_name) | Name of the product/project/application | `string` | `""` | no |
| <a name="input_network_interface_security_groups"></a> [network\_interface\_security\_groups](#input\_network\_interface\_security\_groups) | A list of security group IDs to associate | `list(string)` | `null` | no |
Expand Down
2 changes: 2 additions & 0 deletions modules/cluster/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,8 @@ No modules.

| Name | Description |
|------|-------------|
| <a name="output_ecs_cloudwatch_log_group_arn"></a> [ecs\_cloudwatch\_log\_group\_arn](#output\_ecs\_cloudwatch\_log\_group\_arn) | The cloudwatch log group to be used by the cluster |
| <a name="output_ecs_cloudwatch_log_group_name"></a> [ecs\_cloudwatch\_log\_group\_name](#output\_ecs\_cloudwatch\_log\_group\_name) | The cloudwatch log group to be used by the cluster |
| <a name="output_ecs_cluster_arn"></a> [ecs\_cluster\_arn](#output\_ecs\_cluster\_arn) | ARN of the ECS Cluster |
| <a name="output_ecs_cluster_id"></a> [ecs\_cluster\_id](#output\_ecs\_cluster\_id) | ID of the ECS Cluster |
| <a name="output_ecs_cluster_kms_arn"></a> [ecs\_cluster\_kms\_arn](#output\_ecs\_cluster\_kms\_arn) | The AWS Key Management Service key ID to encrypt the data between the local client and the container |
Expand Down
3 changes: 1 addition & 2 deletions modules/iam/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@

| Name | Version |
|------|---------|
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | >= 1.3 |
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | ~> 4.0 |
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | >= 4.0 |

## Providers

Expand Down
1 change: 1 addition & 0 deletions modules/service/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ No modules.

| Name | Description |
|------|-------------|
| <a name="output_aws_ecs_task_definition"></a> [aws\_ecs\_task\_definition](#output\_aws\_ecs\_task\_definition) | ARN of the ECS service |
| <a name="output_ecs_service_arn"></a> [ecs\_service\_arn](#output\_ecs\_service\_arn) | ARN of the ECS service |
| <a name="output_ecs_service_name"></a> [ecs\_service\_name](#output\_ecs\_service\_name) | The name of the ECS service |
<!-- END OF PRE-COMMIT-TERRAFORM DOCS HOOK -->
Expand Down
1 change: 1 addition & 0 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ variable "service_map" {
variable "service_task_execution_role_arn" {
description = "Default IAM role for ECS execution"
type = string
default = ""
}

variable "service_task_role_arn" {
Expand Down

0 comments on commit 0d6c2a2

Please sign in to comment.