-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add lan automation resource and data source (#38)
- Loading branch information
1 parent
b0152a8
commit 2801283
Showing
12 changed files
with
1,175 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
--- | ||
# generated by https://github.com/hashicorp/terraform-plugin-docs | ||
page_title: "catalystcenter_lan_automation Data Source - terraform-provider-catalystcenter" | ||
subcategory: "LAN Automation" | ||
description: |- | ||
This data source can read the LAN Automation. | ||
--- | ||
|
||
# catalystcenter_lan_automation (Data Source) | ||
|
||
This data source can read the LAN Automation. | ||
|
||
## Example Usage | ||
|
||
```terraform | ||
data "catalystcenter_lan_automation" "example" { | ||
id = "76d24097-41c4-4558-a4d0-a8c07ac08470" | ||
} | ||
``` | ||
|
||
<!-- schema generated by tfplugindocs --> | ||
## Schema | ||
|
||
### Required | ||
|
||
- `id` (String) The id of the object | ||
|
||
### Read-Only | ||
|
||
- `discovered_device_site_name_hierarchy` (String) Discovered device site name. | ||
- `host_name_file_id` (String) File ID of the CSV file containing the host name list. | ||
- `host_name_prefix` (String) Host name prefix which shall be assigned to the discovered device. | ||
- `ip_pools` (Attributes List) The list of IP pools with its name and role. (see [below for nested schema](#nestedatt--ip_pools)) | ||
- `isis_domain_password` (String) ISIS domain password. | ||
- `multicast_enabled` (Boolean) To enable underlay native multicast. | ||
- `peer_device_management_ip_address` (String) The list of interfaces on primary seed via which the discovered devices are connected. | ||
- `primary_device_interface_names` (List of String) The list of interfaces on primary seed via which the discovered devices are connected. | ||
- `primary_device_management_ip_address` (String) Primary seed management IP address. | ||
- `redistribute_isis_to_bgp` (Boolean) Advertise LAN Automation summary route into BGP. | ||
|
||
<a id="nestedatt--ip_pools"></a> | ||
### Nested Schema for `ip_pools` | ||
|
||
Read-Only: | ||
|
||
- `ip_pool_name` (String) Name of the IP pool. | ||
- `ip_pool_role` (String) Role of the IP pool. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
--- | ||
# generated by https://github.com/hashicorp/terraform-plugin-docs | ||
page_title: "catalystcenter_lan_automation Resource - terraform-provider-catalystcenter" | ||
subcategory: "LAN Automation" | ||
description: |- | ||
This resource can Start LAN Automation on resource creation and Stop LAN Automation on resource deletion | ||
--- | ||
|
||
# catalystcenter_lan_automation (Resource) | ||
|
||
This resource can Start LAN Automation on resource creation and Stop LAN Automation on resource deletion | ||
|
||
## Example Usage | ||
|
||
```terraform | ||
resource "catalystcenter_lan_automation" "example" { | ||
discovered_device_site_name_hierarchy = "Global/Area1/Area2" | ||
primary_device_management_ip_address = "1.2.3.4" | ||
peer_device_management_ip_address = "1.2.3.5" | ||
primary_device_interface_names = ["HundredGigE1/0/1"] | ||
ip_pools = [ | ||
{ | ||
ip_pool_name = "POOL1" | ||
ip_pool_role = "MAIN_POOL" | ||
} | ||
] | ||
multicast_enabled = true | ||
host_name_prefix = "TEST" | ||
host_name_file_id = "1234" | ||
isis_domain_password = "cisco123" | ||
redistribute_isis_to_bgp = true | ||
} | ||
``` | ||
|
||
<!-- schema generated by tfplugindocs --> | ||
## Schema | ||
|
||
### Required | ||
|
||
- `discovered_device_site_name_hierarchy` (String) Discovered device site name. | ||
- `primary_device_interface_names` (List of String) The list of interfaces on primary seed via which the discovered devices are connected. | ||
- `primary_device_management_ip_address` (String) Primary seed management IP address. | ||
|
||
### Optional | ||
|
||
- `host_name_file_id` (String) File ID of the CSV file containing the host name list. | ||
- `host_name_prefix` (String) Host name prefix which shall be assigned to the discovered device. | ||
- `ip_pools` (Attributes List) The list of IP pools with its name and role. (see [below for nested schema](#nestedatt--ip_pools)) | ||
- `isis_domain_password` (String) ISIS domain password. | ||
- `multicast_enabled` (Boolean) To enable underlay native multicast. | ||
- `peer_device_management_ip_address` (String) The list of interfaces on primary seed via which the discovered devices are connected. | ||
- `redistribute_isis_to_bgp` (Boolean) Advertise LAN Automation summary route into BGP. | ||
|
||
### Read-Only | ||
|
||
- `id` (String) The id of the object | ||
|
||
<a id="nestedatt--ip_pools"></a> | ||
### Nested Schema for `ip_pools` | ||
|
||
Required: | ||
|
||
- `ip_pool_name` (String) Name of the IP pool. | ||
- `ip_pool_role` (String) Role of the IP pool. | ||
- Choices: `MAIN_POOL`, `PHYSICAL_LINK_POOL` | ||
|
||
## Import | ||
|
||
Import is supported using the following syntax: | ||
|
||
```shell | ||
terraform import catalystcenter_lan_automation.example "4b0b7a80-44c0-4bf2-bab5-fc24b4e0a17e" | ||
``` |
3 changes: 3 additions & 0 deletions
3
examples/data-sources/catalystcenter_lan_automation/data-source.tf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
data "catalystcenter_lan_automation" "example" { | ||
id = "76d24097-41c4-4558-a4d0-a8c07ac08470" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
terraform import catalystcenter_lan_automation.example "4b0b7a80-44c0-4bf2-bab5-fc24b4e0a17e" |
17 changes: 17 additions & 0 deletions
17
examples/resources/catalystcenter_lan_automation/resource.tf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
resource "catalystcenter_lan_automation" "example" { | ||
discovered_device_site_name_hierarchy = "Global/Area1/Area2" | ||
primary_device_management_ip_address = "1.2.3.4" | ||
peer_device_management_ip_address = "1.2.3.5" | ||
primary_device_interface_names = ["HundredGigE1/0/1"] | ||
ip_pools = [ | ||
{ | ||
ip_pool_name = "POOL1" | ||
ip_pool_role = "MAIN_POOL" | ||
} | ||
] | ||
multicast_enabled = true | ||
host_name_prefix = "TEST" | ||
host_name_file_id = "1234" | ||
isis_domain_password = "cisco123" | ||
redistribute_isis_to_bgp = true | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,91 @@ | ||
--- | ||
name: LAN Automation | ||
rest_endpoint: /dna/intent/api/v1/lan-automation | ||
get_rest_endpoint: /dna/intent/api/v1/lan-automation/status | ||
no_update: true | ||
id_path: response.id | ||
doc_category: LAN Automation | ||
res_description: | ||
'This resource can Start LAN Automation on resource creation and Stop LAN Automation on resource deletion' | ||
test_tags: [LANAUTO] | ||
attributes: | ||
- model_name: discoveredDeviceSiteNameHierarchy | ||
data_path: "0" | ||
response_data_path: response.0.discoveredDeviceSiteNameHierarchy | ||
type: String | ||
mandatory: true | ||
description: Discovered device site name. | ||
example: Global/Area1/Area2 | ||
- model_name: primaryDeviceManagmentIPAddress | ||
data_path: "0" | ||
response_data_path: response.0.primaryDeviceManagmentIPAddress | ||
tf_name: primary_device_management_ip_address | ||
type: String | ||
mandatory: true | ||
description: Primary seed management IP address. | ||
example: 1.2.3.4 | ||
- model_name: peerDeviceManagmentIPAddress | ||
data_path: "0" | ||
response_data_path: response.0.peerDeviceManagmentIPAddress | ||
tf_name: peer_device_management_ip_address | ||
type: String | ||
description: Secondary seed management IP address. | ||
example: 1.2.3.5 | ||
- model_name: primaryDeviceInterfaceNames | ||
data_path: "0" | ||
response_data_path: response.0.primaryDeviceInterfaceNames | ||
type: StringList | ||
mandatory: true | ||
description: The list of interfaces on primary seed via which the discovered devices are connected. | ||
example: HundredGigE1/0/1 | ||
- model_name: ipPools | ||
data_path: "0" | ||
response_data_path: response.0.ipPools | ||
type: List | ||
description: The list of IP pools with its name and role. | ||
attributes: | ||
- model_name: ipPoolName | ||
type: String | ||
mandatory: true | ||
id: true | ||
description: Name of the IP pool. | ||
example: POOL1 | ||
- model_name: ipPoolRole | ||
type: String | ||
enum_values: [MAIN_POOL, PHYSICAL_LINK_POOL] | ||
mandatory: true | ||
id: true | ||
description: Role of the IP pool. | ||
example: MAIN_POOL | ||
- model_name: multicastEnabled | ||
data_path: "0" | ||
response_data_path: response.0.multicatEnabled | ||
type: Bool | ||
description: To enable underlay native multicast. | ||
example: true | ||
- model_name: hostNamePrefix | ||
data_path: "0" | ||
response_data_path: response.0.hostNamePrefix | ||
type: String | ||
description: Host name prefix which shall be assigned to the discovered device. | ||
example: TEST | ||
- model_name: hostNameFileId | ||
data_path: "0" | ||
response_data_path: response.0.hostNameFileId | ||
type: String | ||
description: File ID of the CSV file containing the host name list. | ||
exclude_test: true | ||
example: 1234 | ||
- model_name: isisDomainPwd | ||
data_path: "0" | ||
response_data_path: response.0.isisDomainPwd | ||
tf_name: isis_domain_password | ||
type: String | ||
description: ISIS domain password. | ||
example: cisco123 | ||
- model_name: redistributeIsisToBgp | ||
data_path: "0" | ||
response_data_path: response.0.redistributeIsisToBgp | ||
type: Bool | ||
description: Advertise LAN Automation summary route into BGP. | ||
example: true |
Oops, something went wrong.