Skip to content

Commit

Permalink
Merge branch 'main' into FT_add_interfaces
Browse files Browse the repository at this point in the history
  • Loading branch information
rrahimm authored Jan 13, 2025
2 parents a1fe31f + 696d60d commit 2cec761
Show file tree
Hide file tree
Showing 8 changed files with 905 additions and 350 deletions.
12 changes: 10 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
## 0.1.1 (unreleased)

- rename "sdwan_profile_parcels.tf" to "sdwan_features.tf"
- provide default value for name if not explicitly set for sdwan_system_basic_feature, sdwan_system_omp_feature, sdwan_system_performance_monitoring_feature, sdwan_system_security_feature, sdwan_system_snmp_feature and sdwan_transport_wan_vpn_feature
- simplify default feature name from "profile_name-feature_name" to "feature_name"
- add support for sdwan_policy_object_feature_profile resource
Expand All @@ -18,11 +17,20 @@
- fix issue where sdwan_custom_control_topology_policy_definition always shows diff when match_criterias or actions are not configured in data model
- fix issue where sdwan_traffic_data_policy_definition always shows diff when match_criterias or actions are not configured in data model
- fix issue where sdwan_application_aware_routing_policy_definition always shows diff when match_criterias or actions are not configured in data model
- add defaults for UX 2.0 feature names
- fix issue where certain parameters were required by sdwan_cflowd_policy_definition resource, but are optional in the UI
- fix issue where authentication_type_variable was not configurable with sdwan_cisco_security_feature_template
- in sdwan_cflowd_policy_definition, fix export_spreading to be optional
- add gateway parameter to ipv6_static_routes of sdwan_transport_wan_vpn_feature
- add support for sdwan_other_ucse_feature resource
- add support for sdwan_transport_management_vpn_feature resource
- add support for sdwan_transport_management_vpn_interface_ethernet_feature resource
- separate "sdwan_profile_parcels.tf" into "sdwan_features_cli.tf", "sdwan_features_other.tf", "sdwan_features_service.tf", "sdwan_features_system.tf" and "sdwan_features_transport.tf"
- rename sdwan_system_performance_monitoring_feature resources from "...-performance_monitor" to "...-perfmonitor"
- add support for sdwan_transport_wan_vpn_ethernet_interface resource
- add support for sdwan_transport_wan_vpn_interface_ethernet_feature_associate_tracker_feature resource
- add support for sdwan_transport_wan_vpn_interface_ethernet_feature_associate_tracker_group_feature resource
- add support for sdwan_transport_wan_vpn_interface_ethernet_feature_associate_ipv6_tracker_feature resource
- add support for sdwan_transport_wan_vpn_interface_ethernet_feature_associate_ipv6_tracker_group_feature resource
- add support for sdwan_cellular_controller_feature_template resource
- add support for sdwan_cellular_cedge_profile_feature_template resource
- add support for sdwan_cisco_vpn_interface_gre_feature_template resource
Expand Down
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,7 @@ module "sdwan" {
| [sdwan_mirror_policy_object.mirror_policy_object](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/mirror_policy_object) | resource |
| [sdwan_other_feature_profile.other_feature_profile](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/other_feature_profile) | resource |
| [sdwan_other_thousandeyes_feature.other_thousandeyes_feature](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/other_thousandeyes_feature) | resource |
| [sdwan_other_ucse_feature.other_ucse_feature](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/other_ucse_feature) | resource |
| [sdwan_policer_policy_object.policer_policy_object](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/policer_policy_object) | resource |
| [sdwan_policy_object_class_map.policy_object_class_map](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/policy_object_class_map) | resource |
| [sdwan_policy_object_data_ipv4_prefix_list.policy_object_data_ipv4_prefix_list](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/policy_object_data_ipv4_prefix_list) | resource |
Expand Down Expand Up @@ -175,10 +176,17 @@ module "sdwan" {
| [sdwan_transport_feature_profile.transport_feature_profile](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/transport_feature_profile) | resource |
| [sdwan_transport_ipv6_tracker_feature.transport_ipv6_tracker_feature](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/transport_ipv6_tracker_feature) | resource |
| [sdwan_transport_ipv6_tracker_group_feature.transport_ipv6_tracker_group_feature](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/transport_ipv6_tracker_group_feature) | resource |
| [sdwan_transport_management_vpn_feature.transport_management_vpn_feature](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/transport_management_vpn_feature) | resource |
| [sdwan_transport_management_vpn_interface_ethernet_feature.transport_management_vpn_interface_ethernet_feature](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/transport_management_vpn_interface_ethernet_feature) | resource |
| [sdwan_transport_tracker_feature.transport_tracker_feature](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/transport_tracker_feature) | resource |
| [sdwan_transport_tracker_group_feature.transport_tracker_group_feature](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/transport_tracker_group_feature) | resource |
| [sdwan_transport_wan_vpn_feature.transport_wan_vpn_feature](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/transport_wan_vpn_feature) | resource |
| [sdwan_vpn_interface_cellular_feature_template.vpn_interface_cellular_feature_template](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/vpn_interface_cellular_feature_template) | resource |
| [sdwan_transport_wan_vpn_interface_ethernet_feature.transport_wan_vpn_interface_ethernet_feature](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/transport_wan_vpn_interface_ethernet_feature) | resource |
| [sdwan_transport_wan_vpn_interface_ethernet_feature_associate_ipv6_tracker_feature.transport_wan_vpn_interface_ethernet_feature_associate_ipv6_tracker_feature](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/transport_wan_vpn_interface_ethernet_feature_associate_ipv6_tracker_feature) | resource |
| [sdwan_transport_wan_vpn_interface_ethernet_feature_associate_ipv6_tracker_group_feature.transport_wan_vpn_interface_ethernet_feature_associate_ipv6_tracker_group_feature](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/transport_wan_vpn_interface_ethernet_feature_associate_ipv6_tracker_group_feature) | resource |
| [sdwan_transport_wan_vpn_interface_ethernet_feature_associate_tracker_feature.transport_wan_vpn_interface_ethernet_feature_associate_tracker_feature](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/transport_wan_vpn_interface_ethernet_feature_associate_tracker_feature) | resource |
| [sdwan_transport_wan_vpn_interface_ethernet_feature_associate_tracker_group_feature.transport_wan_vpn_interface_ethernet_feature_associate_tracker_group_feature](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/transport_wan_vpn_interface_ethernet_feature_associate_tracker_group_feature) | resource |
| [sdwan_vpn_interface_svi_feature_template.vpn_interface_svi_feature_template](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/vpn_interface_svi_feature_template) | resource |
| [sdwan_vpn_list_policy_object.vpn_list_policy_object](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/vpn_list_policy_object) | resource |
| [sdwan_vpn_membership_policy_definition.vpn_membership_policy_definition](https://registry.terraform.io/providers/CiscoDevNet/sdwan/latest/docs/resources/vpn_membership_policy_definition) | resource |
Expand Down
32 changes: 32 additions & 0 deletions defaults/sdwan.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,19 @@ defaults:
sdwan:
centralized_policies:
definitions:
control_policy:
custom_control_topology:
sequences:
ip_type: ipv4
data_policy:
application_aware_routing:
sequences:
ip_type: ipv4
type: app_route
traffic_data:
sequences:
ip_type: ipv4
type: custom
cflowd:
protocol: ipv4
tos: false
Expand Down Expand Up @@ -325,6 +337,8 @@ defaults:
other_profiles:
thousandeyes:
name: thousandeyes
ucse:
name: ucse
system_profiles:
aaa:
name: aaa
Expand Down Expand Up @@ -355,5 +369,23 @@ defaults:
snmp:
name: snmp
transport_profiles:
management_vpn:
name: management_vpn
ethernet_interfaces:
ipv4_configuration_type: static
ipv6_configuration_type: none
ipv4_static_routes:
gateway: nextHop
ipv6_static_routes:
gateway: nextHop
wan_vpn:
name: wan_vpn
ethernet_interfaces:
ipv4_configuration_type: static
ipv6_configuration_type: none
tunnel_interface:
ipsec_encapsulation: true
ipv4_static_routes:
gateway: nextHop
ipv6_static_routes:
gateway: nextHop
11 changes: 11 additions & 0 deletions sdwan_features_cli.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
resource "sdwan_cli_config_feature" "cli_config_feature" {
for_each = {
for cli in try(local.feature_profiles.cli_profiles, {}) :
"${cli.name}-config" => cli
if try(cli.config, null) != null
}
name = try(each.value.config.name, local.defaults.sdwan.feature_profiles.cli_profiles.config.name)
description = try(each.value.config.description, "")
feature_profile_id = sdwan_cli_feature_profile.cli_feature_profile[each.value.name].id
cli_configuration = each.value.config.cli_configuration
}
65 changes: 65 additions & 0 deletions sdwan_features_other.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
resource "sdwan_other_thousandeyes_feature" "other_thousandeyes_feature" {
for_each = {
for other in try(local.feature_profiles.other_profiles, {}) :
"${other.name}-thousandeyes" => other
if try(other.thousandeyes, null) != null
}
name = try(each.value.thousandeyes.name, local.defaults.sdwan.feature_profiles.other_profiles.thousandeyes.name)
description = try(each.value.thousandeyes.description, "")
feature_profile_id = sdwan_other_feature_profile.other_feature_profile[each.value.name].id
virtual_application = [{
account_group_token = try(each.value.thousandeyes.account_group_token, null)
account_group_token_variable = try("{{${each.value.thousandeyes.account_group_token_variable}}}", null)
agent_default_gateway = try(each.value.thousandeyes.agent_default_gateway, null)
agent_default_gateway_variable = try("{{${each.value.thousandeyes.agent_default_gateway_variable}}}", null)
hostname = try(each.value.thousandeyes.hostname, null)
hostname_variable = try("{{${each.value.thousandeyes.hostname_variable}}}", null)
management_ip = try(each.value.thousandeyes.management_ip, null)
management_ip_variable = try("{{${each.value.thousandeyes.management_ip_variable}}}", null)
management_subnet_mask = try(each.value.thousandeyes.management_subnet_mask, null)
management_subnet_mask_variable = try("{{${each.value.thousandeyes.management_subnet_mask_variable}}}", null)
name_server_ip = try(each.value.thousandeyes.name_server_ip, null)
name_server_ip_variable = try("{{${each.value.thousandeyes.name_server_ip_variable}}}", null)
pac_url = try(each.value.thousandeyes.pac_proxy_url, null)
pac_url_variable = try("{{${each.value.thousandeyes.pac_proxy_url_variable}}}", null)
proxy_host = try(each.value.thousandeyes.static_proxy_host, null)
proxy_host_variable = try("{{${each.value.thousandeyes.static_proxy_host_variable}}}", null)
proxy_port = try(each.value.thousandeyes.static_proxy_port, null)
proxy_port_variable = try("{{${each.value.thousandeyes.static_proxy_port_variable}}}", null)
proxy_type = try(each.value.thousandeyes.proxy_type, null)
vpn = try(each.value.thousandeyes.vpn_id, null)
vpn_variable = try("{{${each.value.thousandeyes.vpn_id_variable}}}", null)
}]
}

resource "sdwan_other_ucse_feature" "other_ucse_feature" {
for_each = {
for other in try(local.feature_profiles.other_profiles, {}) :
"${other.name}-ucse" => other
if try(other.ucse, null) != null
}
name = try(each.value.ucse.name, local.defaults.sdwan.feature_profiles.other_profiles.ucse.name)
description = try(each.value.ucse.description, "")
feature_profile_id = sdwan_other_feature_profile.other_feature_profile[each.value.name].id
access_port_dedicated = try(each.value.ucse.cimc_access_port_dedicated, null)
access_port_shared_failover_type = try(each.value.ucse.cimc_access_port_shared_failover_type, null)
access_port_shared_type = try(each.value.ucse.cimc_access_port_shared_type, null)
assign_priority = try(each.value.ucse.cimc_assign_priority, null)
assign_priority_variable = try("{{${each.value.ucse.cimc_assign_priority_variable}}}", null)
bay = each.value.ucse.bay
default_gateway = try(each.value.ucse.cimc_default_gateway, null)
default_gateway_variable = try("{{${each.value.ucse.cimc_default_gateway_variable}}}", null)
interfaces = try(length(each.value.ucse.interfaces) == 0, true) ? null : [for i in each.value.ucse.interfaces : {
interface_name = try(i.interface_name, null)
interface_name_variable = try("{{${i.interface_name_variable}}}", null)
ipv4_address = try(i.ipv4_address, null)
ipv4_address_variable = try("{{${i.ipv4_address_variable}}}", null)
ucse_interface_vpn = try(i.vpn_id, null)
ucse_interface_vpn_variable = try("{{${i.vpn_id_variable}}}", null)
}]
ipv4_address = try(each.value.ucse.cimc_ipv4_address, null)
ipv4_address_variable = try("{{${each.value.ucse.cimc_ipv4_address_variable}}}", null)
slot = each.value.ucse.slot
vlan_id = try(each.value.ucse.cimc_vlan_id, null)
vlan_id_variable = try("{{${each.value.ucse.cimc_vlan_id_variable}}}", null)
}
Loading

0 comments on commit 2cec761

Please sign in to comment.