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.
- Loading branch information
Showing
7 changed files
with
187 additions
and
4 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,68 @@ | ||
--- | ||
# generated by https://github.com/hashicorp/terraform-plugin-docs | ||
page_title: "meshstack_project_user_binding Data Source - terraform-provider-meshstack" | ||
subcategory: "" | ||
description: |- | ||
Single project user binding by name. | ||
--- | ||
|
||
# meshstack_project_user_binding (Data Source) | ||
|
||
Single project user binding by name. | ||
|
||
## Example Usage | ||
|
||
```terraform | ||
data "meshstack_project_user_binding" "example" { | ||
metadata = { | ||
name = "214cb14d-2e21-11ef-8e80-0242ac130003" | ||
} | ||
} | ||
``` | ||
|
||
<!-- schema generated by tfplugindocs --> | ||
## Schema | ||
|
||
### Required | ||
|
||
- `metadata` (Attributes) Project role assigned by this binding. (see [below for nested schema](#nestedatt--metadata)) | ||
|
||
### Read-Only | ||
|
||
- `api_version` (String) Project user binding datatype version | ||
- `kind` (String) meshObject type, always `meshProjectUserBinding`. | ||
- `role_ref` (Attributes) Project role assigned by this binding. (see [below for nested schema](#nestedatt--role_ref)) | ||
- `subject` (Attributes) Users assigned by this binding. (see [below for nested schema](#nestedatt--subject)) | ||
- `target_ref` (Attributes) Project, identified by workspace and project identifier. (see [below for nested schema](#nestedatt--target_ref)) | ||
|
||
<a id="nestedatt--metadata"></a> | ||
### Nested Schema for `metadata` | ||
|
||
Required: | ||
|
||
- `name` (String) | ||
|
||
|
||
<a id="nestedatt--role_ref"></a> | ||
### Nested Schema for `role_ref` | ||
|
||
Read-Only: | ||
|
||
- `name` (String) | ||
|
||
|
||
<a id="nestedatt--subject"></a> | ||
### Nested Schema for `subject` | ||
|
||
Read-Only: | ||
|
||
- `name` (String) Username. | ||
|
||
|
||
<a id="nestedatt--target_ref"></a> | ||
### Nested Schema for `target_ref` | ||
|
||
Read-Only: | ||
|
||
- `name` (String) | ||
- `owned_by_workspace` (String) |
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,90 @@ | ||
--- | ||
# generated by https://github.com/hashicorp/terraform-plugin-docs | ||
page_title: "meshstack_project_user_binding Resource - terraform-provider-meshstack" | ||
subcategory: "" | ||
description: |- | ||
Project user binding assigns a user with a specific role to a project. | ||
--- | ||
|
||
# meshstack_project_user_binding (Resource) | ||
|
||
Project user binding assigns a user with a specific role to a project. | ||
|
||
## Example Usage | ||
|
||
```terraform | ||
resource "meshstack_project_user_binding" "example" { | ||
metadata = { | ||
name = "this-is-an-example" | ||
} | ||
role_ref = { | ||
name = "Project Reader" | ||
} | ||
target_ref = { | ||
owned_by_workspace = "my-customer" | ||
name = "my-project" | ||
} | ||
subject = { | ||
name = "user@meshcloud.io" | ||
} | ||
} | ||
``` | ||
|
||
<!-- schema generated by tfplugindocs --> | ||
## Schema | ||
|
||
### Required | ||
|
||
- `metadata` (Attributes) Project user binding metadata. (see [below for nested schema](#nestedatt--metadata)) | ||
- `role_ref` (Attributes) Selects the role to use for this project binding. (see [below for nested schema](#nestedatt--role_ref)) | ||
- `subject` (Attributes) Selects the user for this binding. (see [below for nested schema](#nestedatt--subject)) | ||
- `target_ref` (Attributes) Selects the project to which this binding applies. (see [below for nested schema](#nestedatt--target_ref)) | ||
|
||
### Read-Only | ||
|
||
- `api_version` (String) Project user binding datatype version | ||
- `kind` (String) meshObject type, always `meshProjectUserBinding`. | ||
|
||
<a id="nestedatt--metadata"></a> | ||
### Nested Schema for `metadata` | ||
|
||
Required: | ||
|
||
- `name` (String) The name identifies the binding and must be unique across the meshStack. | ||
|
||
|
||
<a id="nestedatt--role_ref"></a> | ||
### Nested Schema for `role_ref` | ||
|
||
Required: | ||
|
||
- `name` (String) | ||
|
||
|
||
<a id="nestedatt--subject"></a> | ||
### Nested Schema for `subject` | ||
|
||
Required: | ||
|
||
- `name` (String) Username. | ||
|
||
|
||
<a id="nestedatt--target_ref"></a> | ||
### Nested Schema for `target_ref` | ||
|
||
Required: | ||
|
||
- `name` (String) Project identifier. | ||
- `owned_by_workspace` (String) Identifier of workspace containing the target project. | ||
|
||
## Import | ||
|
||
Import is supported using the following syntax: | ||
|
||
```shell | ||
# import via project binding name | ||
terraform import 'meshstack_project_user_binding.example' 'my-binding-name' | ||
``` |
5 changes: 5 additions & 0 deletions
5
examples/data-sources/meshstack_project_user_binding/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,5 @@ | ||
data "meshstack_project_user_binding" "example" { | ||
metadata = { | ||
name = "214cb14d-2e21-11ef-8e80-0242ac130003" | ||
} | ||
} |
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,2 @@ | ||
# import via project binding name | ||
terraform import 'meshstack_project_user_binding.example' 'my-binding-name' |
18 changes: 18 additions & 0 deletions
18
examples/resources/meshstack_project_user_binding/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,18 @@ | ||
resource "meshstack_project_user_binding" "example" { | ||
metadata = { | ||
name = "this-is-an-example" | ||
} | ||
|
||
role_ref = { | ||
name = "Project Reader" | ||
} | ||
|
||
target_ref = { | ||
owned_by_workspace = "my-customer" | ||
name = "my-project" | ||
} | ||
|
||
subject = { | ||
name = "user@meshcloud.io" | ||
} | ||
} |
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