Class CfnEnvironment

java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
All Implemented Interfaces:
IInspectable, ITaggable, software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct, software.constructs.IDependable

@Generated(value="jsii-pacmak/1.97.0 (build 729de35)", date="2024-04-18T17:54:16.907Z") @Stability(Stable) public class CfnEnvironment extends CfnResource implements IInspectable, ITaggable
Specify an AWS Elastic Beanstalk environment by using the AWS::ElasticBeanstalk::Environment resource in an AWS CloudFormation template.

The AWS::ElasticBeanstalk::Environment resource is an AWS Elastic Beanstalk resource type that specifies an Elastic Beanstalk environment.

Example:

 // The code below shows an example of how to instantiate this type.
 // The values are placeholders you should change.
 import software.amazon.awscdk.services.elasticbeanstalk.*;
 CfnEnvironment cfnEnvironment = CfnEnvironment.Builder.create(this, "MyCfnEnvironment")
         .applicationName("applicationName")
         // the properties below are optional
         .cnamePrefix("cnamePrefix")
         .description("description")
         .environmentName("environmentName")
         .operationsRole("operationsRole")
         .optionSettings(List.of(OptionSettingProperty.builder()
                 .namespace("namespace")
                 .optionName("optionName")
                 // the properties below are optional
                 .resourceName("resourceName")
                 .value("value")
                 .build()))
         .platformArn("platformArn")
         .solutionStackName("solutionStackName")
         .tags(List.of(CfnTag.builder()
                 .key("key")
                 .value("value")
                 .build()))
         .templateName("templateName")
         .tier(TierProperty.builder()
                 .name("name")
                 .type("type")
                 .version("version")
                 .build())
         .versionLabel("versionLabel")
         .build();
 

See Also:
  • Field Details

    • CFN_RESOURCE_TYPE_NAME

      @Stability(Stable) public static final String CFN_RESOURCE_TYPE_NAME
      The CloudFormation resource type name for this resource class.
  • Constructor Details

    • CfnEnvironment

      protected CfnEnvironment(software.amazon.jsii.JsiiObjectRef objRef)
    • CfnEnvironment

      protected CfnEnvironment(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
    • CfnEnvironment

      @Stability(Stable) public CfnEnvironment(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnEnvironmentProps props)
      Parameters:
      scope - Scope in which this resource is defined. This parameter is required.
      id - Construct identifier for this resource (unique in its scope). This parameter is required.
      props - Resource properties. This parameter is required.
  • Method Details

    • inspect

      @Stability(Stable) public void inspect(@NotNull TreeInspector inspector)
      Examines the CloudFormation resource and discloses attributes.

      Specified by:
      inspect in interface IInspectable
      Parameters:
      inspector - tree inspector to collect and process attributes. This parameter is required.
    • renderProperties

      @Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String,Object> props)
      Overrides:
      renderProperties in class CfnResource
      Parameters:
      props - This parameter is required.
    • getAttrEndpointUrl

      @Stability(Stable) @NotNull public String getAttrEndpointUrl()
      For load-balanced, autoscaling environments, the URL to the load balancer. For single-instance environments, the IP address of the instance.

      Example load balancer URL:

      Example instance IP address:

      192.0.2.0

    • getCfnProperties

      @Stability(Stable) @NotNull protected Map<String,Object> getCfnProperties()
      Overrides:
      getCfnProperties in class CfnResource
    • getTags

      @Stability(Stable) @NotNull public TagManager getTags()
      Tag Manager which manages the tags for this resource.
      Specified by:
      getTags in interface ITaggable
    • getApplicationName

      @Stability(Stable) @NotNull public String getApplicationName()
      The name of the application that is associated with this environment.
    • setApplicationName

      @Stability(Stable) public void setApplicationName(@NotNull String value)
      The name of the application that is associated with this environment.
    • getCnamePrefix

      @Stability(Stable) @Nullable public String getCnamePrefix()
      If specified, the environment attempts to use this value as the prefix for the CNAME in your Elastic Beanstalk environment URL.
    • setCnamePrefix

      @Stability(Stable) public void setCnamePrefix(@Nullable String value)
      If specified, the environment attempts to use this value as the prefix for the CNAME in your Elastic Beanstalk environment URL.
    • getDescription

      @Stability(Stable) @Nullable public String getDescription()
      Your description for this environment.
    • setDescription

      @Stability(Stable) public void setDescription(@Nullable String value)
      Your description for this environment.
    • getEnvironmentName

      @Stability(Stable) @Nullable public String getEnvironmentName()
      A unique name for the environment.
    • setEnvironmentName

      @Stability(Stable) public void setEnvironmentName(@Nullable String value)
      A unique name for the environment.
    • getOperationsRole

      @Stability(Stable) @Nullable public String getOperationsRole()

      The operations role feature of AWS Elastic Beanstalk is in beta release and is subject to change.

    • setOperationsRole

      @Stability(Stable) public void setOperationsRole(@Nullable String value)

      The operations role feature of AWS Elastic Beanstalk is in beta release and is subject to change.

    • getOptionSettings

      @Stability(Stable) @Nullable public Object getOptionSettings()
      Key-value pairs defining configuration options for this environment, such as the instance type.
    • setOptionSettings

      @Stability(Stable) public void setOptionSettings(@Nullable IResolvable value)
      Key-value pairs defining configuration options for this environment, such as the instance type.
    • setOptionSettings

      @Stability(Stable) public void setOptionSettings(@Nullable List<Object> value)
      Key-value pairs defining configuration options for this environment, such as the instance type.
    • getPlatformArn

      @Stability(Stable) @Nullable public String getPlatformArn()
      The Amazon Resource Name (ARN) of the custom platform to use with the environment.
    • setPlatformArn

      @Stability(Stable) public void setPlatformArn(@Nullable String value)
      The Amazon Resource Name (ARN) of the custom platform to use with the environment.
    • getSolutionStackName

      @Stability(Stable) @Nullable public String getSolutionStackName()
      The name of an Elastic Beanstalk solution stack (platform version) to use with the environment.
    • setSolutionStackName

      @Stability(Stable) public void setSolutionStackName(@Nullable String value)
      The name of an Elastic Beanstalk solution stack (platform version) to use with the environment.
    • getTagsRaw

      @Stability(Stable) @Nullable public List<CfnTag> getTagsRaw()
      Specifies the tags applied to resources in the environment.
    • setTagsRaw

      @Stability(Stable) public void setTagsRaw(@Nullable List<CfnTag> value)
      Specifies the tags applied to resources in the environment.
    • getTemplateName

      @Stability(Stable) @Nullable public String getTemplateName()
      The name of the Elastic Beanstalk configuration template to use with the environment.
    • setTemplateName

      @Stability(Stable) public void setTemplateName(@Nullable String value)
      The name of the Elastic Beanstalk configuration template to use with the environment.
    • getTier

      @Stability(Stable) @Nullable public Object getTier()
      Specifies the tier to use in creating this environment.
    • setTier

      @Stability(Stable) public void setTier(@Nullable IResolvable value)
      Specifies the tier to use in creating this environment.
    • setTier

      @Stability(Stable) public void setTier(@Nullable CfnEnvironment.TierProperty value)
      Specifies the tier to use in creating this environment.
    • getVersionLabel

      @Stability(Stable) @Nullable public String getVersionLabel()
      The name of the application version to deploy.
    • setVersionLabel

      @Stability(Stable) public void setVersionLabel(@Nullable String value)
      The name of the application version to deploy.