Resource: aws_appconfig_environment

Provides an AppConfig Environment resource for an aws_appconfig_application resource. One or more environments can be defined for an application.

Example Usage

resource "aws_appconfig_environment" "example" {
  name           = "example-environment-tf"
  description    = "Example AppConfig Environment"
  application_id = aws_appconfig_application.example.id

  monitor {
    alarm_arn      = aws_cloudwatch_metric_alarm.example.arn
    alarm_role_arn = aws_iam_role.example.arn
  }

  tags = {
    Type = "AppConfig Environment"
  }
}

resource "aws_appconfig_application" "example" {
  name        = "example-application-tf"
  description = "Example AppConfig Application"

  tags = {
    Type = "AppConfig Application"
  }
}

Argument Reference

This resource supports the following arguments:

Monitor

The monitor block supports the following:

Attribute Reference

This resource exports the following attributes in addition to the arguments above:

Import

In Terraform v1.5.0 and later, use an import block to import AppConfig Environments using the environment ID and application ID separated by a colon (:). For example:

import {
  to = aws_appconfig_environment.example
  id = "71abcde:11xxxxx"
}

Using terraform import, import AppConfig Environments using the environment ID and application ID separated by a colon (:). For example:

% terraform import aws_appconfig_environment.example 71abcde:11xxxxx