Skip to content

Commit b3661b9

Browse files
authored
feat: make nat_ip of access_config optional (#463)
1 parent 1b657fe commit b3661b9

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

modules/instance_template/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ See the [simple](../../examples/instance_template/simple) for a usage example.
1313

1414
| Name | Description | Type | Default | Required |
1515
|------|-------------|------|---------|:--------:|
16-
| access\_config | Access configurations, i.e. IPs via which the VM instance can be accessed via the Internet. | <pre>list(object({<br> nat_ip = string<br> network_tier = string<br> }))</pre> | `[]` | no |
16+
| access\_config | Access configurations, i.e. IPs via which the VM instance can be accessed via the Internet. | <pre>list(object({<br> nat_ip = optional(string)<br> network_tier = string<br> }))</pre> | `[]` | no |
1717
| additional\_disks | List of maps of additional disks. See https://www.terraform.io/docs/providers/google/r/compute_instance_template#disk_name | <pre>list(object({<br> auto_delete = optional(bool, true)<br> boot = optional(bool, false)<br> device_name = optional(string)<br> disk_name = optional(string)<br> disk_size_gb = optional(number)<br> disk_type = optional(string)<br> disk_labels = optional(map(string), {})<br> interface = optional(string)<br> mode = optional(string)<br> source = optional(string)<br> source_image = optional(string)<br> source_snapshot = optional(string)<br> }))</pre> | `[]` | no |
1818
| additional\_networks | Additional network interface details for GCE, if any. | <pre>list(object({<br> network = string<br> subnetwork = string<br> subnetwork_project = string<br> network_ip = string<br> nic_type = string<br> stack_type = string<br> queue_count = number<br> access_config = list(object({<br> nat_ip = string<br> network_tier = string<br> }))<br> ipv6_access_config = list(object({<br> network_tier = string<br> }))<br> alias_ip_range = list(object({<br> ip_cidr_range = string<br> subnetwork_range_name = string<br> }))<br> }))</pre> | `[]` | no |
1919
| alias\_ip\_range | An array of alias IP ranges for this network interface. Can only be specified for network interfaces on subnet-mode networks.<br>ip\_cidr\_range: The IP CIDR range represented by this alias IP range. This IP CIDR range must belong to the specified subnetwork and cannot contain IP addresses reserved by system or used by other network interfaces. At the time of writing only a netmask (e.g. /24) may be supplied, with a CIDR format resulting in an API error.<br>subnetwork\_range\_name: The subnetwork secondary range name specifying the secondary range from which to allocate the IP CIDR range for this alias IP range. If left unspecified, the primary range of the subnetwork will be used. | <pre>object({<br> ip_cidr_range = string<br> subnetwork_range_name = string<br> })</pre> | `null` | no |

modules/instance_template/metadata.display.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright 2024 Google LLC
1+
# Copyright 2025 Google LLC
22
#
33
# Licensed under the Apache License, Version 2.0 (the "License");
44
# you may not use this file except in compliance with the License.

modules/instance_template/metadata.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -327,7 +327,7 @@ spec:
327327
description: Access configurations, i.e. IPs via which the VM instance can be accessed via the Internet.
328328
varType: |-
329329
list(object({
330-
nat_ip = string
330+
nat_ip = optional(string)
331331
network_tier = string
332332
}))
333333
defaultValue: []

modules/instance_template/variables.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -375,7 +375,7 @@ variable "confidential_instance_type" {
375375
variable "access_config" {
376376
description = "Access configurations, i.e. IPs via which the VM instance can be accessed via the Internet."
377377
type = list(object({
378-
nat_ip = string
378+
nat_ip = optional(string)
379379
network_tier = string
380380
}))
381381
default = []

0 commit comments

Comments
 (0)