Skip to content

feat: add examples for additional resources #2343

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 8 commits into from
Jun 17, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion contributing/DEVELOPMENT.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ Clone repository to: `$HOME/development/terraform-providers/`

```sh
$ mkdir -p $HOME/development/terraform-providers/; cd $HOME/development/terraform-providers/
$ git clone git@github.com:terraform-providers/terraform-provider-awscc
$ git clone git@github.com:hashicorp/terraform-provider-awscc
...
```

Expand Down
13 changes: 12 additions & 1 deletion docs/resources/applicationsignals_discovery.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@

---
# generated by https://github.com/hashicorp/terraform-plugin-docs
page_title: "awscc_applicationsignals_discovery Resource - terraform-provider-awscc"
subcategory: ""
description: |-
Expand All @@ -10,7 +10,18 @@ description: |-

Resource Type definition for AWS::ApplicationSignals::Discovery

## Example Usage

### Configure Application Signals Discovery

Configures AWS Application Signals discovery service which appears to be empty or pending configuration details.

~> This example is generated by LLM using Amazon Bedrock and validated using terraform validate, apply and destroy. While we strive for accuracy and quality, please note that the information provided may not be entirely error-free or up-to-date. We recommend independently verifying the content.

```terraform
resource "awscc_applicationsignals_discovery" "example" {
}
```

<!-- schema generated by tfplugindocs -->
## Schema
Expand Down
25 changes: 24 additions & 1 deletion docs/resources/batch_consumable_resource.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@

---
# generated by https://github.com/hashicorp/terraform-plugin-docs
page_title: "awscc_batch_consumable_resource Resource - terraform-provider-awscc"
subcategory: ""
description: |-
Expand All @@ -10,7 +10,30 @@ description: |-

Resource Type definition for AWS::Batch::ConsumableResource

## Example Usage

### AWS Batch Consumable Resource Configuration

Creates a replenishable consumable resource for AWS Batch with a total quantity of 10 units, enabling license management for batch workloads.

~> This example is generated by LLM using Amazon Bedrock and validated using terraform validate, apply and destroy. While we strive for accuracy and quality, please note that the information provided may not be entirely error-free or up-to-date. We recommend independently verifying the content.

```terraform
# Batch Consumable Resource Example
resource "awscc_batch_consumable_resource" "demo" {
resource_type = "REPLENISHABLE"
total_quantity = 10
consumable_resource_name = "demo-license-resource"

tags = [{
key = "Environment"
value = "demo"
}, {
key = "Modified By"
value = "AWSCC"
}]
}
```

<!-- schema generated by tfplugindocs -->
## Schema
Expand Down
43 changes: 40 additions & 3 deletions docs/resources/bedrock_intelligent_prompt_router.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
---
# generated by https://github.com/hashicorp/terraform-plugin-docs
page_title: "awscc_bedrock_intelligent_prompt_router Resource - terraform-provider-awscc"
subcategory: ""
description: |-
Expand All @@ -10,7 +9,45 @@ description: |-

Definition of AWS::Bedrock::IntelligentPromptRouter Resource Type


## Example Usage

```terraform
data "aws_region" "current" {}

# Create the Bedrock Intelligent Prompt Router
resource "awscc_bedrock_intelligent_prompt_router" "example" {
prompt_router_name = "example-intelligent-prompt-router"
description = "Example intelligent prompt router for routing between Claude models based on response quality"

# Primary models to route between (limited to exactly 2 models)
models = [
{
model_arn = "arn:aws:bedrock:${data.aws_region.current.name}::foundation-model/anthropic.claude-3-5-sonnet-20241022-v2:0"
},
{
model_arn = "arn:aws:bedrock:${data.aws_region.current.name}::foundation-model/anthropic.claude-3-haiku-20240307-v1:0"
}
]

# Fallback model (must be one of the models in the models list above)
fallback_model = {
model_arn = "arn:aws:bedrock:${data.aws_region.current.name}::foundation-model/anthropic.claude-3-haiku-20240307-v1:0"
}

# Routing criteria based on response quality difference
# Value must be a multiple of 5 (likely as percentage: 5, 10, 15, 20, etc.)
routing_criteria = {
response_quality_difference = 20
}

tags = [
{
key = "ModifiedBy"
value = "AWSCC"
}
]
}
```

<!-- schema generated by tfplugindocs -->
## Schema
Expand Down Expand Up @@ -74,4 +111,4 @@ Import is supported using the following syntax:

```shell
$ terraform import awscc_bedrock_intelligent_prompt_router.example "prompt_router_arn"
```
```
43 changes: 42 additions & 1 deletion docs/resources/cognito_user_pool_domain.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@

---
# generated by https://github.com/hashicorp/terraform-plugin-docs
page_title: "awscc_cognito_user_pool_domain Resource - terraform-provider-awscc"
subcategory: ""
description: |-
Expand All @@ -10,7 +10,48 @@ description: |-

Resource Type definition for AWS::Cognito::UserPoolDomain

## Example Usage

### Configure Cognito User Pool Domain

Creates a custom domain for a Cognito User Pool with dynamic naming based on the AWS account ID, enabling a branded URL for user authentication endpoints.

~> This example is generated by LLM using Amazon Bedrock and validated using terraform validate, apply and destroy. While we strive for accuracy and quality, please note that the information provided may not be entirely error-free or up-to-date. We recommend independently verifying the content.

```terraform
# Get current account ID for dynamic naming
data "aws_caller_identity" "current" {}

