Skip to content

Commit 3b05eb7

Browse files
authored
Add hsrp resources and data sources (#172)
1 parent 3a68cab commit 3b05eb7

27 files changed

+3802
-1
lines changed

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,9 @@
1212
- Add `load_balancing_flow_src_dst_mac` and `load_balancing_flow_src_dst_ip` attributes to `iosxr_l2vpn` resource and data source
1313
- Add `iosxr_l2vpn_pw_class` resource and data source
1414
- Add `igp_sync_delay` and `label_local_allocate` attributes to `iosxr_mpls_ldp` resource and data source
15+
- Add `iosxr_router_hsrp_interface` resource and data source
16+
- Add `iosxr_router_hsrp_interface_address_family_ipv4` resource and data source
17+
1518

1619
## 0.2.3
1720

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
---
2+
# generated by https://github.com/hashicorp/terraform-plugin-docs
3+
page_title: "iosxr_router_hsrp_interface Data Source - terraform-provider-iosxr"
4+
subcategory: "HSRP"
5+
description: |-
6+
This data source can read the Router HSRP Interface configuration.
7+
---
8+
9+
# iosxr_router_hsrp_interface (Data Source)
10+
11+
This data source can read the Router HSRP Interface configuration.
12+
13+
## Example Usage
14+
15+
```terraform
16+
data "iosxr_router_hsrp_interface" "example" {
17+
interface_name = "GigabitEthernet0/0/0/1"
18+
}
19+
```
20+
21+
<!-- schema generated by tfplugindocs -->
22+
## Schema
23+
24+
### Required
25+
26+
- `interface_name` (String) HSRP interface configuration subcommands
27+
28+
### Optional
29+
30+
- `device` (String) A device name from the provider configuration.
31+
32+
### Read-Only
33+
34+
- `hsrp_bfd_minimum_interval` (Number) Hello interval
35+
- `hsrp_bfd_multiplier` (Number) Detect multiplier
36+
- `hsrp_delay_minimum` (Number) Set minimum delay on every interface up event
37+
- `hsrp_delay_reload` (Number) Set reload delay for first interface up event
38+
- `hsrp_mac_refresh` (Number) HSRP MGO subordinate MAC refresh rate
39+
- `hsrp_redirects_disable` (Boolean) Disable HSRP filtered ICMP redirects
40+
- `hsrp_use_bia` (Boolean) Use burned-in address
41+
- `id` (String) The path of the retrieved object.
Lines changed: 132 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,132 @@
1+
---
2+
# generated by https://github.com/hashicorp/terraform-plugin-docs
3+
page_title: "iosxr_router_hsrp_interface_address_family_ipv4 Data Source - terraform-provider-iosxr"
4+
subcategory: "HSRP"
5+
description: |-
6+
This data source can read the Router HSRP Interface Address Family IPv4 configuration.
7+
---
8+
9+
# iosxr_router_hsrp_interface_address_family_ipv4 (Data Source)
10+
11+
This data source can read the Router HSRP Interface Address Family IPv4 configuration.
12+
13+
## Example Usage
14+
15+
```terraform
16+
data "iosxr_router_hsrp_interface_address_family_ipv4" "example" {
17+
interface_name = "GigabitEthernet0/0/0/1"
18+
}
19+
```
20+
21+
<!-- schema generated by tfplugindocs -->
22+
## Schema
23+
24+
### Required
25+
26+
- `interface_name` (String) HSRP interface configuration subcommands
27+
28+
### Optional
29+
30+
- `device` (String) A device name from the provider configuration.
31+
32+
### Read-Only
33+
34+
- `group_number_version_1s` (Attributes List) group number version 1 (see [below for nested schema](#nestedatt--group_number_version_1s))
35+
- `group_number_version_2s` (Attributes List) group number version 2 (see [below for nested schema](#nestedatt--group_number_version_2s))
36+
- `id` (String) The path of the retrieved object.
37+
38+
<a id="nestedatt--group_number_version_1s"></a>
39+
### Nested Schema for `group_number_version_1s`
40+
41+
Read-Only:
42+
43+
- `address_ipv4_address` (String) Hot standby IP address
44+
- `address_learn` (Boolean) Learn virtual IP address from peer
45+
- `bfd_fast_detect_peer_interface` (String) Select an interface over which to run BFD
46+
- `bfd_fast_detect_peer_ipv4` (String) BFD peer interface IPv4 address
47+
- `group_number_version_1_id` (Number) group number version 1
48+
- `mac_address` (String) Use specified mac address for the virtual router
49+
- `name` (String) MGO session name
50+
- `preempt_delay` (Number) Wait before preempting
51+
- `priority` (Number) Priority level
52+
- `secondary_ipv4_addresses` (Attributes List) Set secondary hot standby IP address (see [below for nested schema](#nestedatt--group_number_version_1s--secondary_ipv4_addresses))
53+
- `timers_hold_time` (Number) Hold time in seconds
54+
- `timers_hold_time2` (Number) Hold time in seconds
55+
- `timers_msec` (Number) Specify hellotime in milliseconds
56+
- `timers_msec2` (Number) Specify hold time in milliseconds
57+
- `track_interfaces` (Attributes List) Configure tracking (see [below for nested schema](#nestedatt--group_number_version_1s--track_interfaces))
58+
- `track_objects` (Attributes List) Object tracking (see [below for nested schema](#nestedatt--group_number_version_1s--track_objects))
59+
60+
<a id="nestedatt--group_number_version_1s--secondary_ipv4_addresses"></a>
61+
### Nested Schema for `group_number_version_1s.secondary_ipv4_addresses`
62+
63+
Read-Only:
64+
65+
- `address` (String) Set secondary hot standby IP address
66+
67+
68+
<a id="nestedatt--group_number_version_1s--track_interfaces"></a>
69+
### Nested Schema for `group_number_version_1s.track_interfaces`
70+
71+
Read-Only:
72+
73+
- `priority_decrement` (Number) Priority decrement
74+
- `track_name` (String) Configure tracking
75+
76+
77+
<a id="nestedatt--group_number_version_1s--track_objects"></a>
78+
### Nested Schema for `group_number_version_1s.track_objects`
79+
80+
Read-Only:
81+
82+
- `object_name` (String) Object tracking
83+
- `priority_decrement` (Number) Priority decrement
84+
85+
86+
87+
<a id="nestedatt--group_number_version_2s"></a>
88+
### Nested Schema for `group_number_version_2s`
89+
90+
Read-Only:
91+
92+
- `address_ipv4_address` (String) Hot standby IP address
93+
- `address_learn` (Boolean) Learn virtual IP address from peer
94+
- `bfd_fast_detect_peer_interface` (String) Select an interface over which to run BFD
95+
- `bfd_fast_detect_peer_ipv4` (String) BFD peer interface IPv4 address
96+
- `group_number_version_2_id` (Number) group number version 2
97+
- `mac_address` (String) Use specified mac address for the virtual router
98+
- `name` (String) MGO session name
99+
- `preempt_delay` (Number) Wait before preempting
100+
- `priority` (Number) Priority level
101+
- `secondary_ipv4_addresses` (Attributes List) Set secondary hot standby IP address (see [below for nested schema](#nestedatt--group_number_version_2s--secondary_ipv4_addresses))
102+
- `timers_hold_time` (Number) Hold time in seconds
103+
- `timers_hold_time2` (Number) Hold time in seconds
104+
- `timers_msec` (Number) Specify hellotime in milliseconds
105+
- `timers_msec2` (Number) Specify hold time in milliseconds
106+
- `track_interfaces` (Attributes List) Configure tracking (see [below for nested schema](#nestedatt--group_number_version_2s--track_interfaces))
107+
- `track_objects` (Attributes List) Object tracking (see [below for nested schema](#nestedatt--group_number_version_2s--track_objects))
108+
109+
<a id="nestedatt--group_number_version_2s--secondary_ipv4_addresses"></a>
110+
### Nested Schema for `group_number_version_2s.secondary_ipv4_addresses`
111+
112+
Read-Only:
113+
114+
- `address` (String) Set secondary hot standby IP address
115+
116+
117+
<a id="nestedatt--group_number_version_2s--track_interfaces"></a>
118+
### Nested Schema for `group_number_version_2s.track_interfaces`
119+
120+
Read-Only:
121+
122+
- `priority_decrement` (Number) Priority decrement
123+
- `track_name` (String) Configure tracking
124+
125+
126+
<a id="nestedatt--group_number_version_2s--track_objects"></a>
127+
### Nested Schema for `group_number_version_2s.track_objects`
128+
129+
Read-Only:
130+
131+
- `object_name` (String) Object tracking
132+
- `priority_decrement` (Number) Priority decrement

docs/guides/changelog.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@ description: |-
2121
- Add `load_balancing_flow_src_dst_mac` and `load_balancing_flow_src_dst_ip` attributes to `iosxr_l2vpn` resource and data source
2222
- Add `iosxr_l2vpn_pw_class` resource and data source
2323
- Add `igp_sync_delay` and `label_local_allocate` attributes to `iosxr_mpls_ldp` resource and data source
24+
- Add `iosxr_router_hsrp_interface` resource and data source
25+
- Add `iosxr_router_hsrp_interface_address_family_ipv4` resource and data source
26+
2427

2528
## 0.2.3
2629

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
---
2+
# generated by https://github.com/hashicorp/terraform-plugin-docs
3+
page_title: "iosxr_router_hsrp_interface Resource - terraform-provider-iosxr"
4+
subcategory: "HSRP"
5+
description: |-
6+
This resource can manage the Router HSRP Interface configuration.
7+
---
8+
9+
# iosxr_router_hsrp_interface (Resource)
10+
11+
This resource can manage the Router HSRP Interface configuration.
12+
13+
## Example Usage
14+
15+
```terraform
16+
resource "iosxr_router_hsrp_interface" "example" {
17+
interface_name = "GigabitEthernet0/0/0/1"
18+
hsrp_use_bia = true
19+
hsrp_redirects_disable = true
20+
hsrp_delay_minimum = 500
21+
hsrp_delay_reload = 700
22+
hsrp_bfd_minimum_interval = 20000
23+
hsrp_bfd_multiplier = 40
24+
hsrp_mac_refresh = 5000
25+
}
26+
```
27+
28+
<!-- schema generated by tfplugindocs -->
29+
## Schema
30+
31+
### Required
32+
33+
- `interface_name` (String) HSRP interface configuration subcommands
34+
35+
### Optional
36+
37+
- `delete_mode` (String) Configure behavior when deleting/destroying the resource. Either delete the entire object (YANG container) being managed, or only delete the individual resource attributes configured explicitly and leave everything else as-is. Default value is `all`.
38+
- Choices: `all`, `attributes`
39+
- `device` (String) A device name from the provider configuration.
40+
- `hsrp_bfd_minimum_interval` (Number) Hello interval
41+
- Range: `3`-`30000`
42+
- `hsrp_bfd_multiplier` (Number) Detect multiplier
43+
- Range: `2`-`50`
44+
- `hsrp_delay_minimum` (Number) Set minimum delay on every interface up event
45+
- Range: `0`-`10000`
46+
- `hsrp_delay_reload` (Number) Set reload delay for first interface up event
47+
- Range: `0`-`10000`
48+
- `hsrp_mac_refresh` (Number) HSRP MGO subordinate MAC refresh rate
49+
- Range: `0`-`10000`
50+
- `hsrp_redirects_disable` (Boolean) Disable HSRP filtered ICMP redirects
51+
- `hsrp_use_bia` (Boolean) Use burned-in address
52+
53+
### Read-Only
54+
55+
- `id` (String) The path of the object.
56+
57+
## Import
58+
59+
Import is supported using the following syntax:
60+
61+
```shell
62+
terraform import iosxr_router_hsrp_interface.example "Cisco-IOS-XR-um-router-hsrp-cfg:/router/hsrp/interfaces/interface[interface-name=GigabitEthernet0/0/0/1]"
63+
```

0 commit comments

Comments
 (0)