generated from hashicorp/terraform-provider-scaffolding-framework
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: meshstack_tag_definition resource
- Loading branch information
Showing
8 changed files
with
767 additions
and
2 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
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
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,154 @@ | ||
--- | ||
# generated by https://github.com/hashicorp/terraform-plugin-docs | ||
page_title: "meshstack_tag_definition Resource - terraform-provider-meshstack" | ||
subcategory: "" | ||
description: |- | ||
Manage tag definitions | ||
--- | ||
|
||
# meshstack_tag_definition (Resource) | ||
|
||
Manage tag definitions | ||
|
||
## Example Usage | ||
|
||
```terraform | ||
resource "meshstack_tag_definition" "example" { | ||
metadata = { | ||
name = "meshProject.example-key" | ||
} | ||
spec = { | ||
target_kind = "meshProject" | ||
key = "example-key" | ||
display_name = "Example" | ||
value_type = { | ||
email = { | ||
default_value = "default" | ||
validation_regex = ".*" | ||
} | ||
} | ||
description = "Example Description" | ||
sort_order = 0 | ||
mandatory = false | ||
immutable = false | ||
restricted = false | ||
} | ||
} | ||
``` | ||
|
||
<!-- schema generated by tfplugindocs --> | ||
## Schema | ||
|
||
### Required | ||
|
||
- `metadata` (Attributes) Tag definition metadata. Name of the target tag definition must be set here. (see [below for nested schema](#nestedatt--metadata)) | ||
- `spec` (Attributes) Tag definition specification. (see [below for nested schema](#nestedatt--spec)) | ||
|
||
### Read-Only | ||
|
||
- `api_version` (String) Tag definition datatype version | ||
- `kind` (String) meshObject type, always `meshTagDefinition`. | ||
|
||
<a id="nestedatt--metadata"></a> | ||
### Nested Schema for `metadata` | ||
|
||
Required: | ||
|
||
- `name` (String) | ||
|
||
|
||
<a id="nestedatt--spec"></a> | ||
### Nested Schema for `spec` | ||
|
||
Required: | ||
|
||
- `display_name` (String) | ||
- `key` (String) | ||
- `target_kind` (String) | ||
- `value_type` (Attributes) (see [below for nested schema](#nestedatt--spec--value_type)) | ||
|
||
Optional: | ||
|
||
- `description` (String) | ||
- `immutable` (Boolean) | ||
- `mandatory` (Boolean) | ||
- `restricted` (Boolean) | ||
- `sort_order` (Number) | ||
|
||
<a id="nestedatt--spec--value_type"></a> | ||
### Nested Schema for `spec.value_type` | ||
|
||
Optional: | ||
|
||
- `email` (Attributes) (see [below for nested schema](#nestedatt--spec--value_type--email)) | ||
- `integer` (Attributes) (see [below for nested schema](#nestedatt--spec--value_type--integer)) | ||
- `multi_select` (Attributes) (see [below for nested schema](#nestedatt--spec--value_type--multi_select)) | ||
- `number` (Attributes) (see [below for nested schema](#nestedatt--spec--value_type--number)) | ||
- `single_select` (Attributes) (see [below for nested schema](#nestedatt--spec--value_type--single_select)) | ||
- `string` (Attributes) (see [below for nested schema](#nestedatt--spec--value_type--string)) | ||
|
||
<a id="nestedatt--spec--value_type--email"></a> | ||
### Nested Schema for `spec.value_type.email` | ||
|
||
Optional: | ||
|
||
- `default_value` (String) | ||
- `validation_regex` (String) | ||
|
||
|
||
<a id="nestedatt--spec--value_type--integer"></a> | ||
### Nested Schema for `spec.value_type.integer` | ||
|
||
Optional: | ||
|
||
- `default_value` (Number) | ||
|
||
|
||
<a id="nestedatt--spec--value_type--multi_select"></a> | ||
### Nested Schema for `spec.value_type.multi_select` | ||
|
||
Optional: | ||
|
||
- `default_value` (List of String) | ||
- `options` (List of String) | ||
|
||
|
||
<a id="nestedatt--spec--value_type--number"></a> | ||
### Nested Schema for `spec.value_type.number` | ||
|
||
Optional: | ||
|
||
- `default_value` (Number) | ||
|
||
|
||
<a id="nestedatt--spec--value_type--single_select"></a> | ||
### Nested Schema for `spec.value_type.single_select` | ||
|
||
Optional: | ||
|
||
- `default_value` (String) | ||
- `options` (List of String) | ||
|
||
|
||
<a id="nestedatt--spec--value_type--string"></a> | ||
### Nested Schema for `spec.value_type.string` | ||
|
||
Optional: | ||
|
||
- `default_value` (String) | ||
- `validation_regex` (String) | ||
|
||
## Import | ||
|
||
Import is supported using the following syntax: | ||
|
||
```shell | ||
# import via tag definition name | ||
terraform import 'meshstack_tag_definition.example' 'target_kind.key' | ||
|
||
# import the example tag definition | ||
terraform import 'meshstack_tag_definition.example' 'meshProject.example-key' | ||
``` |
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,5 @@ | ||
# import via tag definition name | ||
terraform import 'meshstack_tag_definition.example' 'target_kind.key' | ||
|
||
# import the example tag definition | ||
terraform import 'meshstack_tag_definition.example' 'meshProject.example-key' |
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,24 @@ | ||
resource "meshstack_tag_definition" "example" { | ||
metadata = { | ||
name = "meshProject.example-key" | ||
} | ||
|
||
spec = { | ||
target_kind = "meshProject" | ||
key = "example-key" | ||
|
||
display_name = "Example" | ||
|
||
value_type = { | ||
email = { | ||
default_value = "default" | ||
validation_regex = ".*" | ||
} | ||
} | ||
description = "Example Description" | ||
sort_order = 0 | ||
mandatory = false | ||
immutable = false | ||
restricted = false | ||
} | ||
} |
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
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
Oops, something went wrong.