Skip to content

Commit

Permalink
feat: Add roles resource
Browse files Browse the repository at this point in the history
  • Loading branch information
uanid committed Jan 24, 2024
1 parent c93e814 commit 1c1303a
Show file tree
Hide file tree
Showing 36 changed files with 720 additions and 293 deletions.
20 changes: 4 additions & 16 deletions docs/data-sources/clusterrolebinding.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,27 +64,15 @@ Optional:

Read-Only:

- `policy_inline` (List of Object) (see [below for nested schema](#nestedobjatt--spec--policy_inline))
- `policy_ref` (String)
- `role_ref` (List of Object) (see [below for nested schema](#nestedobjatt--spec--role_ref))
- `subject_ref` (List of Object) (see [below for nested schema](#nestedobjatt--spec--subject_ref))

<a id="nestedobjatt--spec--policy_inline"></a>
### Nested Schema for `spec.policy_inline`
<a id="nestedobjatt--spec--role_ref"></a>
### Nested Schema for `spec.role_ref`

Read-Only:

- `actions` (Set of String)
- `paths` (Set of String)
- `resources` (List of Object) (see [below for nested schema](#nestedobjatt--spec--policy_inline--resources))

<a id="nestedobjatt--spec--policy_inline--resources"></a>
### Nested Schema for `spec.policy_inline.resources`

Read-Only:

- `api_group` (String)
- `kind` (String)

- `name` (String)


<a id="nestedobjatt--spec--subject_ref"></a>
Expand Down
20 changes: 4 additions & 16 deletions docs/data-sources/clusterrolebindings.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,27 +73,15 @@ Read-Only:

Read-Only:

- `policy_inline` (List of Object) (see [below for nested schema](#nestedobjatt--items--spec--policy_inline))
- `policy_ref` (String)
- `role_ref` (List of Object) (see [below for nested schema](#nestedobjatt--items--spec--role_ref))
- `subject_ref` (List of Object) (see [below for nested schema](#nestedobjatt--items--spec--subject_ref))

<a id="nestedobjatt--items--spec--policy_inline"></a>
### Nested Schema for `items.spec.policy_inline`
<a id="nestedobjatt--items--spec--role_ref"></a>
### Nested Schema for `items.spec.role_ref`

Read-Only:

- `actions` (Set of String)
- `paths` (Set of String)
- `resources` (List of Object) (see [below for nested schema](#nestedobjatt--items--spec--policy_inline--resources))

<a id="nestedobjatt--items--spec--policy_inline--resources"></a>
### Nested Schema for `items.spec.policy_inline.resources`

Read-Only:

- `api_group` (String)
- `kind` (String)

- `name` (String)


<a id="nestedobjatt--items--spec--subject_ref"></a>
Expand Down
84 changes: 84 additions & 0 deletions docs/data-sources/role.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
---
# generated by https://github.com/hashicorp/terraform-plugin-docs
page_title: "bluechip_role Data Source - terraform-provider-bluechip"
subcategory: ""
description: |-
---

# bluechip_role (Data Source)



## Example Usage

```terraform
data "bluechip_role" "current" {
metadata {
name = "my-test"
}
}
```

<!-- schema generated by tfplugindocs -->
## Schema

### Optional

- `metadata` (Block List) (see [below for nested schema](#nestedblock--metadata))
- `timeouts` (Block, Optional) (see [below for nested schema](#nestedblock--timeouts))

### Read-Only

- `id` (String) The ID of this resource.
- `spec` (List of Object) (see [below for nested schema](#nestedatt--spec))

<a id="nestedblock--metadata"></a>
### Nested Schema for `metadata`

Required:

- `name` (String) Name is the name of the resource.

Optional:

- `annotations` (Map of String) Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects.
- `labels` (Map of String) Labels are key value pairs that may be used to scope and select individual resources. They are not queryable and should be preserved when modifying objects.

Read-Only:

- `creation_timestamp` (String) CreationTimestamp is a timestamp representing the server time when this object was created.
- `update_timestamp` (String) UpdateTimestamp is a timestamp representing the server time when this object was last updated.


<a id="nestedblock--timeouts"></a>
### Nested Schema for `timeouts`

Optional:

- `default` (String)


<a id="nestedatt--spec"></a>
### Nested Schema for `spec`

Read-Only:

- `statements` (List of Object) (see [below for nested schema](#nestedobjatt--spec--statements))

<a id="nestedobjatt--spec--statements"></a>
### Nested Schema for `spec.statements`

Read-Only:

- `actions` (Set of String)
- `paths` (Set of String)
- `resources` (List of Object) (see [below for nested schema](#nestedobjatt--spec--statements--resources))

<a id="nestedobjatt--spec--statements--resources"></a>
### Nested Schema for `spec.statements.resources`

Read-Only:

- `api_group` (String)
- `kind` (String)
20 changes: 4 additions & 16 deletions docs/data-sources/rolebinding.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,27 +66,15 @@ Optional:

Read-Only:

- `policy_inline` (List of Object) (see [below for nested schema](#nestedobjatt--spec--policy_inline))
- `policy_ref` (String)
- `role_ref` (List of Object) (see [below for nested schema](#nestedobjatt--spec--role_ref))
- `subject_ref` (List of Object) (see [below for nested schema](#nestedobjatt--spec--subject_ref))

<a id="nestedobjatt--spec--policy_inline"></a>
### Nested Schema for `spec.policy_inline`
<a id="nestedobjatt--spec--role_ref"></a>
### Nested Schema for `spec.role_ref`

Read-Only:

- `actions` (Set of String)
- `paths` (Set of String)
- `resources` (List of Object) (see [below for nested schema](#nestedobjatt--spec--policy_inline--resources))

<a id="nestedobjatt--spec--policy_inline--resources"></a>
### Nested Schema for `spec.policy_inline.resources`

Read-Only:

- `api_group` (String)
- `kind` (String)

- `name` (String)


<a id="nestedobjatt--spec--subject_ref"></a>
Expand Down
20 changes: 4 additions & 16 deletions docs/data-sources/rolebindings.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,27 +84,15 @@ Read-Only:

Read-Only:

- `policy_inline` (List of Object) (see [below for nested schema](#nestedobjatt--items--spec--policy_inline))
- `policy_ref` (String)
- `role_ref` (List of Object) (see [below for nested schema](#nestedobjatt--items--spec--role_ref))
- `subject_ref` (List of Object) (see [below for nested schema](#nestedobjatt--items--spec--subject_ref))

<a id="nestedobjatt--items--spec--policy_inline"></a>
### Nested Schema for `items.spec.policy_inline`
<a id="nestedobjatt--items--spec--role_ref"></a>
### Nested Schema for `items.spec.role_ref`

Read-Only:

- `actions` (Set of String)
- `paths` (Set of String)
- `resources` (List of Object) (see [below for nested schema](#nestedobjatt--items--spec--policy_inline--resources))

<a id="nestedobjatt--items--spec--policy_inline--resources"></a>
### Nested Schema for `items.spec.policy_inline.resources`

Read-Only:

- `api_group` (String)
- `kind` (String)

- `name` (String)


<a id="nestedobjatt--items--spec--subject_ref"></a>
Expand Down
93 changes: 93 additions & 0 deletions docs/data-sources/roles.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
---
# generated by https://github.com/hashicorp/terraform-plugin-docs
page_title: "bluechip_roles Data Source - terraform-provider-bluechip"
subcategory: ""
description: |-
---

# bluechip_roles (Data Source)



## Example Usage

```terraform
data "bluechip_roles" "current" {
}
```

<!-- schema generated by tfplugindocs -->
## Schema

### Optional

- `filter` (Block List) Filter is a list of query terms to filter the results by. (see [below for nested schema](#nestedblock--filter))
- `timeouts` (Block, Optional) (see [below for nested schema](#nestedblock--timeouts))

### Read-Only

- `id` (String) The ID of this resource.
- `items` (List of Object) Filter is a list of query terms to filter the results by. (see [below for nested schema](#nestedatt--items))

<a id="nestedblock--filter"></a>
### Nested Schema for `filter`

Required:

- `field` (String) Field to use for the query term.
- `operator` (String) Operator to use for the query term. One of ['equals', 'notEquals', 'fuzzy', 'wildcard', 'regex', 'matchPhrase', 'prefix'].
- `value` (String) Value to use for the query term.


<a id="nestedblock--timeouts"></a>
### Nested Schema for `timeouts`

Optional:

- `default` (String)


<a id="nestedatt--items"></a>
### Nested Schema for `items`

Read-Only:

- `metadata` (List of Object) (see [below for nested schema](#nestedobjatt--items--metadata))
- `spec` (List of Object) (see [below for nested schema](#nestedobjatt--items--spec))

<a id="nestedobjatt--items--metadata"></a>
### Nested Schema for `items.metadata`

Read-Only:

- `annotations` (Map of String)
- `creation_timestamp` (String)
- `labels` (Map of String)
- `name` (String)
- `update_timestamp` (String)


<a id="nestedobjatt--items--spec"></a>
### Nested Schema for `items.spec`

Read-Only:

- `statements` (List of Object) (see [below for nested schema](#nestedobjatt--items--spec--statements))

<a id="nestedobjatt--items--spec--statements"></a>
### Nested Schema for `items.spec.statements`

Read-Only:

- `actions` (Set of String)
- `paths` (Set of String)
- `resources` (List of Object) (see [below for nested schema](#nestedobjatt--items--spec--statements--resources))

<a id="nestedobjatt--items--spec--statements--resources"></a>
### Nested Schema for `items.spec.statements.resources`

Read-Only:

- `api_group` (String)
- `kind` (String)
32 changes: 7 additions & 25 deletions docs/resources/clusterrolebinding.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,42 +66,24 @@ Read-Only:

Required:

- `role_ref` (Block List, Min: 1) (see [below for nested schema](#nestedblock--spec--role_ref))
- `subject_ref` (Block List, Min: 1) (see [below for nested schema](#nestedblock--spec--subject_ref))

Optional:

- `policy_inline` (Block List) (see [below for nested schema](#nestedblock--spec--policy_inline))
- `policy_ref` (String)

<a id="nestedblock--spec--subject_ref"></a>
### Nested Schema for `spec.subject_ref`
<a id="nestedblock--spec--role_ref"></a>
### Nested Schema for `spec.role_ref`

Required:

- `kind` (String) Kind of the referent. Valid kinds are 'User', 'Group'.
- `name` (String) Name of the referent.


<a id="nestedblock--spec--policy_inline"></a>
### Nested Schema for `spec.policy_inline`

Required:

- `actions` (Set of String) Actions is a list of actions this role binding grants access to.

Optional:

- `paths` (Set of String) Paths is a list of paths this role binding grants access to.
- `resources` (Block List) Resources is a list of resources this role binding grants access to. (see [below for nested schema](#nestedblock--spec--policy_inline--resources))

<a id="nestedblock--spec--policy_inline--resources"></a>
### Nested Schema for `spec.policy_inline.resources`
<a id="nestedblock--spec--subject_ref"></a>
### Nested Schema for `spec.subject_ref`

Required:

- `api_group` (String) APIGroup is the group for the resource being referenced.
- `kind` (String) Kind is the type of resource being referenced.

- `kind` (String) Kind of the referent. Valid kinds are 'User', 'Group'.
- `name` (String) Name of the referent.



Expand Down
Loading

0 comments on commit 1c1303a

Please sign in to comment.