Add documentation to support beta resources (#417)

* add README, guide and description method

* undo unwanted changes to docs

* Update docs/guides/opting_into_beta_resources.md

Co-authored-by: GokceGK <161626272+GokceGK@users.noreply.github.com>

* address PR comments

* address PR comments

---------

Co-authored-by: GokceGK <161626272+GokceGK@users.noreply.github.com>
This commit is contained in:
Diogo Ferrão 2024-06-24 15:07:31 +01:00 committed by GitHub
parent 3a93e6e54c
commit 610b65f1cc
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 119 additions and 0 deletions

View file

@ -145,6 +145,33 @@ terraform {
Note: AWS specific checks must be skipped as they do not work on STACKIT. For details on what those validations do, see [here](https://developer.hashicorp.com/terraform/language/settings/backends/s3#configuration).
## Opting into Beta Resources
To use beta resources in the STACKIT Terraform provider, follow these steps:
1. **Provider Configuration Option**
Set the `enable_beta_resources` option in the provider configuration. This is a boolean attribute that can be either `true` or `false`.
```hcl
provider "stackit" {
region = "eu01"
enable_beta_resources = true
}
```
2. **Environment Variable**
Set the `STACKIT_TF_ENABLE_BETA_RESOURCES` environment variable to `"true"` or `"false"`. Other values will be ignored and will produce a warning.
```sh
export STACKIT_TF_ENABLE_BETA_RESOURCES=true
```
> **Note**: The environment variable takes precedence over the provider configuration option. This means that if the `STACKIT_TF_ENABLE_BETA_RESOURCES` environment variable is set to a valid value (`"true"` or `"false"`), it will override the `enable_beta_resources` option specified in the provider configuration.
For more details, please refer to the [beta resources configuration guide](TODO-LINK).
## Acceptance Tests
Terraform acceptance tests are run using the command `make test-acceptance-tf`. For all services,