Skip to content

Commit

Permalink
[minor_change] Add aci_l3out_provider_label resource and data-source …
Browse files Browse the repository at this point in the history
…and updated templates to accept parent_dependency_name from properties.yaml (#1200)
  • Loading branch information
sajagana authored Apr 23, 2024
1 parent 3589526 commit d70a0cf
Show file tree
Hide file tree
Showing 24 changed files with 2,978 additions and 17 deletions.
1 change: 1 addition & 0 deletions docs/data-sources/annotation.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ data "aci_annotation" "example_application_epg" {
- [aci_tenant](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/tenant) ([fvTenant](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/fvTenant/overview))
- [aci_l3out_consumer_label](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/l3out_consumer_label) ([l3extConsLbl](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extConsLbl/overview))
- [aci_l3_outside](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/l3_outside) ([l3extOut](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extOut/overview))
- [aci_l3out_provider_label](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/l3out_provider_label) ([l3extProvLbl](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extProvLbl/overview))
- [aci_relation_to_fallback_route_group](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/relation_to_fallback_route_group) ([l3extRsOutToFBRGroup](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extRsOutToFBRGroup/overview))
- [aci_l3out_redistribute_policy](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/l3out_redistribute_policy) ([l3extRsRedistributePol](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extRsRedistributePol/overview))
- [aci_external_management_network_instance_profile](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/external_management_network_instance_profile) ([mgmtInstP](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/mgmtInstP/overview))
Expand Down
64 changes: 64 additions & 0 deletions docs/data-sources/l3out_provider_label.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
---
# Documentation generated by "gen/generator.go"; DO NOT EDIT.
# In order to regenerate this file execute `go generate` from the repository root.
# More details can be found in the [README](https://github.com/CiscoDevNet/terraform-provider-aci/blob/master/README.md).
subcategory: "L3Out"
layout: "aci"
page_title: "ACI: aci_l3out_provider_label"
sidebar_current: "docs-aci-data-source-aci_l3out_provider_label"
description: |-
Data source for L3out Provider Label
---

# aci_l3out_provider_label #

Data source for L3out Provider Label

## API Information ##

* Class: [l3extProvLbl](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extProvLbl/overview)

* Supported in ACI versions: 2.0(1m) and later.

* Distinguished Name Format: `uni/tn-{name}/out-{name}/provlbl-{name}`

## GUI Information ##

* Location: `Tenants (infra) -> Networking -> L3Outs -> Policy -> Main -> Provider Label`

## Example Usage ##

```hcl
data "aci_l3out_provider_label" "example_l3_outside" {
parent_dn = aci_l3_outside.example.id
name = "prov_label"
}
```

## Schema ##

### Required ###

* `parent_dn` - (string) The distinguished name (DN) of the parent object, possible resources:
- [aci_l3_outside](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/l3_outside) ([l3extOut](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extOut/overview))
* `name` (name) - (string) The name of the L3out Provider Label object.

### Read-Only ###

* `id` - (string) The distinguished name (DN) of the L3out Provider Label object.
* `annotation` (annotation) - (string) The annotation of the L3out Provider Label object.
* `description` (descr) - (string) The description of the L3out Provider Label object.
* `name_alias` (nameAlias) - (string) The name alias of the L3out Provider Label object.
* `owner_key` (ownerKey) - (string) The key for enabling clients to own their data for entity correlation.
* `owner_tag` (ownerTag) - (string) A tag for enabling clients to add their own data. For example, to indicate who created this object.
* `tag` (tag) - (string) Specifies the color of a policy label.

* `annotations` - (list) A list of Annotations (ACI object [tagAnnotation](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/tagAnnotation/overview)). This attribute is supported in ACI versions: 3.2(1l) and later.
* `key` (key) - (string) The key used to uniquely identify this configuration object.
* `value` (value) - (string) The value of the property.

* `tags` - (list) A list of Tags (ACI object [tagTag](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/tagTag/overview)). This attribute is supported in ACI versions: 3.2(1l) and later.
* `key` (key) - (string) The key used to uniquely identify this configuration object.
* `value` (value) - (string) The value of the property.
1 change: 1 addition & 0 deletions docs/data-sources/tag.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ data "aci_tag" "example_application_epg" {
- [aci_tenant](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/tenant) ([fvTenant](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/fvTenant/overview))
- [aci_l3out_consumer_label](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/l3out_consumer_label) ([l3extConsLbl](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extConsLbl/overview))
- [aci_l3_outside](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/l3_outside) ([l3extOut](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extOut/overview))
- [aci_l3out_provider_label](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/l3out_provider_label) ([l3extProvLbl](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extProvLbl/overview))
- [aci_relation_to_fallback_route_group](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/relation_to_fallback_route_group) ([l3extRsOutToFBRGroup](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extRsOutToFBRGroup/overview))
- [aci_l3out_redistribute_policy](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/l3out_redistribute_policy) ([l3extRsRedistributePol](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extRsRedistributePol/overview))
- [aci_external_management_network_instance_profile](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/external_management_network_instance_profile) ([mgmtInstP](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/mgmtInstP/overview))
Expand Down
1 change: 1 addition & 0 deletions docs/resources/annotation.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ All examples for the Annotation resource can be found in the [examples](https://
- [aci_tenant](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/tenant) ([fvTenant](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/fvTenant/overview))
- [aci_l3out_consumer_label](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/l3out_consumer_label) ([l3extConsLbl](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extConsLbl/overview))
- [aci_l3_outside](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/l3_outside) ([l3extOut](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extOut/overview))
- [aci_l3out_provider_label](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/l3out_provider_label) ([l3extProvLbl](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extProvLbl/overview))
- [aci_relation_to_fallback_route_group](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/relation_to_fallback_route_group) ([l3extRsOutToFBRGroup](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extRsOutToFBRGroup/overview))
- [aci_l3out_redistribute_policy](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/l3out_redistribute_policy) ([l3extRsRedistributePol](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extRsRedistributePol/overview))
- [aci_external_management_network_instance_profile](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/external_management_network_instance_profile) ([mgmtInstP](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/mgmtInstP/overview))
Expand Down
129 changes: 129 additions & 0 deletions docs/resources/l3out_provider_label.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,129 @@
---
# Documentation generated by "gen/generator.go"; DO NOT EDIT.
# In order to regenerate this file execute `go generate` from the repository root.
# More details can be found in the [README](https://github.com/CiscoDevNet/terraform-provider-aci/blob/master/README.md).
subcategory: "L3Out"
layout: "aci"
page_title: "ACI: aci_l3out_provider_label"
sidebar_current: "docs-aci-resource-aci_l3out_provider_label"
description: |-
Manages ACI L3out Provider Label
---

# aci_l3out_provider_label #

Manages ACI L3out Provider Label



## API Information ##

* Class: [l3extProvLbl](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extProvLbl/overview)

* Supported in ACI versions: 2.0(1m) and later.

* Distinguished Name Format: `uni/tn-{name}/out-{name}/provlbl-{name}`

## GUI Information ##

* Location: `Tenants (infra) -> Networking -> L3Outs -> Policy -> Main -> Provider Label`

## Example Usage ##

The configuration snippet below creates a L3out Provider Label with only required attributes.

```hcl
resource "aci_l3out_provider_label" "example_l3_outside" {
parent_dn = aci_l3_outside.example.id
name = "prov_label"
}
```
The configuration snippet below shows all possible attributes of the L3out Provider Label.

!> This example might not be valid configuration and is only used to show all possible attributes.

```hcl
resource "aci_l3out_provider_label" "full_example_l3_outside" {
parent_dn = aci_l3_outside.example.id
annotation = "annotation"
description = "description"
name = "prov_label"
name_alias = "name_alias"
owner_key = "owner_key"
owner_tag = "owner_tag"
tag = "alice-blue"
annotations = [
{
key = "key_0"
value = "value_1"
}
]
tags = [
{
key = "key_0"
value = "value_1"
}
]
}
```

All examples for the L3out Provider Label resource can be found in the [examples](https://github.com/CiscoDevNet/terraform-provider-aci/tree/master/examples/resources/aci_l3out_provider_label) folder.

## Schema ##

### Required ###

* `parent_dn` - (string) The distinguished name (DN) of the parent object, possible resources:
- [aci_l3_outside](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/l3_outside) ([l3extOut](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extOut/overview))
* `name` (name) - (string) The name of the L3out Provider Label object.

### Read-Only ###

* `id` - (string) The distinguished name (DN) of the L3out Provider Label object.

### Optional ###

* `annotation` (annotation) - (string) The annotation of the L3out Provider Label object.
- Default: `orchestrator:terraform`
* `description` (descr) - (string) The description of the L3out Provider Label object.
* `name_alias` (nameAlias) - (string) The name alias of the L3out Provider Label object.
* `owner_key` (ownerKey) - (string) The key for enabling clients to own their data for entity correlation.
* `owner_tag` (ownerTag) - (string) A tag for enabling clients to add their own data. For example, to indicate who created this object.
* `tag` (tag) - (string) Specifies the color of a policy label.
- Valid Values: `alice-blue`, `antique-white`, `aqua`, `aquamarine`, `azure`, `beige`, `bisque`, `black`, `blanched-almond`, `blue`, `blue-violet`, `brown`, `burlywood`, `cadet-blue`, `chartreuse`, `chocolate`, `coral`, `cornflower-blue`, `cornsilk`, `crimson`, `cyan`, `dark-blue`, `dark-cyan`, `dark-goldenrod`, `dark-gray`, `dark-green`, `dark-khaki`, `dark-magenta`, `dark-olive-green`, `dark-orange`, `dark-orchid`, `dark-red`, `dark-salmon`, `dark-sea-green`, `dark-slate-blue`, `dark-slate-gray`, `dark-turquoise`, `dark-violet`, `deep-pink`, `deep-sky-blue`, `dim-gray`, `dodger-blue`, `fire-brick`, `floral-white`, `forest-green`, `fuchsia`, `gainsboro`, `ghost-white`, `gold`, `goldenrod`, `gray`, `green`, `green-yellow`, `honeydew`, `hot-pink`, `indian-red`, `indigo`, `ivory`, `khaki`, `lavender`, `lavender-blush`, `lawn-green`, `lemon-chiffon`, `light-blue`, `light-coral`, `light-cyan`, `light-goldenrod-yellow`, `light-gray`, `light-green`, `light-pink`, `light-salmon`, `light-sea-green`, `light-sky-blue`, `light-slate-gray`, `light-steel-blue`, `light-yellow`, `lime`, `lime-green`, `linen`, `magenta`, `maroon`, `medium-aquamarine`, `medium-blue`, `medium-orchid`, `medium-purple`, `medium-sea-green`, `medium-slate-blue`, `medium-spring-green`, `medium-turquoise`, `medium-violet-red`, `midnight-blue`, `mint-cream`, `misty-rose`, `moccasin`, `navajo-white`, `navy`, `old-lace`, `olive`, `olive-drab`, `orange`, `orange-red`, `orchid`, `pale-goldenrod`, `pale-green`, `pale-turquoise`, `pale-violet-red`, `papaya-whip`, `peachpuff`, `peru`, `pink`, `plum`, `powder-blue`, `purple`, `red`, `rosy-brown`, `royal-blue`, `saddle-brown`, `salmon`, `sandy-brown`, `sea-green`, `seashell`, `sienna`, `silver`, `sky-blue`, `slate-blue`, `slate-gray`, `snow`, `spring-green`, `steel-blue`, `tan`, `teal`, `thistle`, `tomato`, `turquoise`, `violet`, `wheat`, `white`, `white-smoke`, `yellow`, `yellow-green`.

* `annotations` - (list) A list of Annotations (ACI object [tagAnnotation](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/tagAnnotation/overview)). Annotations can also be configured using a separate [aci_annotation](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/annotation) resource. This attribute is supported in ACI versions: 3.2(1l) and later.

#### Required ####

* `key` (key) - (string) The key used to uniquely identify this configuration object.
* `value` (value) - (string) The value of the property.

* `tags` - (list) A list of Tags (ACI object [tagTag](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/tagTag/overview)). Tags can also be configured using a separate [aci_tag](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/tag) resource. This attribute is supported in ACI versions: 3.2(1l) and later.

#### Required ####

* `key` (key) - (string) The key used to uniquely identify this configuration object.
* `value` (value) - (string) The value of the property.

## Importing

An existing L3out Provider Label can be [imported](https://www.terraform.io/docs/import/index.html) into this resource with its distinguished name (DN), via the following command:

```
terraform import aci_l3out_provider_label.example_l3_outside uni/tn-{name}/out-{name}/provlbl-{name}
```

Starting in Terraform version 1.5, an existing L3out Provider Label can be imported
using [import blocks](https://developer.hashicorp.com/terraform/language/import) via the following configuration:

```
import {
id = "uni/tn-{name}/out-{name}/provlbl-{name}"
to = aci_l3out_provider_label.example_l3_outside
}
```
1 change: 1 addition & 0 deletions docs/resources/tag.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ All examples for the Tag resource can be found in the [examples](https://github.
- [aci_tenant](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/tenant) ([fvTenant](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/fvTenant/overview))
- [aci_l3out_consumer_label](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/l3out_consumer_label) ([l3extConsLbl](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extConsLbl/overview))
- [aci_l3_outside](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/l3_outside) ([l3extOut](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extOut/overview))
- [aci_l3out_provider_label](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/l3out_provider_label) ([l3extProvLbl](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extProvLbl/overview))
- [aci_relation_to_fallback_route_group](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/relation_to_fallback_route_group) ([l3extRsOutToFBRGroup](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extRsOutToFBRGroup/overview))
- [aci_l3out_redistribute_policy](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/l3out_redistribute_policy) ([l3extRsRedistributePol](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/l3extRsRedistributePol/overview))
- [aci_external_management_network_instance_profile](https://registry.terraform.io/providers/CiscoDevNet/aci/latest/docs/resources/external_management_network_instance_profile) ([mgmtInstP](https://pubhub.devnetcloud.com/media/model-doc-latest/docs/app/index.html#/objects/mgmtInstP/overview))
Expand Down
5 changes: 5 additions & 0 deletions examples/data-sources/aci_l3out_provider_label/data-source.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@

data "aci_l3out_provider_label" "example_l3_outside" {
parent_dn = aci_l3_outside.example.id
name = "prov_label"
}
14 changes: 14 additions & 0 deletions examples/data-sources/aci_l3out_provider_label/provider.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
terraform {
required_providers {
aci = {
source = "ciscodevnet/aci"
}
}
}

provider "aci" {
username = ""
password = ""
url = ""
insecure = true
}
14 changes: 14 additions & 0 deletions examples/resources/aci_l3out_provider_label/provider.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
terraform {
required_providers {
aci = {
source = "ciscodevnet/aci"
}
}
}

provider "aci" {
username = ""
password = ""
url = ""
insecure = true
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@

resource "aci_l3out_provider_label" "full_example_l3_outside" {
parent_dn = aci_l3_outside.example.id
annotation = "annotation"
description = "description"
name = "prov_label"
name_alias = "name_alias"
owner_key = "owner_key"
owner_tag = "owner_tag"
tag = "alice-blue"
annotations = [
{
key = "key_0"
value = "value_1"
}
]
tags = [
{
key = "key_0"
value = "value_1"
}
]
}
5 changes: 5 additions & 0 deletions examples/resources/aci_l3out_provider_label/resource.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@

resource "aci_l3out_provider_label" "example_l3_outside" {
parent_dn = aci_l3_outside.example.id
name = "prov_label"
}
6 changes: 6 additions & 0 deletions gen/definitions/classes.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -158,3 +158,9 @@ l3extRsOutToFBRGroup:
ui_locations:
- "Tenants -> Networking -> L3Outs -> Policy -> Main -> Fallback Route Group"
sub_category: "L3Out"

l3extProvLbl:
resource_name: "l3out_provider_label"
ui_locations:
- "Tenants (infra) -> Networking -> L3Outs -> Policy -> Main -> Provider Label"
sub_category: "L3Out"
Loading

0 comments on commit d70a0cf

Please sign in to comment.