81 lines
2.4 KiB
Terraform
81 lines
2.4 KiB
Terraform
variable "region" {
|
|
description = "AWS region for the managed VyOS network path."
|
|
type = string
|
|
}
|
|
|
|
variable "name_prefix" {
|
|
description = "Prefix used for isolated copies when an explicit production name is omitted."
|
|
type = string
|
|
}
|
|
|
|
variable "protect_from_destroy" {
|
|
description = "Protect the VyOS instance and security group from destroy. prod は true 固定。既存 workspace で true→false に反転しない。"
|
|
type = bool
|
|
default = true
|
|
}
|
|
|
|
variable "vpc_id" {
|
|
description = "Existing VPC ID containing the VyOS security group."
|
|
type = string
|
|
}
|
|
|
|
variable "subnet_id" {
|
|
description = "Existing subnet ID containing the VyOS primary network interface."
|
|
type = string
|
|
}
|
|
|
|
variable "key_name" {
|
|
description = "Existing EC2 key pair name used by VyOS."
|
|
type = string
|
|
}
|
|
|
|
variable "security_group" {
|
|
description = "Existing VyOS security group configuration."
|
|
type = object({
|
|
name = optional(string)
|
|
description = string
|
|
tags = optional(map(string), {})
|
|
})
|
|
}
|
|
|
|
variable "ingress_rules" {
|
|
description = "Existing VyOS ingress rules keyed by a stable logical name, one CIDR per resource."
|
|
type = map(object({
|
|
description = optional(string)
|
|
ip_protocol = string
|
|
from_port = optional(number)
|
|
to_port = optional(number)
|
|
cidr_ipv4 = string
|
|
}))
|
|
}
|
|
|
|
variable "instance" {
|
|
description = "Existing VyOS EC2 instance. user_data is intentionally absent."
|
|
type = object({
|
|
name = optional(string)
|
|
ami = string
|
|
instance_type = string
|
|
private_ip = string
|
|
associate_public_ip_address = bool
|
|
source_dest_check = bool
|
|
ebs_optimized = bool
|
|
monitoring = bool
|
|
metadata_options = object({
|
|
http_endpoint = string
|
|
http_tokens = string
|
|
http_put_response_hop_limit = number
|
|
http_protocol_ipv6 = string
|
|
instance_metadata_tags = string
|
|
})
|
|
root_block_device = object({
|
|
delete_on_termination = bool
|
|
encrypted = bool
|
|
volume_size = number
|
|
volume_type = string
|
|
iops = optional(number)
|
|
throughput = optional(number)
|
|
})
|
|
tags = optional(map(string), {})
|
|
})
|
|
}
|