Skip to content

Commit

Permalink
Azure TF | Add outputs
Browse files Browse the repository at this point in the history
  • Loading branch information
chkp-natanelm committed Jan 15, 2025
1 parent 788ceeb commit 910eef8
Show file tree
Hide file tree
Showing 21 changed files with 433 additions and 1 deletion.
17 changes: 16 additions & 1 deletion terraform/azure/high-availability-existing-vnet/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -211,13 +211,28 @@ availability_type = "Availability Zone"
add_storage_account_ip_rules = false
storage_account_additional_ips = []

## Outputs

| Name | Description |
| ------------------------ | ---------------------------------------------------------------------------- |
| resource_group_link | URL to the created resource group.. |
| public_ips | Public IP address of the VMs. |
| resource_group | Name of the created resource group. |
| subnets | IDs of the subnets. |
| locations | Regions where the VMs are deployed. |
| vm_names | Name of the VMs. |
| disk_size | Disk size. |
| os_version | Version of the GAIA OS. |

## Revision History
In order to check the template version refer to the [sk116585](https://supportcenter.checkpoint.com/supportcenter/portal?eventSubmit_doGoviewsolutiondetails=&solutionid=sk116585)

| Template Version | Description |
| ---------------- |----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| 20251501 | - Added output values |
| | | |
| 20240613 | - Updated Azure Terraform provider version <br> - Updated managed identity permissions <br> - Cosmetic fixes & default values <br> - Added option to limit storage account access by specify allowed sourcess <br> - Added validation for os_version & os_offer |
| | | |
| | | |
| 20230910 | - R81.20 is the default version |
| | | |
| 20230212 | - Added Smart-1 Cloud support |
Expand Down
27 changes: 27 additions & 0 deletions terraform/azure/high-availability-existing-vnet/outputs.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
locals {
vms = local.availability_set_condition? azurerm_virtual_machine.vm-instance-availability-set : azurerm_virtual_machine.vm-instance-availability-zone
}
output "resource_group_link" {
value = module.common.resource_group_link
}
output "public_ips" {
value = azurerm_public_ip.public-ip[*].ip_address
}
output "resource_group" {
value = local.vms[0].resource_group_name
}
output "subnets" {
value = [data.azurerm_subnet.backend.id, data.azurerm_subnet.frontend.id]
}
output "locations" {
value = local.vms[*].location
}
output "vm_names" {
value = local.vms[*].name
}
output "disk_size" {
value = local.vms[0].storage_os_disk[0].disk_size_gb
}
output "os_version" {
value = module.common.os_version
}
16 changes: 16 additions & 0 deletions terraform/azure/high-availability-new-vnet/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -210,11 +210,27 @@ availability_type = "Availability Zone"
add_storage_account_ip_rules = false
storage_account_additional_ips = []

## Outputs

| Name | Description |
| ------------------------ | ---------------------------------------------------------------------------- |
| resource_group_link | URL to the created resource group.. |
| public_ips | Public IP address of the VMs. |
| resource_group | Name of the created resource group. |
| vnet | Name of the created vnet. |
| subnets | IDs of the created subnets. |
| locations | Regions where the VMs are deployed. |
| vm_names | Name of the VMs. |
| disk_size | Disk size. |
| os_version | Version of the GAIA OS. |

## Revision History
In order to check the template version refer to the [sk116585](https://supportcenter.checkpoint.com/supportcenter/portal?eventSubmit_doGoviewsolutiondetails=&solutionid=sk116585)

| Template Version | Description |
| ---------------- | ------------- |
| 20251501 | - Added output values |
| | | |
| 20240613 | - Updated Azure Terraform provider version <br> - Updated managed identity permissions <br> - Cosmetic fixes & default values <br> - Added option to limit storage account access by specify allowed sourcess <br> - Added validation for os_version & os_offer |
| | | |
| 20230910 | - R81.20 is the default version |
Expand Down
30 changes: 30 additions & 0 deletions terraform/azure/high-availability-new-vnet/outputs.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
locals {
vms = local.availability_set_condition? azurerm_virtual_machine.vm-instance-availability-set : azurerm_virtual_machine.vm-instance-availability-zone
}
output "resource_group_link" {
value = module.common.resource_group_link
}
output "public_ips" {
value = azurerm_public_ip.public-ip[*].ip_address
}
output "resource_group" {
value = local.vms[0].resource_group_name
}
output "vnet" {
value = module.vnet.vnet_name
}
output "subnets" {
value = module.vnet.vnet_subnets
}
output "locations" {
value = local.vms[*].location
}
output "vm_names" {
value = local.vms[*].name
}
output "disk_size" {
value = local.vms[0].storage_os_disk[0].disk_size_gb
}
output "os_version" {
value = module.common.os_version
}
16 changes: 16 additions & 0 deletions terraform/azure/management-existing-vnet/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -163,11 +163,27 @@ This solution uses the following modules:
storage_account_additional_ips = []



## Outputs

| Name | Description |
| ------------------------ | ---------------------------------------------------------------------------- |
| resource_group_link | URL to the created resource group.. |
| public_ip | Public IP address of the VM. |
| resource_group | Name of the created resource group. |
| subnets | IDs of the subnets. |
| location | Region where the VM is deployed. |
| vm_name | Name of the VM. |
| disk_size | Disk size. |
| os_version | Version of the GAIA OS. |

## Revision History
In order to check the template version refer to the [sk116585](https://supportcenter.checkpoint.com/supportcenter/portal?eventSubmit_doGoviewsolutiondetails=&solutionid=sk116585)

| Template Version | Description |
| ---------------- | ------------- |
| 20251501 | - Added output values |
| | | |
| 20240613 | - Updated Azure Terraform provider version <br> - Cosmetic fixes & default values <br> - Added option to limit storage account access by specify allowed sourcess <br> - Updated Public IP sku to Standard <br> - Added validation for os_version & os_offer |
| | | |
| 20230910 | - R81.20 is the default version |
Expand Down
24 changes: 24 additions & 0 deletions terraform/azure/management-existing-vnet/outputs.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
output "resource_group_link" {
value = module.common.resource_group_link
}
output "public_ip" {
value = azurerm_public_ip.public-ip.ip_address
}
output "resource_group" {
value = azurerm_virtual_machine.mgmt-vm-instance.resource_group_name
}
output "subnets" {
value = [data.azurerm_subnet.mgmt_subnet.id]
}
output "location" {
value = azurerm_virtual_machine.mgmt-vm-instance.location
}
output "vm_name" {
value = azurerm_virtual_machine.mgmt-vm-instance.name
}
output "disk_size" {
value = azurerm_virtual_machine.mgmt-vm-instance.storage_os_disk[0].disk_size_gb
}
output "os_version" {
value = module.common.os_version
}
18 changes: 18 additions & 0 deletions terraform/azure/management-new-vnet/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -161,11 +161,29 @@ This solution uses the following modules:
add_storage_account_ip_rules = false
storage_account_additional_ips = []


## Outputs

| Name | Description |
| ------------------------ | ---------------------------------------------------------------------------- |
| resource_group_link | URL to the created resource group.. |
| public_ip | Public IP address of the VM. |
| resource_group | Name of the created resource group. |
| vnet | Name of the created vnet. |
| subnets | IDs of the created subnets. |
| location | Region where the VM is deployed. |
| vm_name | Name of the VM. |
| disk_size | Disk size. |
| os_version | Version of the GAIA OS. |


## Revision History
In order to check the template version refer to the [sk116585](https://supportcenter.checkpoint.com/supportcenter/portal?eventSubmit_doGoviewsolutiondetails=&solutionid=sk116585)

| Template Version | Description |
| ---------------- | ------------- |
| 20251501 | - Added output values |
| | | |
| 20240613 | - Updated Azure Terraform provider version <br> - Cosmetic fixes & default values <br> - Added option to limit storage account access by specify allowed sourcess <br> - Updated Public IP sku to Standard <br> - Added validation for os_version & os_offer |
| | | |
| 20230910 | - R81.20 is the default version |
Expand Down
27 changes: 27 additions & 0 deletions terraform/azure/management-new-vnet/outputs.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
output "resource_group_link" {
value = module.common.resource_group_link
}
output "public_ip" {
value = azurerm_public_ip.public-ip.ip_address
}
output "resource_group" {
value = azurerm_virtual_machine.mgmt-vm-instance.resource_group_name
}
output "vnet" {
value = module.vnet.vnet_name
}
output "subnets" {
value = module.vnet.vnet_subnets
}
output "location" {
value = azurerm_virtual_machine.mgmt-vm-instance.location
}
output "vm_name" {
value = azurerm_virtual_machine.mgmt-vm-instance.name
}
output "disk_size" {
value = azurerm_virtual_machine.mgmt-vm-instance.storage_os_disk[0].disk_size_gb
}
output "os_version" {
value = module.common.os_version
}
17 changes: 17 additions & 0 deletions terraform/azure/mds-existing-vnet/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -177,11 +177,28 @@ This solution uses the following modules:
add_storage_account_ip_rules = false
storage_account_additional_ips = []


## Outputs

| Name | Description |
| ------------------------ | ---------------------------------------------------------------------------- |
| resource_group_link | URL to the created resource group.. |
| public_ip | Public IP address of the VM. |
| resource_group | Name of the created resource group. |
| subnets | IDs of the subnets. |
| location | Region where the VM is deployed. |
| vm_name | Name of the VM. |
| disk_size | Disk size. |
| os_version | Version of the GAIA OS. |


## Revision History
In order to check the template version refer to the [sk116585](https://supportcenter.checkpoint.com/supportcenter/portal?eventSubmit_doGoviewsolutiondetails=&solutionid=sk116585)

| Template Version | Description |
|------------------|---------------------------------------------------------------------------------------------|
| 20251501 | - Added output values |
| | | |
| 20240613 | - Updated Azure Terraform provider version <br> - Cosmetic fixes & default values <br> - Added option to limit storage account access by specify allowed sourcess <br> - Updated Public IP sku to Standard <br> - Added validation for os_version & os_offer |
| | | |
| 20230910 | - R81.20 is the default version |
Expand Down
24 changes: 24 additions & 0 deletions terraform/azure/mds-existing-vnet/outputs.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
output "resource_group_link" {
value = module.common.resource_group_link
}
output "public_ip" {
value = azurerm_public_ip.public-ip.ip_address
}
output "resource_group" {
value = azurerm_virtual_machine.mds-vm-instance.resource_group_name
}
output "subnets" {
value = [data.azurerm_subnet.mds_subnet.id]
}
output "location" {
value = azurerm_virtual_machine.mds-vm-instance.location
}
output "vm_name" {
value = azurerm_virtual_machine.mds-vm-instance.name
}
output "disk_size" {
value = azurerm_virtual_machine.mds-vm-instance.storage_os_disk[0].disk_size_gb
}
output "os_version" {
value = module.common.os_version
}
17 changes: 17 additions & 0 deletions terraform/azure/mds-new-vnet/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -170,11 +170,28 @@ This solution uses the following modules:
add_storage_account_ip_rules = false
storage_account_additional_ips = []

## Outputs

| Name | Description |
| ------------------------ | ---------------------------------------------------------------------------- |
| resource_group_link | URL to the created resource group.. |
| public_ip | Public IP address of the VM. |
| resource_group | Name of the created resource group. |
| vnet | Name of the created vnet. |
| subnets | IDs of the created subnets. |
| location | Region where the VM is deployed. |
| vm_name | Name of the VM. |
| disk_size | Disk size. |
| os_version | Version of the GAIA OS. |


## Revision History
In order to check the template version refer to the [sk116585](https://supportcenter.checkpoint.com/supportcenter/portal?eventSubmit_doGoviewsolutiondetails=&solutionid=sk116585)

| Template Version | Description |
|------------------|---------------------------------------------------------------------------------------------|
| 20251501 | - Added output values |
| | | |
| 20240613 | - Updated Azure Terraform provider version <br> - Cosmetic fixes & default values <br> - Added option to limit storage account access by specify allowed sourcess <br> - Updated Public IP sku to Standard <br> - Added validation for os_version & os_offer |
| | | |
| 20230910 | - R81.20 is the default version |
Expand Down
27 changes: 27 additions & 0 deletions terraform/azure/mds-new-vnet/outputs.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
output "resource_group_link" {
value = module.common.resource_group_link
}
output "public_ip" {
value = azurerm_public_ip.public-ip.ip_address
}
output "resource_group" {
value = azurerm_virtual_machine.mds-vm-instance.resource_group_name
}
output "vnet" {
value = module.vnet.vnet_name
}
output "subnets" {
value = module.vnet.vnet_subnets
}
output "location" {
value = azurerm_virtual_machine.mds-vm-instance.location
}
output "vm_name" {
value = azurerm_virtual_machine.mds-vm-instance.name
}
output "disk_size" {
value = azurerm_virtual_machine.mds-vm-instance.storage_os_disk[0].disk_size_gb
}
output "os_version" {
value = module.common.os_version
}
4 changes: 4 additions & 0 deletions terraform/azure/modules/common/outputs.tf
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@ output "azurerm_resource_group_id" {
value = azurerm_resource_group.resource_group.id
}

output "resource_group_link" {
value = "https://portal.azure.com/#@/resource${azurerm_resource_group.resource_group.id}"
}

output "admin_username" {
value = var.admin_username
}
Expand Down
17 changes: 17 additions & 0 deletions terraform/azure/single-gateway-existing-vnet/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -180,11 +180,28 @@ This solution uses the following modules:
add_storage_account_ip_rules = false
storage_account_additional_ips = []


## Outputs

| Name | Description |
| ------------------------ | ---------------------------------------------------------------------------- |
| resource_group_link | URL to the created resource group. |
| public_ip | Public IP address of the VM. |
| resource_group | Name of the created resource group. |
| subnets | IDs of the subnets. |
| location | Region where the VM is deployed. |
| vm_name | Name of the VM. |
| disk_size | Disk size. |
| os_version | Version of the GAIA OS. |


## Revision History
In order to check the template version refer to the [sk116585](https://supportcenter.checkpoint.com/supportcenter/portal?eventSubmit_doGoviewsolutiondetails=&solutionid=sk116585)

| Template Version | Description |
|------------------|---------------------------------------------------------------------------------------------------|
| 20251501 | - Added output values |
| | | |
| 20240613 | - Updated Azure Terraform provider version <br> - Cosmetic fixes & default values <br> - Added option to limit storage account access by specify allowed sourcess <br> - Added accelerated networking to SGW Terraform templates <br> - Updated Public IP sku to Standard <br> - Added validation for os_version & os_offer |
| | | |
| 20230910 | - R81.20 is the default version |
Expand Down
Loading

0 comments on commit 910eef8

Please sign in to comment.