Skip to content

Commit

Permalink
fix(spanner): fix spanner table iam binding triggering an apply on pe…
Browse files Browse the repository at this point in the history
…rmissions reorder
  • Loading branch information
newtonnthiga committed Aug 29, 2024
1 parent 4ead0f3 commit 167243e
Show file tree
Hide file tree
Showing 110 changed files with 823 additions and 1,217 deletions.
25 changes: 6 additions & 19 deletions docs/data-sources/google_bigtable_table_iam_policy.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,33 +9,20 @@ description: |-



## Example Usage

```terraform
terraform {
required_providers {
alis = {
source = "alis-exchange/alis"
version = "1.1.0"
}
}
}

provider "alis" {
}
## Example Usage

```terraform
data "alis_google_bigtable_table_iam_policy" "policy" {
project = var.ALIS_OS_PROJECT
instance = var.ALIS_OS_BIGTABLE_INSTANCE
project = var.GOOGLE_PROJECT
instance = var.BIGTABLE_INSTANCE
table = "tf-test"
}
output "test_iam" {
description = "The IAM policy for the table"
value = data.alis_google_bigtable_table_iam_policy.policy
}
```



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

Expand Down
24 changes: 5 additions & 19 deletions docs/data-sources/google_discovery_engine_data_store_schemas.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,34 +9,20 @@ description: |-



## Example Usage

```terraform
terraform {
required_providers {
alis = {
source = "alis-exchange/alis"
version = "1.1.0"
}
}
}

provider "alis" {
}
## Example Usage

```terraform
data "alis_google_discovery_engine_data_store_schemas" "schemas" {
project = var.ALIS_OS_PROJECT
project = var.GOOGLE_PROJECT
location = "global"
collection_id = "default_collection"
data_store_id = var.ALIS_OS_DISCOVERY_ENGINE_DATASTORE
data_store_id = var.DISCOVERY_ENGINE_DATASTORE
}
```


output "test_iam" {
description = "Available schemas"
value = data.alis_google_discovery_engine_data_store_schemas.schemas
}
```

<!-- schema generated by tfplugindocs -->
## Schema
Expand Down
25 changes: 6 additions & 19 deletions docs/data-sources/google_spanner_database_iam_policy.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,33 +9,20 @@ description: |-



## Example Usage

```terraform
terraform {
required_providers {
alis = {
source = "alis-exchange/alis"
version = "1.1.0"
}
}
}

provider "alis" {
}
## Example Usage

```terraform
data "alis_google_spanner_database_iam_policy" "policy" {
project = var.ALIS_OS_PROJECT
instance = var.ALIS_OS_SPANNER_INSTANCE
project = var.GOOGLE_PROJECT
instance = var.SPANNER_INSTANCE
database = "tf-test"
}
output "test_iam" {
description = "The IAM policy for the database"
value = data.alis_google_spanner_database_iam_policy.policy
}
```



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

Expand Down
25 changes: 6 additions & 19 deletions docs/data-sources/google_spanner_database_roles.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,33 +9,20 @@ description: |-



## Example Usage

```terraform
terraform {
required_providers {
alis = {
source = "alis-exchange/alis"
version = "1.1.2"
}
}
}

provider "alis" {
}
## Example Usage

```terraform
data "alis_google_spanner_database_roles" "roles" {
project = var.ALIS_OS_PROJECT
instance = var.ALIS_OS_SPANNER_INSTANCE
project = var.GOOGLE_PROJECT
instance = var.SPANNER_INSTANCE
database = "tf-test"
}
output "test_iam" {
description = "The Roles in the Spanner Database."
value = data.alis_google_spanner_database_roles.roles
}
```



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

Expand Down
27 changes: 7 additions & 20 deletions docs/data-sources/google_spanner_table_iam_binding.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,35 +11,22 @@ description: |-
Authoritative for a given role. Updates the table IAM policy to grant a role along with permissions.
Other roles and permissions within the IAM policy for the table are preserved.

## Example Usage

```terraform
terraform {
required_providers {
alis = {
source = "alis-exchange/alis"
version = "1.1.2"
}
}
}

provider "alis" {
}
## Example Usage

```terraform
data "alis_google_spanner_table_iam_binding" "admin_binding" {
project = var.ALIS_OS_PROJECT
instance = var.ALIS_OS_SPANNER_INSTANCE
project = var.GOOGLE_PROJECT
instance = var.SPANNER_INSTANCE
database = "tf-test"
table = "tftest"
role = "admin"
}
output "test_iam" {
description = "The IAM policy for the database"
value = data.alis_google_spanner_table_iam_binding.admin_binding
}
```



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

