diff --git a/README.md b/README.md index 0ae911ddb0..ff6ad3ea77 100644 --- a/README.md +++ b/README.md @@ -445,7 +445,7 @@ We welcome any improvement to the standard module to make the default as secure | [ghes\_url](#input\_ghes\_url) | GitHub Enterprise Server URL. Example: https://github.internal.co - DO NOT SET IF USING PUBLIC GITHUB | `string` | `null` | no | | [github\_app](#input\_github\_app) | GitHub app parameters, see your github app. Ensure the key is the base64-encoded `.pem` file (the output of `base64 app.private-key.pem`, not the content of `private-key.pem`). |
object({| n/a | yes | | [idle\_config](#input\_idle\_config) | List of time period that can be defined as cron expression to keep a minimum amount of runners active instead of scaling down to 0. By defining this list you can ensure that in time periods that match the cron expression within 5 seconds a runner is kept idle. |
key_base64 = string
id = string
webhook_secret = string
})
list(object({| `[]` | no | -| [instance\_allocation\_strategy](#input\_instance\_allocation\_strategy) | The allocation strategy for spot instances. AWS recommends to use `capacity-optimized` however the AWS default is `lowest-price`. | `string` | `"lowest-price"` | no | +| [instance\_allocation\_strategy](#input\_instance\_allocation\_strategy) | The allocation strategy for spot instances. AWS recommends to use `price-capacity-optimized` however the AWS default is `lowest-price`. | `string` | `"lowest-price"` | no | | [instance\_max\_spot\_price](#input\_instance\_max\_spot\_price) | Max price price for spot intances per hour. This variable will be passed to the create fleet as max spot price for the fleet. | `string` | `null` | no | | [instance\_profile\_path](#input\_instance\_profile\_path) | The path that will be added to the instance\_profile, if not set the environment name will be used. | `string` | `null` | no | | [instance\_target\_capacity\_type](#input\_instance\_target\_capacity\_type) | Default lifecycle used for runner instances, can be either `spot` or `on-demand`. | `string` | `"spot"` | no | diff --git a/modules/runners/variables.tf b/modules/runners/variables.tf index 0a1f4d3aca..fe3e521d41 100644 --- a/modules/runners/variables.tf +++ b/modules/runners/variables.tf @@ -109,7 +109,7 @@ variable "instance_allocation_strategy" { default = "lowest-price" validation { - condition = contains(["lowest-price", "diversified", "capacity-optimized", "capacity-optimized-prioritized"], var.instance_allocation_strategy) + condition = contains(["lowest-price", "diversified", "capacity-optimized", "capacity-optimized-prioritized", "price-capacity-optimized"], var.instance_allocation_strategy) error_message = "The instance allocation strategy does not match the allowed values." } } diff --git a/variables.tf b/variables.tf index 7948eeccfb..2672082468 100644 --- a/variables.tf +++ b/variables.tf @@ -451,11 +451,11 @@ variable "instance_target_capacity_type" { } variable "instance_allocation_strategy" { - description = "The allocation strategy for spot instances. AWS recommends to use `capacity-optimized` however the AWS default is `lowest-price`." + description = "The allocation strategy for spot instances. AWS recommends to use `price-capacity-optimized` however the AWS default is `lowest-price`." type = string default = "lowest-price" validation { - condition = contains(["lowest-price", "diversified", "capacity-optimized", "capacity-optimized-prioritized"], var.instance_allocation_strategy) + condition = contains(["lowest-price", "diversified", "capacity-optimized", "capacity-optimized-prioritized", "price-capacity-optimized"], var.instance_allocation_strategy) error_message = "The instance allocation strategy does not match the allowed values." } }
cron = string
timeZone = string
idleCount = number
}))