# Create the Cognito User Pool
resource "aws_cognito_user_pool" "example" {
name = "my-user-pool"

auto_verified_attributes = ["email"]
username_attributes = ["email"]

verification_message_template {
default_email_option = "CONFIRM_WITH_CODE"
}

admin_create_user_config {
allow_admin_create_user_only = false
}

email_configuration {
email_sending_account = "COGNITO_DEFAULT"
}

tags = {
"Modified By" = "AWS"
}
}

# Create the User Pool Domain
resource "awscc_cognito_user_pool_domain" "example" {
domain = "my-example-domain-${data.aws_caller_identity.current.account_id}"
user_pool_id = aws_cognito_user_pool.example.id
}
```

<!-- schema generated by tfplugindocs -->
## Schema
Expand Down
25 changes: 24 additions & 1 deletion docs/resources/deadline_limit.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@

---
# generated by https://github.com/hashicorp/terraform-plugin-docs
page_title: "awscc_deadline_limit Resource - terraform-provider-awscc"
subcategory: ""
description: |-
Expand All @@ -10,7 +10,30 @@ description: |-

Definition of AWS::Deadline::Limit Resource Type

## Example Usage

```terraform
resource "awscc_deadline_farm" "example" {
display_name = "ExampleRenderFarm"
description = "Example Deadline Farm for demonstrating limit configuration"

tags = [
{
key = "ModifiedBy"
value = "AWSCC"
}
]
}

# Create a Deadline Limit for CPU usage
resource "awscc_deadline_limit" "example" {
farm_id = awscc_deadline_farm.example.farm_id
display_name = "CPU Limit"
description = "CPU core usage limit for the render farm"
amount_requirement_name = "amount.cpu"
max_count = 100
}
```

<!-- schema generated by tfplugindocs -->
## Schema
Expand Down
105 changes: 102 additions & 3 deletions docs/resources/deadline_queue.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
---
# generated by https://github.com/hashicorp/terraform-plugin-docs
page_title: "awscc_deadline_queue Resource - terraform-provider-awscc"
subcategory: ""
description: |-
Expand All @@ -10,7 +9,107 @@ description: |-

Definition of AWS::Deadline::Queue Resource Type


## Example Usage

```terraform
# Create S3 bucket for job attachments
resource "awscc_s3_bucket" "example" {
bucket_name = "deadline-job-attachments-${random_id.bucket_suffix.hex}"

tags = [{
key = "ModifiedBy"
value = "AWSCC"
}]
}

# Generate random suffix for bucket name uniqueness
resource "random_id" "bucket_suffix" {
byte_length = 4
}

resource "awscc_deadline_farm" "example" {
display_name = "ExampleRenderFarm"
description = "Example Deadline Farm for queue demonstration"

tags = [{
key = "ModifiedBy"
value = "AWSCC"
}]
}

# Create storage profiles for different operating systems
resource "awscc_deadline_storage_profile" "linux_storage" {
display_name = "Linux Shared Storage"
farm_id = awscc_deadline_farm.example.farm_id
os_family = "LINUX"

file_system_locations = [{
name = "shared storage"
path = "/mnt/shared"
type = "SHARED"
}, {
name = "render assets"
path = "/mnt/assets"
type = "SHARED"
}]
}

resource "awscc_deadline_storage_profile" "windows_storage" {
display_name = "Windows Shared Storage"
farm_id = awscc_deadline_farm.example.farm_id
os_family = "WINDOWS"

file_system_locations = [{
name = "shared storage"
path = "Z:\\"
type = "SHARED"
}, {
name = "render assets"
path = "Y:\\"
type = "SHARED"
}]
}

# Create an advanced Deadline Queue with job attachment settings
resource "awscc_deadline_queue" "example" {
display_name = "AdvancedRenderQueue"
description = "Advanced render queue with S3 job attachments and custom settings"
farm_id = awscc_deadline_farm.example.farm_id
default_budget_action = "STOP_SCHEDULING_AND_COMPLETE_TASKS"

# Configure job attachment settings for S3
job_attachment_settings = {
s3_bucket_name = awscc_s3_bucket.example.bucket_name
root_prefix = "job-attachments/"
}

# Configure job run-as user settings for POSIX systems
job_run_as_user = {
run_as = "QUEUE_CONFIGURED_USER"
posix = {
user = "deadline-worker"
group = "deadline-group"
}
}

# Specify allowed storage profile IDs (dynamically referenced)
allowed_storage_profile_ids = [
awscc_deadline_storage_profile.linux_storage.storage_profile_id,
awscc_deadline_storage_profile.windows_storage.storage_profile_id
]

# Specify required file system location names
required_file_system_location_names = [
"shared storage",
"render assets"
]

tags = [{
key = "ModifiedBy"
value = "AWSCC"
}]
}
```

<!-- schema generated by tfplugindocs -->
## Schema
Expand Down Expand Up @@ -88,4 +187,4 @@ Import is supported using the following syntax:

```shell
$ terraform import awscc_deadline_queue.example "arn"
```
```
Loading