simple-nva: add ability to parse BGP configs as strings. (#1268)
* Add ability to parse BGP configs as strings. * Fix var name * Refresh tfdoc --------- Co-authored-by: Luca Prete <lucaprete@google.com>
This commit is contained in:
parent
5edc931bf9
commit
6e49e94749
|
@ -144,7 +144,7 @@ module "vm" {
|
|||
| [cloud_config](variables.tf#L17) | Cloud config template path. If null default will be used. | <code>string</code> | | <code>null</code> |
|
||||
| [enable_health_checks](variables.tf#L23) | Configures routing to enable responses to health check probes. | <code>bool</code> | | <code>false</code> |
|
||||
| [files](variables.tf#L29) | Map of extra files to create on the instance, path as key. Owner and permissions will use defaults if null. | <code title="map(object({ content = string owner = string permissions = string }))">map(object({…}))</code> | | <code>{}</code> |
|
||||
| [frr_config](variables.tf#L39) | FRR configuration for container running on the NVA. | <code title="object({ daemons_enabled = optional(list(string)) config_file = string })">object({…})</code> | | <code>null</code> |
|
||||
| [frr_config](variables.tf#L39) | FRR configuration for container running on the NVA. | <code title="object({ config_file = string daemons_enabled = optional(list(string)) })">object({…})</code> | | <code>null</code> |
|
||||
| [optional_run_cmds](variables.tf#L84) | Optional Cloud Init run commands to execute. | <code>list(string)</code> | | <code>[]</code> |
|
||||
|
||||
## Outputs
|
||||
|
|
|
@ -41,7 +41,8 @@ locals {
|
|||
permissions = "0744"
|
||||
}
|
||||
"/etc/frr/frr.conf" = {
|
||||
content = file(var.frr_config.config_file)
|
||||
# content can either be the path to the config file or the config string
|
||||
content = try(file(var.frr_config.config_file), var.frr_config.config_file)
|
||||
owner = "root"
|
||||
permissions = "0744"
|
||||
}
|
||||
|
|
|
@ -39,8 +39,8 @@ variable "files" {
|
|||
variable "frr_config" {
|
||||
description = "FRR configuration for container running on the NVA."
|
||||
type = object({
|
||||
daemons_enabled = optional(list(string))
|
||||
config_file = string
|
||||
daemons_enabled = optional(list(string))
|
||||
})
|
||||
default = null
|
||||
validation {
|
||||
|
|
Loading…
Reference in New Issue