Skip to content

Add example for awscc_codedeploy_deployment_group - #3026

Open
wellsiau-aws wants to merge 3 commits into
hashicorp:mainfrom
wellsiau-aws:d-awscc_codedeploy_deployment_group
Open

Add example for awscc_codedeploy_deployment_group#3026
wellsiau-aws wants to merge 3 commits into
hashicorp:mainfrom
wellsiau-aws:d-awscc_codedeploy_deployment_group

Conversation

@wellsiau-aws

Copy link
Copy Markdown
Collaborator

Description

This PR adds a validated Terraform example for awscc_codedeploy_deployment_group.

Validation Summary

  • ✅ Terraform code generated and validated
  • ✅ Real AWS deployment tested (apply/destroy lifecycle)
  • ✅ Independent validation review completed
  • ✅ Required tools installed with make tools
  • ✅ Documentation generated with make docs

Resource Details

  • Resource: awscc_codedeploy_deployment_group
  • Provider Version: 1.69.0
  • Validation Date: 2026-02-19
  • AWS Region: us-west-2

Files Added

  • examples/resources/awscc_codedeploy_deployment_group/codedeploy_deployment_group.tf
  • templates/resources/awscc_codedeploy_deployment_group.md.tmpl
  • docs/resources/awscc_codedeploy_deployment_group.md (auto-generated by make docs)

Validation Report

Click to expand full validation report
TERRAFORM VALIDATION REPORT
==========================
Date: 2026-02-12 18:00:38 UTC
Resource Name: awscc_codedeploy_deployment_group
Session Name: non-agentcore

TARGET RESOURCE VERIFICATION
----------------------------
Target resource found in Terraform code: YES - awscc_codedeploy_deployment_group.example
Resource definition includes required parameters: 
- application_name: "example-application-90466070" (references aws_codedeploy_app.example.name)
- service_role_arn: references aws_iam_role.codedeploy_service.arn
- deployment_group_name: "example-deployment-group-90466070"
- deployment_config_name: "CodeDeployDefault.OneAtATime"
- ec_2_tag_filters: Configured with Environment=example filter
- tags: Proper tagging with Name and Environment

TERRAFORM LIFECYCLE TESTING
--------------------------
terraform init: skipped - reused existing (.terraform directory and lock file present)
terraform validate: SUCCESS - Configuration is valid
terraform plan: SUCCESS - 5 resources to add (aws_codedeploy_app, aws_iam_role, aws_iam_role_policy_attachment, awscc_codedeploy_deployment_group, time_sleep)
terraform apply: SUCCESS - All 5 resources created successfully:
  - aws_codedeploy_app.example: Created (id: a31b557b-ee72-4b10-905a-5dfc7f31463f:example-application-90466070)
  - aws_iam_role.codedeploy_service: Created (id: example-codedeploy-service-role-90466070)
  - aws_iam_role_policy_attachment.codedeploy_service: Created
  - time_sleep.wait_for_iam_role: Created (15s delay for IAM propagation)
  - awscc_codedeploy_deployment_group.example: Created (id: example-application-90466070|example-deployment-group-90466070)
terraform destroy: SUCCESS - All 5 resources destroyed cleanly

RESOURCE VERIFICATION
-------------------
Target resource was successfully provisioned: YES
Resource details: 
- CodeDeploy Deployment Group created with ID: example-application-90466070|example-deployment-group-90466070
- Application name: example-application-90466070
- Deployment config: CodeDeployDefault.OneAtATime
- Service role ARN: arn:aws:iam::204034886740:role/example-codedeploy-service-role-90466070
- EC2 tag filters configured for Environment=example
- Proper IAM role with CodeDeploy service permissions
- 15-second delay implemented for IAM role propagation
All resources were properly destroyed: YES - Clean destruction of all 5 resources

VALIDATION RESULT
----------------
RESULT: PASSED
DETAILS: Independent validation successful. Target resource awscc_codedeploy_deployment_group was found in Terraform code, all lifecycle steps completed successfully, real AWS resources were created and properly destroyed. The code includes necessary supplemental resources (CodeDeploy application, IAM role, policy attachment, timing delay) and implements fixes for IAM role propagation.

This PR was automatically generated by the TANGO Multi-Agent Pipeline.

This commit adds a validated Terraform example for the awscc_codedeploy_deployment_group resource.

Files added:
- examples/resources/awscc_codedeploy_deployment_group/codedeploy_deployment_group.tf
- templates/resources/awscc_codedeploy_deployment_group.md.tmpl
- docs/resources/awscc_codedeploy_deployment_group.md (generated by make docs)

The example has been validated through real AWS deployment testing
and passes all HashiCorp validation requirements.

Generated by TANGO Multi-Agent Pipeline
Comment on lines +38 to +41
resource "time_sleep" "wait_for_iam_role" {
depends_on = [aws_iam_role_policy_attachment.codedeploy_service]
create_duration = "15s"
}

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IAM eventual consistency feels like something the upstream service should handle. Is it possible to verify this example without enforced sleep? If it is still problematic perhaps this warrants it's own bug report.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants