From 6e36497f75e045d6b70ef44d6184c9591ad38c08 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?M=C3=A9sz=C3=A1ros=20Gergely?= <16577123+gregito@users.noreply.github.com> Date: Thu, 14 Mar 2024 17:01:12 +0100 Subject: [PATCH] CDPCP-11620 - fixing lack of compute property for encryption_at_host field, with newly generated docs as well (#94) --- docs/resources/datalake_aws_datalake.md | 1 + docs/resources/datalake_azure_datalake.md | 3 +- docs/resources/datalake_gcp_datalake.md | 8 ++-- .../resources/environments_aws_environment.md | 25 +++++++++++++ .../environments_azure_environment.md | 27 ++++++++++++++ .../resources/environments_gcp_environment.md | 37 +++++++++++++++++-- .../environments/schema_azure_environment.go | 1 + .../schema_azure_environment_test.go | 2 +- 8 files changed, 93 insertions(+), 11 deletions(-) diff --git a/docs/resources/datalake_aws_datalake.md b/docs/resources/datalake_aws_datalake.md index dc04aa80..60bb0140 100644 --- a/docs/resources/datalake_aws_datalake.md +++ b/docs/resources/datalake_aws_datalake.md @@ -139,6 +139,7 @@ Optional: Optional: +- `async` (Boolean) Boolean value that specifies if Terraform should wait for resource creation/deletion. - `polling_timeout` (Number) Timeout value in minutes that specifies for how long should the polling go for resource creation/deletion. diff --git a/docs/resources/datalake_azure_datalake.md b/docs/resources/datalake_azure_datalake.md index a84e3eee..8ae2eec9 100644 --- a/docs/resources/datalake_azure_datalake.md +++ b/docs/resources/datalake_azure_datalake.md @@ -23,7 +23,7 @@ A Data Lake is a service which provides a protective ring around the data stored ### Optional -- `database_type` (Number) The type of the azure database. FLEXIBLE_SERVER is the next generation managed PostgreSQL service in Azure that provides maximum flexibility over your database, built-in cost-optimizations. SINGLE_SERVER is a fully managed database service with minimal requirements for customizations of the database. +- `database_type` (String) The type of the azure database. FLEXIBLE_SERVER is the next generation managed PostgreSQL service in Azure that provides maximum flexibility over your database, built-in cost-optimizations. SINGLE_SERVER is a fully managed database service with minimal requirements for customizations of the database. - `enable_ranger_raz` (Boolean) - `image` (Attributes) (see [below for nested schema](#nestedatt--image)) - `java_version` (Number) @@ -65,6 +65,7 @@ Optional: Optional: +- `async` (Boolean) Boolean value that specifies if Terraform should wait for resource creation/deletion. - `polling_timeout` (Number) Timeout value in minutes that specifies for how long should the polling go for resource creation/deletion. diff --git a/docs/resources/datalake_gcp_datalake.md b/docs/resources/datalake_gcp_datalake.md index fa815b71..20f72804 100644 --- a/docs/resources/datalake_gcp_datalake.md +++ b/docs/resources/datalake_gcp_datalake.md @@ -119,6 +119,7 @@ Optional: Optional: +- `async` (Boolean) Boolean value that specifies if Terraform should wait for resource creation/deletion. - `polling_timeout` (Number) Timeout value in minutes that specifies for how long should the polling go for resource creation/deletion. @@ -127,10 +128,7 @@ Optional: Required: -- `instance_group_name` (String) -- `recipe_names` (Attributes Set) (see [below for nested schema](#nestedatt--recipes--recipe_names)) - - -### Nested Schema for `recipes.recipe_names` +- `instance_group_name` (String) The name of the designated instance group. +- `recipe_names` (Set of String) The set of recipe names that are going to be applied on the given instance group. diff --git a/docs/resources/environments_aws_environment.md b/docs/resources/environments_aws_environment.md index 2de2f28b..2f13e1bf 100644 --- a/docs/resources/environments_aws_environment.md +++ b/docs/resources/environments_aws_environment.md @@ -141,10 +141,35 @@ Optional: - `os` (String) - `recipes` (Set of String) +Read-Only: + +- `instances` (Attributes Set) (see [below for nested schema](#nestedatt--freeipa--instances)) + + +### Nested Schema for `freeipa.instances` + +Read-Only: + +- `availability_zone` (String) +- `discovery_fqdn` (String) +- `instance_group` (String) +- `instance_id` (String) +- `instance_status` (String) +- `instance_status_reason` (String) +- `instance_type` (String) +- `instance_vm_type` (String) +- `life_cycle` (String) +- `private_ip` (String) +- `public_ip` (String) +- `ssh_port` (Number) +- `subnet_id` (String) + + ### Nested Schema for `polling_options` Optional: +- `async` (Boolean) Boolean value that specifies if Terraform should wait for resource creation/deletion. - `polling_timeout` (Number) Timeout value in minutes that specifies for how long should the polling go for resource creation/deletion. \ No newline at end of file diff --git a/docs/resources/environments_azure_environment.md b/docs/resources/environments_azure_environment.md index dd0d6d89..a1396ef2 100644 --- a/docs/resources/environments_azure_environment.md +++ b/docs/resources/environments_azure_environment.md @@ -82,6 +82,7 @@ output "crn" { - `description` (String) - `enable_outbound_load_balancer` (Boolean) - `enable_tunnel` (Boolean) +- `encryption_at_host` (Boolean) - `encryption_key_resource_group_name` (String) - `encryption_key_url` (String) - `endpoint_access_gateway_scheme` (String) The scheme for the endpoint gateway. PUBLIC creates an external endpoint that can be accessed over the Internet. Defaults to PRIVATE which restricts the traffic to be internal to the VPC. @@ -153,9 +154,34 @@ Optional: - `image_id` (String) - `instance_count_by_group` (Number) - `instance_type` (String) +- `multi_az` (Boolean) - `os` (String) - `recipes` (Set of String) +Read-Only: + +- `instances` (Attributes Set) (see [below for nested schema](#nestedatt--freeipa--instances)) + + +### Nested Schema for `freeipa.instances` + +Read-Only: + +- `availability_zone` (String) +- `discovery_fqdn` (String) +- `instance_group` (String) +- `instance_id` (String) +- `instance_status` (String) +- `instance_status_reason` (String) +- `instance_type` (String) +- `instance_vm_type` (String) +- `life_cycle` (String) +- `private_ip` (String) +- `public_ip` (String) +- `ssh_port` (Number) +- `subnet_id` (String) + + ### Nested Schema for `new_network_params` @@ -170,4 +196,5 @@ Required: Optional: +- `async` (Boolean) Boolean value that specifies if Terraform should wait for resource creation/deletion. - `polling_timeout` (Number) Timeout value in minutes that specifies for how long should the polling go for resource creation/deletion. \ No newline at end of file diff --git a/docs/resources/environments_gcp_environment.md b/docs/resources/environments_gcp_environment.md index 0d2820b6..50a5c37b 100644 --- a/docs/resources/environments_gcp_environment.md +++ b/docs/resources/environments_gcp_environment.md @@ -92,7 +92,7 @@ output "shared_project_id" { - `enable_tunnel` (Boolean) Whether to enable SSH tunneling for the environment. - `encryption_key` (String) Key Resource ID of the customer managed encryption key to encrypt GCP resources. - `endpoint_access_gateway_scheme` (String) The scheme for the endpoint gateway. PUBLIC creates an external endpoint that can be accessed over the Internet. Defaults to PRIVATE which restricts the traffic to be internal to the VPC. -- `freeipa` (Attributes) The FreeIPA creation request for the environment. (see [below for nested schema](#nestedatt--freeipa)) +- `freeipa` (Attributes) (see [below for nested schema](#nestedatt--freeipa)) - `log_storage` (Attributes) GCP storage configuration for cluster and audit logs. (see [below for nested schema](#nestedatt--log_storage)) - `polling_options` (Attributes) Polling related configuration options that could specify various values that will be used during CDP resource creation. (see [below for nested schema](#nestedatt--polling_options)) - `proxy_config_name` (String) Name of the proxy config to use for the environment. @@ -123,9 +123,37 @@ Required: Optional: -- `instance_count_by_group` (Number) The number of FreeIPA instances to create per group when creating FreeIPA in the environment. -- `instance_type` (String) Custom instance type of FreeIPA instances. -- `recipes` (Set of String) The recipes for the FreeIPA cluster. +- `catalog` (String) +- `image_id` (String) +- `instance_count_by_group` (Number) +- `instance_type` (String) +- `multi_az` (Boolean) +- `os` (String) +- `recipes` (Set of String) + +Read-Only: + +- `instances` (Attributes Set) (see [below for nested schema](#nestedatt--freeipa--instances)) + + +### Nested Schema for `freeipa.instances` + +Read-Only: + +- `availability_zone` (String) +- `discovery_fqdn` (String) +- `instance_group` (String) +- `instance_id` (String) +- `instance_status` (String) +- `instance_status_reason` (String) +- `instance_type` (String) +- `instance_vm_type` (String) +- `life_cycle` (String) +- `private_ip` (String) +- `public_ip` (String) +- `ssh_port` (Number) +- `subnet_id` (String) + @@ -146,6 +174,7 @@ Optional: Optional: +- `async` (Boolean) Boolean value that specifies if Terraform should wait for resource creation/deletion. - `polling_timeout` (Number) Timeout value in minutes that specifies for how long should the polling go for resource creation/deletion. diff --git a/resources/environments/schema_azure_environment.go b/resources/environments/schema_azure_environment.go index baa013db..67abf7c9 100644 --- a/resources/environments/schema_azure_environment.go +++ b/resources/environments/schema_azure_environment.go @@ -107,6 +107,7 @@ var AzureEnvironmentSchema = schema.Schema{ }, "encryption_at_host": schema.BoolAttribute{ Optional: true, + Computed: true, Default: booldefault.StaticBool(false), }, "environment_name": schema.StringAttribute{ diff --git a/resources/environments/schema_azure_environment_test.go b/resources/environments/schema_azure_environment_test.go index 57adb883..d68dcf10 100644 --- a/resources/environments/schema_azure_environment_test.go +++ b/resources/environments/schema_azure_environment_test.go @@ -91,7 +91,7 @@ var schemaElements = []SchemaTestCaseStructure{ { name: "encryption_at_host should exist and be valid", field: "encryption_at_host", - computed: false, + computed: true, shouldBeRequired: false, }, {