View a markdown version of this page

AWS::AmplifyGen3::App EnvironmentVariable - Amazon CloudFormation
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China (PDF).

This is the new Amazon CloudFormation Template Reference Guide. Please update your bookmarks and links. For help getting started with CloudFormation, see the Amazon CloudFormation User Guide.

AWS::AmplifyGen3::App EnvironmentVariable

An environment variable to set.

Syntax

To declare this entity in your Amazon CloudFormation template, use the following syntax:

JSON

{ "Comment" : String, "Key" : String, "Scope" : String, "Type" : String, "Value" : String }

YAML

Comment: String Key: String Scope: String Type: String Value: String

Properties

Comment

An optional comment describing the environment variable.

Required: No

Type: String

Minimum: 0

Maximum: 1024

Update requires: No interruption

Key

The key of the environment variable.

Required: Yes

Type: String

Pattern: ^[a-zA-Z]([a-zA-Z0-9_])*$

Minimum: 1

Maximum: 128

Update requires: No interruption

Scope

The scope where the environment variable is available. Valid values:

  • ALL: The variable is available to the build and the runtime.

  • BACKEND: The variable is available only to the app's backend, not to the build or the runtime.

The default is ALL.

Required: No

Type: String

Allowed values: ALL | BACKEND

Update requires: No interruption

Type

The type of the environment variable. Valid values:

  • PLAINTEXT: The value is returned when you read the variable.

  • SENSITIVE: The value is omitted when you read the variable.

Required: Yes

Type: String

Allowed values: PLAINTEXT | SENSITIVE

Update requires: No interruption

Value

The value of the environment variable.

Required: No

Type: String

Minimum: 1

Maximum: 4096

Update requires: No interruption