Skip to content

Commit 49a451a

Browse files
authored
Merge pull request #4 from data-platform-hq/support_no_public_ip_prefix_selection
fix: updated vmss module version; added var for public ip prefix
2 parents 7b93d7c + 35737ee commit 49a451a

File tree

3 files changed

+25
-17
lines changed

3 files changed

+25
-17
lines changed

README.md

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ module "ado_vmss_agent_pool" {
4444

4545
| Module | Path | Version |
4646
|--------------------------------------------------------------------|--------------------------------|---------|
47-
| [vmss](https://github.com/data-platform-hq/terraform-azurerm-vmss) | data-platform-hq/vmss/azurerm | 1.1.0 |
47+
| [vmss](https://github.com/data-platform-hq/terraform-azurerm-vmss) | data-platform-hq/vmss/azurerm | 1.2.0 |
4848

4949
## Resources
5050

@@ -59,16 +59,17 @@ module "ado_vmss_agent_pool" {
5959

6060
## Inputs
6161

62-
| Name | Description | Type | Default | Required |
63-
|------|-------------|------|-------------------------------------------------------------------------------------------------------------------------------------------------------|:--------:|
64-
| <a name="input_vm_scale_set_name"></a> [vm\_scale\_set\_name](#input\_vm\_scale\_set\_name)| VM Scale Sets name | `string` | n/a | yes |
65-
| <a name="input_resource_group"></a> [resource\_group](#input\_resource\_group)| The name of the resource group. | `string` | n/a| yes |
66-
| <a name="input_location"></a> [location](#input\_location)| The Azure Region in which all resources in this example should be created. | `string` | n/a | yes |
67-
| <a name="input_subnet_id"></a> [subnet\_id](#input\_subnet\_id)| Subnet where VM Scale Sets would be provisioned | `string` | n/a | yes |
68-
| <a name="input_ado_project_name"></a> [ado\_project\_name](#input\_ado\_project\_name)| Target Azure DevOps Project name where VMSS agent pool would be provisioned | `string` | n/a | yes |
69-
| <a name="input_ado_service_connection_azurerm_name"></a> [ado\_service\_connection\_azurerm\_name](#input\_ado\_service\_connection\_azurerm\_name)| Name of existing Azure DevOps Service Connection AzureRM that points to Azure Subscription with VMSS used in agent pool | `string` | n/a | yes |
70-
| <a name="input_ado_vmss_pool_name"></a> [ado\_vmss\_pool\_name](#input\_ado\_vmss\_pool\_name)| Given name to Azure DevOps VMSS agent pool | `string` | n/a | yes |
71-
| <a name="input_ado_vmss_pool_configuration"></a> [ado\_vmss\_pool\_configuration](#input\_ado\_vmss\_pool\_configuration)| Object with configuration options for Azure DevOps VMSS agent pool | <pre>object({<br> desired_idle = optional(number)<br> max_capacity = optional(number)<br> time_to_live_minutes = optional(number)<br> recycle_after_each_use = optional(bool)<br>})</pre> |<pre>object({<br> desired_idle = optional(number, 0)<br> max_capacity = optional(number, 3)<br> time_to_live_minutes = optional(number, 30)<br> recycle_after_each_use = optional(bool, false)<br>})</pre> | no |
62+
| Name | Description | Type | Default | Required |
63+
|-----------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|:--------:|
64+
| <a name="input_vm_scale_set_name"></a> [vm\_scale\_set\_name](#input\_vm\_scale\_set\_name) | VM Scale Sets name | `string` | n/a | yes |
65+
| <a name="input_resource_group"></a> [resource\_group](#input\_resource\_group) | The name of the resource group. | `string` | n/a | yes |
66+
| <a name="input_location"></a> [location](#input\_location) | The Azure Region in which all resources in this example should be created. | `string` | n/a | yes |
67+
| <a name="input_subnet_id"></a> [subnet\_id](#input\_subnet\_id) | Subnet where VM Scale Sets would be provisioned | `string` | n/a | yes |
68+
| <a name="input_ado_project_name"></a> [ado\_project\_name](#input\_ado\_project\_name) | Target Azure DevOps Project name where VMSS agent pool would be provisioned | `string` | n/a | yes |
69+
| <a name="input_ado_service_connection_azurerm_name"></a> [ado\_service\_connection\_azurerm\_name](#input\_ado\_service\_connection\_azurerm\_name) | Name of existing Azure DevOps Service Connection AzureRM that points to Azure Subscription with VMSS used in agent pool | `string` | n/a | yes |
70+
| <a name="input_ado_vmss_pool_name"></a> [ado\_vmss\_pool\_name](#input\_ado\_vmss\_pool\_name) | Given name to Azure DevOps VMSS agent pool | `string` | n/a | yes |
71+
| <a name="input_ado_vmss_pool_configuration"></a> [ado\_vmss\_pool\_configuration](#input\_ado\_vmss\_pool\_configuration) | Object with configuration options for Azure DevOps VMSS agent pool | <pre>object({<br> desired_idle = optional(number)<br> max_capacity = optional(number)<br> time_to_live_minutes = optional(number)<br> recycle_after_each_use = optional(bool)<br>})</pre> | <pre>object({<br> desired_idle = optional(number, 0)<br> max_capacity = optional(number, 3)<br> time_to_live_minutes = optional(number, 30)<br> recycle_after_each_use = optional(bool, false)<br>})</pre> | no |
72+
| <a name="input_ado_vmss_public_ip_prefix_enabled"></a> [ado\_vmss\_public\_ip\_prefix\_enabled](#input\_ado\_vmss\_public\_ip\_prefix\_enabled) | Boolean flag that determines whether Public IP Prefix is assigned to VM Scale Sets | `bool` | true | no |
7273

7374
## Outputs
7475

main.tf

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,14 @@ resource "tls_private_key" "this" {
55

66
module "vmss" {
77
source = "data-platform-hq/vmss/azurerm"
8-
version = "1.1.0"
8+
version = "1.2.0"
99

10-
scale_set_name = var.vm_scale_set_name
11-
location = var.location
12-
resource_group = var.resource_group
13-
admin_ssh_key = { public_key = tls_private_key.this.public_key_openssh }
14-
subnet = var.subnet_id
10+
scale_set_name = var.vm_scale_set_name
11+
location = var.location
12+
resource_group = var.resource_group
13+
admin_ssh_key = { public_key = tls_private_key.this.public_key_openssh }
14+
subnet_id = var.subnet_id
15+
public_ip_prefix_enabled = var.ado_vmss_public_ip_prefix_enabled
1516
}
1617

1718
data "azuredevops_project" "this" {

variables.tf

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,3 +43,9 @@ variable "ado_vmss_pool_configuration" {
4343
})
4444
default = {}
4545
}
46+
47+
variable "ado_vmss_public_ip_prefix_enabled" {
48+
description = "Boolean flag that determines whether Public IP Prefix is assigned to VM Scale Sets"
49+
type = bool
50+
default = true
51+
}

0 commit comments

Comments
 (0)