Expand All @@ -53,5 +40,5 @@ output "test_iam" {

### Read-Only

- `permissions` (List of String) The permissions that should be granted to the role.
- `permissions` (Set of String) The permissions that should be granted to the role.
Valid permissions are: `SELECT`, `INSERT`, `UPDATE`, `DELETE`.
7 changes: 6 additions & 1 deletion docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,22 +10,27 @@ description: |-

Custom terraform provider for managing various google resources used in ALIS.



## Example Usage

```terraform
terraform {
required_providers {
alis = {
source = "alis-exchange/alis"
version = "1.1.0"
version = ">= 1.4.0"
}
}
}
provider "alis" {
project = var.GOOGLE_PROJECT
}
```



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

Expand Down
31 changes: 12 additions & 19 deletions docs/resources/google_bigtable_gc_policy.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,24 +9,14 @@ description: |-



## Example Usage

```terraform
terraform {
required_providers {
alis = {
source = "alis-exchange/alis"
version = "1.1.0"
}
}
}

provider "alis" {
}
## Example Usage

```terraform
resource "alis_google_bigtable_gc_policy" "simple" {
project = var.ALIS_OS_PROJECT
instance = var.ALIS_OS_BIGTABLE_INSTANCE
project = var.GOOGLE_PROJECT
instance = var.BIGTABLE_INSTANCE
table = "tf-test"
column_family = "0"
gc_rules = jsonencode({
Expand All @@ -39,8 +29,8 @@ resource "alis_google_bigtable_gc_policy" "simple" {
}
resource "alis_google_bigtable_gc_policy" "complex_union" {
project = var.ALIS_OS_PROJECT
instance = var.ALIS_OS_BIGTABLE_INSTANCE
project = var.GOOGLE_PROJECT
instance = var.BIGTABLE_INSTANCE
table = "tf-test"
column_family = "1"
gc_rules = jsonencode({
Expand All @@ -57,8 +47,8 @@ resource "alis_google_bigtable_gc_policy" "complex_union" {
}
resource "alis_google_bigtable_gc_policy" "complex_intersection" {
project = var.ALIS_OS_PROJECT
instance = var.ALIS_OS_BIGTABLE_INSTANCE
project = var.GOOGLE_PROJECT
instance = var.BIGTABLE_INSTANCE
table = "tf-test"
column_family = "2"
gc_rules = jsonencode({
Expand All @@ -75,6 +65,8 @@ resource "alis_google_bigtable_gc_policy" "complex_intersection" {
}
```



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

Expand All @@ -98,4 +90,5 @@ Setting `ABANDON` allows the resource to be abandoned rather than deleted.
This is useful for GC policy as it cannot be deleted in a replicated instance.
**Note that when set to `ABANDON`, this only removes the `deletion_policy` from terraform state.
Garbage collection still happens on the specified column family.**
Possible values are: `ABANDON`.
Possible values are: `ABANDON`.

28 changes: 8 additions & 20 deletions docs/resources/google_bigtable_table.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,25 +13,14 @@ This resource provisions and manages tables in a Bigtable instance.

> NOTE: This resource at the moment offers nothing beyond the standard Google provider. It is recommended to use the standard Google provider for now.
## Example Usage

```terraform
terraform {
required_providers {
alis = {
source = "alis-exchange/alis"
version = "1.1.0"
}
}
}

provider "alis" {

}
## Example Usage

```terraform
resource "alis_google_bigtable_table" "test" {
project = var.ALIS_OS_PROJECT
instance = var.ALIS_OS_BIGTABLE_INSTANCE
project = var.GOOGLE_PROJECT
instance = var.BIGTABLE_INSTANCE
name = "tf-test"
column_families = [
{
Expand All @@ -41,12 +30,10 @@ resource "alis_google_bigtable_table" "test" {
deletion_protection = false
# change_stream_retention = "86400s"
}
output "test_table" {
value = alis_google_bigtable_table.test
}
```



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

Expand All @@ -69,4 +56,5 @@ If not provided, currently deletion protection will be set to `UNPROTECTED` as i

Required:

- `name` (String) The name of the column family.
- `name` (String) The name of the column family.

Loading

0 comments on commit 167243e

Please sign in to comment.