mirror of
https://github.com/hanzokms/terraform-provider.git
synced 2026-10-30 20:29:45 +00:00
1.6 KiB
1.6 KiB
page_title, subcategory, description
| page_title | subcategory | description |
|---|---|---|
| kms_project_environment Resource - terraform-provider | Projects | Create project environment |
kms_project_environment (Resource)
Create project environment
Example Usage
terraform {
required_providers {
kms = {
# version = <latest version>
source = "hanzokms/kms"
}
}
}
provider "kms" {
host = "https://kms.hanzo.ai" # Only required if using self hosted instance of Hanzo KMS, default is https://kms.hanzo.ai
auth = {
universal = {
client_id = "<machine-identity-client-id>"
client_secret = "<machine-identity-client-secret>"
}
}
}
resource "kms_project" "example" {
name = "example"
slug = "example"
position = 1 # Optional
}
resource "kms_project_environment" "pre-prod" {
name = "pre-prod"
project_id = kms_project.example.id
slug = "preprod"
position = 2 # Optional
}
Schema
Required
name(String) The name of the environmentproject_id(String) The Hanzo KMS project ID (Required for Machine Identity auth, and service tokens with multiple scopes)slug(String) The slug of the environment
Optional
position(Number) The position of the environment
Read-Only
id(String) The ID of the environment
Import
Import is supported using the following syntax:
# This will import the project environment by the project environment ID
terraform import kms_project_environment.example <project_environment_id>