Skip to content

Commit db9dafe

Browse files
committed
Enable data source name query option of ip to sgt mapping resource
1 parent ab9bc1b commit db9dafe

10 files changed

+88
-32
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
## 0.1.4 (unreleased)
2+
3+
- Add `ise_trustsec_ip_to_sgt_mapping` resource and data source
4+
- Add `ise_trustsec_ip_to_sgt_mapping_group` resource and data source
5+
16
## 0.1.3
27

38
- Add support for nested conditions to `ise_network_access_authentication_rule` resource and data source

docs/data-sources/trustsec_ip_to_sgt_mapping.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -21,17 +21,17 @@ data "ise_trustsec_ip_to_sgt_mapping" "example" {
2121
<!-- schema generated by tfplugindocs -->
2222
## Schema
2323

24-
### Required
24+
### Optional
2525

2626
- `id` (String) The id of the object
27+
- `name` (String) The name of the IP to SGT mapping
2728

2829
### Read-Only
2930

30-
- `deploy_to` (String) Mandatory unless mappingGroup is set or unless `deployType=ALL`
31+
- `deploy_to` (String) Mandatory unless `mapping_group` is set or unless `deploy_type` is `ALL`
3132
- `deploy_type` (String) Deploy Type
3233
- `description` (String) Description
33-
- `host_ip` (String) Mandatory if hostName is empty -- valid IP
34-
- `host_name` (String) Mandatory if hostIp is empty
35-
- `mapping_group` (String) IP to SGT Mapping Group ID. Mandatory unless sgt and deployTo and deployType are set
36-
- `name` (String) The name of the IP to SGT mapping
37-
- `sgt` (String) Trustsec Security Group ID. Mandatory unless mappingGroup is set
34+
- `host_ip` (String) Mandatory if `host_name` is empty
35+
- `host_name` (String) Mandatory if `host_ip` is empty
36+
- `mapping_group` (String) IP to SGT Mapping Group ID. Mandatory unless `sgt` and `deploy_to` and `deploy_type` are set
37+
- `sgt` (String) Trustsec Security Group ID. Mandatory unless `mapping_group` is set

docs/guides/changelog.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,11 @@ description: |-
77

88
# Changelog
99

10+
## 0.1.4 (unreleased)
11+
12+
- Add `ise_trustsec_ip_to_sgt_mapping` resource and data source
13+
- Add `ise_trustsec_ip_to_sgt_mapping_group` resource and data source
14+
1015
## 0.1.3
1116

1217
- Add support for nested conditions to `ise_network_access_authentication_rule` resource and data source

docs/resources/trustsec_ip_to_sgt_mapping.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,14 +30,14 @@ resource "ise_trustsec_ip_to_sgt_mapping" "example" {
3030

3131
### Optional
3232

33-
- `deploy_to` (String) Mandatory unless mappingGroup is set or unless `deployType=ALL`
33+
- `deploy_to` (String) Mandatory unless `mapping_group` is set or unless `deploy_type` is `ALL`
3434
- `deploy_type` (String) Deploy Type
3535
- Choices: `ALL`, `ND`, `NDG`
3636
- `description` (String) Description
37-
- `host_ip` (String) Mandatory if hostName is empty -- valid IP
38-
- `host_name` (String) Mandatory if hostIp is empty
39-
- `mapping_group` (String) IP to SGT Mapping Group ID. Mandatory unless sgt and deployTo and deployType are set
40-
- `sgt` (String) Trustsec Security Group ID. Mandatory unless mappingGroup is set
37+
- `host_ip` (String) Mandatory if `host_name` is empty
38+
- `host_name` (String) Mandatory if `host_ip` is empty
39+
- `mapping_group` (String) IP to SGT Mapping Group ID. Mandatory unless `sgt` and `deploy_to` and `deploy_type` are set
40+
- `sgt` (String) Trustsec Security Group ID. Mandatory unless `mapping_group` is set
4141

4242
### Read-Only
4343

gen/definitions/trustsec_ip_to_sgt_mapping.yaml

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
name: TrustSec IP to SGT Mapping
33
rest_endpoint: /ers/config/sgmapping
44
doc_category: TrustSec
5+
data_source_name_query: true
56
id_path: response.id
67
attributes:
78
- model_name: name
@@ -18,7 +19,7 @@ attributes:
1819
- model_name: deployTo
1920
data_path: [SGMapping]
2021
type: String
21-
description: "Mandatory unless mappingGroup is set or unless `deployType=ALL`"
22+
description: "Mandatory unless `mapping_group` is set or unless `deploy_type` is `ALL`"
2223
exclude_test: true
2324
example: "All Locations"
2425
- model_name: deployType
@@ -31,26 +32,27 @@ attributes:
3132
- model_name: hostName
3233
data_path: [SGMapping]
3334
type: String
34-
description: Mandatory if hostIp is empty
35+
description: Mandatory if `host_ip` is empty
3536
example: "server1.cisco.com"
3637
exclude_test: true
3738
- model_name: hostIp
3839
data_path: [SGMapping]
3940
type: String
40-
description: Mandatory if hostName is empty -- valid IP
41+
description: Mandatory if `host_name` is empty
4142
example: "10.0.0.1/32"
4243
minimum_test_value: '"10.0.0.1/32"'
4344
- model_name: sgt
4445
data_path: [SGMapping]
4546
type: String
4647
example: "93e1bf00-8c01-11e6-996c-525400b48521"
48+
test_value: ise_trustsec_security_group.test.id
4749
minimum_test_value: ise_trustsec_security_group.test.id
48-
description: Trustsec Security Group ID. Mandatory unless mappingGroup is set
50+
description: Trustsec Security Group ID. Mandatory unless `mapping_group` is set
4951
- model_name: mappingGroup
5052
data_path: [SGMapping]
5153
type: String
5254
example: "48fc1ac2-d500-493d-99ad-8d8fab0ef11f"
53-
description: IP to SGT Mapping Group ID. Mandatory unless sgt and deployTo and deployType are set
55+
description: IP to SGT Mapping Group ID. Mandatory unless `sgt` and `deploy_to` and `deploy_type` are set
5456
exclude_test: true
5557

5658
test_prerequisites: |

internal/provider/data_source_ise_trustsec_ip_to_sgt_mapping.go

Lines changed: 47 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

internal/provider/data_source_ise_trustsec_ip_to_sgt_mapping_test.go

Lines changed: 1 addition & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

internal/provider/resource_ise_trustsec_ip_to_sgt_mapping.go

Lines changed: 5 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

internal/provider/resource_ise_trustsec_ip_to_sgt_mapping_test.go

Lines changed: 1 addition & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

templates/guides/changelog.md.tmpl

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,11 @@ description: |-
77

88
# Changelog
99

10+
## 0.1.4 (unreleased)
11+
12+
- Add `ise_trustsec_ip_to_sgt_mapping` resource and data source
13+
- Add `ise_trustsec_ip_to_sgt_mapping_group` resource and data source
14+
1015
## 0.1.3
1116

1217
- Add support for nested conditions to `ise_network_access_authentication_rule` resource and data source

0 commit comments

Comments
 (0)