diff --git a/README.md b/README.md
index b62c6c3..d99b491 100644
--- a/README.md
+++ b/README.md
@@ -39,7 +39,7 @@ module "nxos" {
| Name | Version |
|------|---------|
-| [terraform](#requirement\_terraform) | >= 1.8.0 |
+| [terraform](#requirement\_terraform) | >= 1.9.0 |
| [local](#requirement\_local) | >= 2.3.0 |
| [nxos](#requirement\_nxos) | >= 0.5.9 |
| [utils](#requirement\_utils) | >= 0.2.6 |
@@ -141,6 +141,7 @@ module "nxos" {
| [nxos_pim_anycast_rp_peer.pim_anycast_rp_peer](https://registry.terraform.io/providers/CiscoDevNet/nxos/latest/docs/resources/pim_anycast_rp_peer) | resource |
| [nxos_pim_instance.pim_instance](https://registry.terraform.io/providers/CiscoDevNet/nxos/latest/docs/resources/pim_instance) | resource |
| [nxos_pim_interface.pim_interface](https://registry.terraform.io/providers/CiscoDevNet/nxos/latest/docs/resources/pim_interface) | resource |
+| [nxos_pim_ssm_range.pim_ssm_range](https://registry.terraform.io/providers/CiscoDevNet/nxos/latest/docs/resources/pim_ssm_range) | resource |
| [nxos_pim_static_rp.pim_static_rp](https://registry.terraform.io/providers/CiscoDevNet/nxos/latest/docs/resources/pim_static_rp) | resource |
| [nxos_pim_static_rp_group_list.pim_static_rp_group_list](https://registry.terraform.io/providers/CiscoDevNet/nxos/latest/docs/resources/pim_static_rp_group_list) | resource |
| [nxos_pim_static_rp_policy.pim_static_rp_policy](https://registry.terraform.io/providers/CiscoDevNet/nxos/latest/docs/resources/pim_static_rp_policy) | resource |
diff --git a/defaults/defaults.yaml b/defaults/defaults.yaml
index 6e6d834..3ebf450 100644
--- a/defaults/defaults.yaml
+++ b/defaults/defaults.yaml
@@ -24,6 +24,7 @@ defaults:
pim:
vrfs:
admin_state: true
+ ssm_range_none: false
ospf_processes:
vrfs:
admin_state: true
diff --git a/nxos_pim.tf b/nxos_pim.tf
index f0182f9..657f35c 100644
--- a/nxos_pim.tf
+++ b/nxos_pim.tf
@@ -23,6 +23,10 @@ locals {
anycast_rp_local_interface = try(vrf.anycast_rp_local_interface, local.defaults.nxos.devices.configuration.routing.pim.vrfs.anycast_rp_local_interface, "unspecified")
anycast_rp_source_interface = try(vrf.anycast_rp_source_interface, local.defaults.nxos.devices.configuration.routing.pim.vrfs.anycast_rp_source_interface, "unspecified")
rp = try(length(vrf.rps), 0) > 0
+ ssm_ranges = try(vrf.ssm_ranges, [])
+ ssm_prefix_list = try(vrf.ssm_prefix_list, "")
+ ssm_route_map = try(vrf.ssm_route_map, "")
+ ssm_none = try(vrf.ssm_range_none, local.defaults.nxos.devices.configuration.routing.pim.vrfs.ssm_range_none)
}
]
])
@@ -40,6 +44,18 @@ resource "nxos_pim_vrf" "pim_vrf" {
]
}
+resource "nxos_pim_ssm_range" "pim_ssm_range" {
+ for_each = { for v in local.routing_pim_vrfs : v.key => v }
+ vrf_name = nxos_pim_vrf.pim_vrf[each.key].name
+ group_list_1 = try(each.value.ssm_ranges[0], null)
+ group_list_2 = try(each.value.ssm_ranges[1], null)
+ group_list_3 = try(each.value.ssm_ranges[2], null)
+ group_list_4 = try(each.value.ssm_ranges[3], null)
+ prefix_list = each.value.ssm_prefix_list
+ route_map = each.value.ssm_route_map
+ ssm_none = each.value.ssm_none
+}
+
resource "nxos_pim_static_rp_policy" "pim_static_rp_policy" {
for_each = { for v in local.routing_pim_vrfs : v.key => v if v.rp }
device = each.value.device
@@ -52,7 +68,7 @@ locals {
for device in local.devices : [
for vrf in try(local.device_config[device.name].routing.pim.vrfs, []) : [
for rp in try(vrf.rps, []) : {
- key = format("%s/%s/%s", device.name, vrf.vrf, rp.address)
+ key = format("%s/%s/%s/%s", device.name, vrf.vrf, rp.address, try(rp.group_range, local.defaults.nxos.devices.configuration.routing.pim.vrfs.rps.group_range, "224.0.0.0/4"))
device = device.name
vrf_key = format("%s/%s", device.name, vrf.vrf)
address = rp.address
diff --git a/versions.tf b/versions.tf
index 4055511..9f1712d 100644
--- a/versions.tf
+++ b/versions.tf
@@ -1,5 +1,5 @@
terraform {
- required_version = ">= 1.8.0"
+ required_version = ">= 1.9.0"
required_providers {
nxos = {