The AWS SDK for JavaScript v2 has reached end-of-support.
We recommend that you migrate to AWS SDK for JavaScript v3. For additional details and information on how to migrate, please refer to the announcement.

Class: AWS.CodeDeploy

Inherits:
AWS.Service show all
Identifier:
codedeploy
API Version:
2014-10-06
Defined in:
(unknown)

Overview

Constructs a service interface object. Each API operation is exposed as a function on service.

Service Description

CodeDeploy is a deployment service that automates application deployments to Amazon EC2 instances, on-premises instances running in your own facility, serverless Lambda functions, or applications in an Amazon ECS service.

You can deploy a nearly unlimited variety of application content, such as an updated Lambda function, updated applications in an Amazon ECS service, code, web and configuration files, executables, packages, scripts, multimedia files, and so on. CodeDeploy can deploy application content stored in Amazon S3 buckets, GitHub repositories, or Bitbucket repositories. You do not need to make changes to your existing code before you can use CodeDeploy.

CodeDeploy makes it easier for you to rapidly release new features, helps you avoid downtime during application deployment, and handles the complexity of updating your applications, without many of the risks associated with error-prone manual deployments.

CodeDeploy Components

Use the information in this guide to help you work with the following CodeDeploy components:

  • Application: A name that uniquely identifies the application you want to deploy. CodeDeploy uses this name, which functions as a container, to ensure the correct combination of revision, deployment configuration, and deployment group are referenced during a deployment.

  • Deployment group: A set of individual instances, CodeDeploy Lambda deployment configuration settings, or an Amazon ECS service and network details. A Lambda deployment group specifies how to route traffic to a new version of a Lambda function. An Amazon ECS deployment group specifies the service created in Amazon ECS to deploy, a load balancer, and a listener to reroute production traffic to an updated containerized application. An Amazon EC2/On-premises deployment group contains individually tagged instances, Amazon EC2 instances in Amazon EC2 Auto Scaling groups, or both. All deployment groups can specify optional trigger, alarm, and rollback settings.

  • Deployment configuration: A set of deployment rules and deployment success and failure conditions used by CodeDeploy during a deployment.

  • Deployment: The process and the components used when updating a Lambda function, a containerized application in an Amazon ECS service, or of installing content on one or more instances.

  • Application revisions: For an Lambda deployment, this is an AppSpec file that specifies the Lambda function to be updated and one or more functions to validate deployment lifecycle events. For an Amazon ECS deployment, this is an AppSpec file that specifies the Amazon ECS task definition, container, and port where production traffic is rerouted. For an EC2/On-premises deployment, this is an archive file that contains source content—source code, webpages, executable files, and deployment scripts—along with an AppSpec file. Revisions are stored in Amazon S3 buckets or GitHub repositories. For Amazon S3, a revision is uniquely identified by its Amazon S3 object key and its ETag, version, or both. For GitHub, a revision is uniquely identified by its commit ID.

This guide also contains information to help you get details about the instances in your deployments, to make on-premises instances available for CodeDeploy deployments, to get details about a Lambda function deployment, and to get details about Amazon ECS service deployments.

CodeDeploy Information Resources

Sending a Request Using CodeDeploy

var codedeploy = new AWS.CodeDeploy();
codedeploy.batchGetDeploymentTargets(params, function (err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Locking the API Version

In order to ensure that the CodeDeploy object uses this specific API, you can construct the object by passing the apiVersion option to the constructor:

var codedeploy = new AWS.CodeDeploy({apiVersion: '2014-10-06'});

You can also set the API version globally in AWS.config.apiVersions using the codedeploy service identifier:

AWS.config.apiVersions = {
  codedeploy: '2014-10-06',
  // other service API versions
};

var codedeploy = new AWS.CodeDeploy();

Version:

  • 2014-10-06

Waiter Resource States

This service supports a list of resource states that can be polled using the waitFor() method. The resource states are:

deploymentSuccessful

Constructor Summary collapse

Property Summary collapse

Properties inherited from AWS.Service

apiVersions

Method Summary collapse

Methods inherited from AWS.Service

makeRequest, makeUnauthenticatedRequest, setupRequestListeners, defineService

Constructor Details

new AWS.CodeDeploy(options = {}) ⇒ Object

Constructs a service object. This object has one method for each API operation.

Examples:

Constructing a CodeDeploy object

var codedeploy = new AWS.CodeDeploy({apiVersion: '2014-10-06'});

Options Hash (options):

  • params (map)

    An optional map of parameters to bind to every request sent by this service object. For more information on bound parameters, see "Working with Services" in the Getting Started Guide.

  • endpoint (String|AWS.Endpoint)

    The endpoint URI to send requests to. The default endpoint is built from the configured region. The endpoint should be a string like 'https://{service}.{region}.amazonaws.com' or an Endpoint object.

  • accessKeyId (String)

    your AWS access key ID.

  • secretAccessKey (String)

    your AWS secret access key.

  • sessionToken (AWS.Credentials)

    the optional AWS session token to sign requests with.

  • credentials (AWS.Credentials)

    the AWS credentials to sign requests with. You can either specify this object, or specify the accessKeyId and secretAccessKey options directly.

  • credentialProvider (AWS.CredentialProviderChain)

    the provider chain used to resolve credentials if no static credentials property is set.

  • region (String)

    the region to send service requests to. See AWS.CodeDeploy.region for more information.

  • maxRetries (Integer)

    the maximum amount of retries to attempt with a request. See AWS.CodeDeploy.maxRetries for more information.

  • maxRedirects (Integer)

    the maximum amount of redirects to follow with a request. See AWS.CodeDeploy.maxRedirects for more information.

  • sslEnabled (Boolean)

    whether to enable SSL for requests.

  • paramValidation (Boolean|map)

    whether input parameters should be validated against the operation description before sending the request. Defaults to true. Pass a map to enable any of the following specific validation features:

    • min [Boolean] — Validates that a value meets the min constraint. This is enabled by default when paramValidation is set to true.
    • max [Boolean] — Validates that a value meets the max constraint.
    • pattern [Boolean] — Validates that a string value matches a regular expression.
    • enum [Boolean] — Validates that a string value matches one of the allowable enum values.
  • computeChecksums (Boolean)

    whether to compute checksums for payload bodies when the service accepts it (currently supported in S3 only)

  • convertResponseTypes (Boolean)

    whether types are converted when parsing response data. Currently only supported for JSON based services. Turning this off may improve performance on large response payloads. Defaults to true.

  • correctClockSkew (Boolean)

    whether to apply a clock skew correction and retry requests that fail because of an skewed client clock. Defaults to false.

  • s3ForcePathStyle (Boolean)

    whether to force path style URLs for S3 objects.

  • s3BucketEndpoint (Boolean)

    whether the provided endpoint addresses an individual bucket (false if it addresses the root API endpoint). Note that setting this configuration option requires an endpoint to be provided explicitly to the service constructor.

  • s3DisableBodySigning (Boolean)

    whether S3 body signing should be disabled when using signature version v4. Body signing can only be disabled when using https. Defaults to true.

  • s3UsEast1RegionalEndpoint ('legacy'|'regional')

    when region is set to 'us-east-1', whether to send s3 request to global endpoints or 'us-east-1' regional endpoints. This config is only applicable to S3 client. Defaults to legacy

  • s3UseArnRegion (Boolean)

    whether to override the request region with the region inferred from requested resource's ARN. Only available for S3 buckets Defaults to true

  • retryDelayOptions (map)

    A set of options to configure the retry delay on retryable errors. Currently supported options are:

    • base [Integer] — The base number of milliseconds to use in the exponential backoff for operation retries. Defaults to 100 ms for all services except DynamoDB, where it defaults to 50ms.
    • customBackoff [function] — A custom function that accepts a retry count and error and returns the amount of time to delay in milliseconds. If the result is a non-zero negative value, no further retry attempts will be made. The base option will be ignored if this option is supplied. The function is only called for retryable errors.
  • httpOptions (map)

    A set of options to pass to the low-level HTTP request. Currently supported options are:

    • proxy [String] — the URL to proxy requests through
    • agent [http.Agent, https.Agent] — the Agent object to perform HTTP requests with. Used for connection pooling. Defaults to the global agent (http.globalAgent) for non-SSL connections. Note that for SSL connections, a special Agent object is used in order to enable peer certificate verification. This feature is only available in the Node.js environment.
    • connectTimeout [Integer] — Sets the socket to timeout after failing to establish a connection with the server after connectTimeout milliseconds. This timeout has no effect once a socket connection has been established.
    • timeout [Integer] — Sets the socket to timeout after timeout milliseconds of inactivity on the socket. Defaults to two minutes (120000).
    • xhrAsync [Boolean] — Whether the SDK will send asynchronous HTTP requests. Used in the browser environment only. Set to false to send requests synchronously. Defaults to true (async on).
    • xhrWithCredentials [Boolean] — Sets the "withCredentials" property of an XMLHttpRequest object. Used in the browser environment only. Defaults to false.
  • apiVersion (String, Date)

    a String in YYYY-MM-DD format (or a date) that represents the latest possible API version that can be used in all services (unless overridden by apiVersions). Specify 'latest' to use the latest possible version.

  • apiVersions (map<String, String|Date>)

    a map of service identifiers (the lowercase service class name) with the API version to use when instantiating a service. Specify 'latest' for each individual that can use the latest available version.

  • logger (#write, #log)

    an object that responds to .write() (like a stream) or .log() (like the console object) in order to log information about requests

  • systemClockOffset (Number)

    an offset value in milliseconds to apply to all signing times. Use this to compensate for clock skew when your system may be out of sync with the service time. Note that this configuration option can only be applied to the global AWS.config object and cannot be overridden in service-specific configuration. Defaults to 0 milliseconds.

  • signatureVersion (String)

    the signature version to sign requests with (overriding the API configuration). Possible values are: 'v2', 'v3', 'v4'.

  • signatureCache (Boolean)

    whether the signature to sign requests with (overriding the API configuration) is cached. Only applies to the signature version 'v4'. Defaults to true.

  • dynamoDbCrc32 (Boolean)

    whether to validate the CRC32 checksum of HTTP response bodies returned by DynamoDB. Default: true.

  • useAccelerateEndpoint (Boolean)

    Whether to use the S3 Transfer Acceleration endpoint with the S3 service. Default: false.

  • clientSideMonitoring (Boolean)

    whether to collect and publish this client's performance metrics of all its API requests.

  • endpointDiscoveryEnabled (Boolean|undefined)

    whether to call operations with endpoints given by service dynamically. Setting this

  • endpointCacheSize (Number)

    the size of the global cache storing endpoints from endpoint discovery operations. Once endpoint cache is created, updating this setting cannot change existing cache size. Defaults to 1000

  • hostPrefixEnabled (Boolean)

    whether to marshal request parameters to the prefix of hostname. Defaults to true.

  • stsRegionalEndpoints ('legacy'|'regional')

    whether to send sts request to global endpoints or regional endpoints. Defaults to 'legacy'.

  • useFipsEndpoint (Boolean)

    Enables FIPS compatible endpoints. Defaults to false.

  • useDualstackEndpoint (Boolean)

    Enables IPv6 dualstack endpoint. Defaults to false.

Property Details

endpointAWS.Endpoint (readwrite)

Returns an Endpoint object representing the endpoint URL for service requests.

Returns:

  • (AWS.Endpoint)

    an Endpoint object representing the endpoint URL for service requests.

Method Details

addTagsToOnPremisesInstances(params = {}, callback) ⇒ AWS.Request

Adds tags to on-premises instances.

Service Reference:

Examples:

Calling the addTagsToOnPremisesInstances operation

var params = {
  instanceNames: [ /* required */
    'STRING_VALUE',
    /* more items */
  ],
  tags: [ /* required */
    {
      Key: 'STRING_VALUE',
      Value: 'STRING_VALUE'
    },
    /* more items */
  ]
};
codedeploy.addTagsToOnPremisesInstances(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • tags — (Array<map>)

      The tag key-value pairs to add to the on-premises instances.

      Keys and values are both required. Keys cannot be null or empty strings. Value-only tags are not allowed.

      • Key — (String)

        The tag's key.

      • Value — (String)

        The tag's value.

    • instanceNames — (Array<String>)

      The names of the on-premises instances to which to add tags.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

batchGetApplicationRevisions(params = {}, callback) ⇒ AWS.Request

Gets information about one or more application revisions. The maximum number of application revisions that can be returned is 25.

Service Reference:

Examples:

Calling the batchGetApplicationRevisions operation

var params = {
  applicationName: 'STRING_VALUE', /* required */
  revisions: [ /* required */
    {
      appSpecContent: {
        content: 'STRING_VALUE',
        sha256: 'STRING_VALUE'
      },
      gitHubLocation: {
        commitId: 'STRING_VALUE',
        repository: 'STRING_VALUE'
      },
      revisionType: S3 | GitHub | String | AppSpecContent,
      s3Location: {
        bucket: 'STRING_VALUE',
        bundleType: tar | tgz | zip | YAML | JSON,
        eTag: 'STRING_VALUE',
        key: 'STRING_VALUE',
        version: 'STRING_VALUE'
      },
      string: {
        content: 'STRING_VALUE',
        sha256: 'STRING_VALUE'
      }
    },
    /* more items */
  ]
};
codedeploy.batchGetApplicationRevisions(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • applicationName — (String)

      The name of an CodeDeploy application about which to get revision information.

    • revisions — (Array<map>)

      An array of RevisionLocation objects that specify information to get about the application revisions, including type and location. The maximum number of RevisionLocation objects you can specify is 25.

      • revisionType — (String)

        The type of application revision:

        • S3: An application revision stored in Amazon S3.

        • GitHub: An application revision stored in GitHub (EC2/On-premises deployments only).

        • String: A YAML-formatted or JSON-formatted string (Lambda deployments only).

        • AppSpecContent: An AppSpecContent object that contains the contents of an AppSpec file for an Lambda or Amazon ECS deployment. The content is formatted as JSON or YAML stored as a RawString.

        Possible values include:
        • "S3"
        • "GitHub"
        • "String"
        • "AppSpecContent"
      • s3Location — (map)

        Information about the location of a revision stored in Amazon S3.

        • bucket — (String)

          The name of the Amazon S3 bucket where the application revision is stored.

        • key — (String)

          The name of the Amazon S3 object that represents the bundled artifacts for the application revision.

        • bundleType — (String)

          The file type of the application revision. Must be one of the following:

          • tar: A tar archive file.

          • tgz: A compressed tar archive file.

          • zip: A zip archive file.

          • YAML: A YAML-formatted file.

          • JSON: A JSON-formatted file.

          Possible values include:
          • "tar"
          • "tgz"
          • "zip"
          • "YAML"
          • "JSON"
        • version — (String)

          A specific version of the Amazon S3 object that represents the bundled artifacts for the application revision.

          If the version is not specified, the system uses the most recent version by default.

        • eTag — (String)

          The ETag of the Amazon S3 object that represents the bundled artifacts for the application revision.

          If the ETag is not specified as an input parameter, ETag validation of the object is skipped.

      • gitHubLocation — (map)

        Information about the location of application artifacts stored in GitHub.

        • repository — (String)

          The GitHub account and repository pair that stores a reference to the commit that represents the bundled artifacts for the application revision.

          Specified as account/repository.

        • commitId — (String)

          The SHA1 commit ID of the GitHub commit that represents the bundled artifacts for the application revision.

      • string — (map)

        Information about the location of an Lambda deployment revision stored as a RawString.

        • content — (String)

          The YAML-formatted or JSON-formatted revision string. It includes information about which Lambda function to update and optional Lambda functions that validate deployment lifecycle events.

        • sha256 — (String)

          The SHA256 hash value of the revision content.

      • appSpecContent — (map)

        The content of an AppSpec file for an Lambda or Amazon ECS deployment. The content is formatted as JSON or YAML and stored as a RawString.

        • content — (String)

          The YAML-formatted or JSON-formatted revision string.

          For an Lambda deployment, the content includes a Lambda function name, the alias for its original version, and the alias for its replacement version. The deployment shifts traffic from the original version of the Lambda function to the replacement version.

          For an Amazon ECS deployment, the content includes the task name, information about the load balancer that serves traffic to the container, and more.

          For both types of deployments, the content can specify Lambda functions that run at specified hooks, such as BeforeInstall, during a deployment.

        • sha256 — (String)

          The SHA256 hash value of the revision content.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • applicationName — (String)

        The name of the application that corresponds to the revisions.

      • errorMessage — (String)

        Information about errors that might have occurred during the API call.

      • revisions — (Array<map>)

        Additional information about the revisions, including the type and location.

        • revisionLocation — (map)

          Information about the location and type of an application revision.

          • revisionType — (String)

            The type of application revision:

            • S3: An application revision stored in Amazon S3.

            • GitHub: An application revision stored in GitHub (EC2/On-premises deployments only).

            • String: A YAML-formatted or JSON-formatted string (Lambda deployments only).

            • AppSpecContent: An AppSpecContent object that contains the contents of an AppSpec file for an Lambda or Amazon ECS deployment. The content is formatted as JSON or YAML stored as a RawString.

            Possible values include:
            • "S3"
            • "GitHub"
            • "String"
            • "AppSpecContent"
          • s3Location — (map)

            Information about the location of a revision stored in Amazon S3.

            • bucket — (String)

              The name of the Amazon S3 bucket where the application revision is stored.

            • key — (String)

              The name of the Amazon S3 object that represents the bundled artifacts for the application revision.

            • bundleType — (String)

              The file type of the application revision. Must be one of the following:

              • tar: A tar archive file.

              • tgz: A compressed tar archive file.

              • zip: A zip archive file.

              • YAML: A YAML-formatted file.

              • JSON: A JSON-formatted file.

              Possible values include:
              • "tar"
              • "tgz"
              • "zip"
              • "YAML"
              • "JSON"
            • version — (String)

              A specific version of the Amazon S3 object that represents the bundled artifacts for the application revision.

              If the version is not specified, the system uses the most recent version by default.

            • eTag — (String)

              The ETag of the Amazon S3 object that represents the bundled artifacts for the application revision.

              If the ETag is not specified as an input parameter, ETag validation of the object is skipped.

          • gitHubLocation — (map)

            Information about the location of application artifacts stored in GitHub.

            • repository — (String)

              The GitHub account and repository pair that stores a reference to the commit that represents the bundled artifacts for the application revision.

              Specified as account/repository.

            • commitId — (String)

              The SHA1 commit ID of the GitHub commit that represents the bundled artifacts for the application revision.

          • string — (map)

            Information about the location of an Lambda deployment revision stored as a RawString.

            • content — (String)

              The YAML-formatted or JSON-formatted revision string. It includes information about which Lambda function to update and optional Lambda functions that validate deployment lifecycle events.

            • sha256 — (String)

              The SHA256 hash value of the revision content.

          • appSpecContent — (map)

            The content of an AppSpec file for an Lambda or Amazon ECS deployment. The content is formatted as JSON or YAML and stored as a RawString.

            • content — (String)

              The YAML-formatted or JSON-formatted revision string.

              For an Lambda deployment, the content includes a Lambda function name, the alias for its original version, and the alias for its replacement version. The deployment shifts traffic from the original version of the Lambda function to the replacement version.

              For an Amazon ECS deployment, the content includes the task name, information about the load balancer that serves traffic to the container, and more.

              For both types of deployments, the content can specify Lambda functions that run at specified hooks, such as BeforeInstall, during a deployment.

            • sha256 — (String)

              The SHA256 hash value of the revision content.

        • genericRevisionInfo — (map)

          Information about an application revision, including usage details and associated deployment groups.

          • description — (String)

            A comment about the revision.

          • deploymentGroups — (Array<String>)

            The deployment groups for which this is the current target revision.

          • firstUsedTime — (Date)

            When the revision was first used by CodeDeploy.

          • lastUsedTime — (Date)

            When the revision was last used by CodeDeploy.

          • registerTime — (Date)

            When the revision was registered with CodeDeploy.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

batchGetApplications(params = {}, callback) ⇒ AWS.Request

Gets information about one or more applications. The maximum number of applications that can be returned is 100.

Service Reference:

Examples:

Calling the batchGetApplications operation

var params = {
  applicationNames: [ /* required */
    'STRING_VALUE',
    /* more items */
  ]
};
codedeploy.batchGetApplications(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • applicationNames — (Array<String>)

      A list of application names separated by spaces. The maximum number of application names you can specify is 100.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • applicationsInfo — (Array<map>)

        Information about the applications.

        • applicationId — (String)

          The application ID.

        • applicationName — (String)

          The application name.

        • createTime — (Date)

          The time at which the application was created.

        • linkedToGitHub — (Boolean)

          True if the user has authenticated with GitHub for the specified application. Otherwise, false.

        • gitHubAccountName — (String)

          The name for a connection to a GitHub account.

        • computePlatform — (String)

          The destination platform type for deployment of the application (Lambda or Server).

          Possible values include:
          • "Server"
          • "Lambda"
          • "ECS"

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

batchGetDeploymentGroups(params = {}, callback) ⇒ AWS.Request

Gets information about one or more deployment groups.

Service Reference:

Examples:

Calling the batchGetDeploymentGroups operation

var params = {
  applicationName: 'STRING_VALUE', /* required */
  deploymentGroupNames: [ /* required */
    'STRING_VALUE',
    /* more items */
  ]
};
codedeploy.batchGetDeploymentGroups(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • applicationName — (String)

      The name of an CodeDeploy application associated with the applicable user or Amazon Web Services account.

    • deploymentGroupNames — (Array<String>)

      The names of the deployment groups.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • deploymentGroupsInfo — (Array<map>)

        Information about the deployment groups.

        • applicationName — (String)

          The application name.

        • deploymentGroupId — (String)

          The deployment group ID.

        • deploymentGroupName — (String)

          The deployment group name.

        • deploymentConfigName — (String)

          The deployment configuration name.

        • ec2TagFilters — (Array<map>)

          The Amazon EC2 tags on which to filter. The deployment group includes EC2 instances with any of the specified tags.

          • Key — (String)

            The tag filter key.

          • Value — (String)

            The tag filter value.

          • Type — (String)

            The tag filter type:

            • KEY_ONLY: Key only.

            • VALUE_ONLY: Value only.

            • KEY_AND_VALUE: Key and value.

            Possible values include:
            • "KEY_ONLY"
            • "VALUE_ONLY"
            • "KEY_AND_VALUE"
        • onPremisesInstanceTagFilters — (Array<map>)

          The on-premises instance tags on which to filter. The deployment group includes on-premises instances with any of the specified tags.

          • Key — (String)

            The on-premises instance tag filter key.

          • Value — (String)

            The on-premises instance tag filter value.

          • Type — (String)

            The on-premises instance tag filter type:

            • KEY_ONLY: Key only.

            • VALUE_ONLY: Value only.

            • KEY_AND_VALUE: Key and value.

            Possible values include:
            • "KEY_ONLY"
            • "VALUE_ONLY"
            • "KEY_AND_VALUE"
        • autoScalingGroups — (Array<map>)

          A list of associated Auto Scaling groups.

        • serviceRoleArn — (String)

          A service role Amazon Resource Name (ARN) that grants CodeDeploy permission to make calls to Amazon Web Services services on your behalf. For more information, see Create a Service Role for CodeDeploy in the CodeDeploy User Guide.

        • targetRevision — (map)

          Information about the deployment group's target revision, including type and location.

          • revisionType — (String)

            The type of application revision:

            • S3: An application revision stored in Amazon S3.

            • GitHub: An application revision stored in GitHub (EC2/On-premises deployments only).

            • String: A YAML-formatted or JSON-formatted string (Lambda deployments only).

            • AppSpecContent: An AppSpecContent object that contains the contents of an AppSpec file for an Lambda or Amazon ECS deployment. The content is formatted as JSON or YAML stored as a RawString.

            Possible values include:
            • "S3"
            • "GitHub"
            • "String"
            • "AppSpecContent"
          • s3Location — (map)

            Information about the location of a revision stored in Amazon S3.

            • bucket — (String)

              The name of the Amazon S3 bucket where the application revision is stored.

            • key — (String)

              The name of the Amazon S3 object that represents the bundled artifacts for the application revision.

            • bundleType — (String)

              The file type of the application revision. Must be one of the following:

              • tar: A tar archive file.

              • tgz: A compressed tar archive file.

              • zip: A zip archive file.

              • YAML: A YAML-formatted file.

              • JSON: A JSON-formatted file.

              Possible values include:
              • "tar"
              • "tgz"
              • "zip"
              • "YAML"
              • "JSON"
            • version — (String)

              A specific version of the Amazon S3 object that represents the bundled artifacts for the application revision.

              If the version is not specified, the system uses the most recent version by default.

            • eTag — (String)

              The ETag of the Amazon S3 object that represents the bundled artifacts for the application revision.

              If the ETag is not specified as an input parameter, ETag validation of the object is skipped.

          • gitHubLocation — (map)

            Information about the location of application artifacts stored in GitHub.

            • repository — (String)

              The GitHub account and repository pair that stores a reference to the commit that represents the bundled artifacts for the application revision.

              Specified as account/repository.

            • commitId — (String)

              The SHA1 commit ID of the GitHub commit that represents the bundled artifacts for the application revision.

          • string — (map)

            Information about the location of an Lambda deployment revision stored as a RawString.

            • content — (String)

              The YAML-formatted or JSON-formatted revision string. It includes information about which Lambda function to update and optional Lambda functions that validate deployment lifecycle events.

            • sha256 — (String)

              The SHA256 hash value of the revision content.

          • appSpecContent — (map)

            The content of an AppSpec file for an Lambda or Amazon ECS deployment. The content is formatted as JSON or YAML and stored as a RawString.

            • content — (String)

              The YAML-formatted or JSON-formatted revision string.

              For an Lambda deployment, the content includes a Lambda function name, the alias for its original version, and the alias for its replacement version. The deployment shifts traffic from the original version of the Lambda function to the replacement version.

              For an Amazon ECS deployment, the content includes the task name, information about the load balancer that serves traffic to the container, and more.

              For both types of deployments, the content can specify Lambda functions that run at specified hooks, such as BeforeInstall, during a deployment.

            • sha256 — (String)

              The SHA256 hash value of the revision content.

        • triggerConfigurations — (Array<map>)

          Information about triggers associated with the deployment group.

          • triggerName — (String)

            The name of the notification trigger.

          • triggerTargetArn — (String)

            The Amazon Resource Name (ARN) of the Amazon Simple Notification Service topic through which notifications about deployment or instance events are sent.

          • triggerEvents — (Array<String>)

            The event type or types for which notifications are triggered.

        • alarmConfiguration — (map)

          A list of alarms associated with the deployment group.

          • enabled — (Boolean)

            Indicates whether the alarm configuration is enabled.

          • ignorePollAlarmFailure — (Boolean)

            Indicates whether a deployment should continue if information about the current state of alarms cannot be retrieved from Amazon CloudWatch. The default value is false.

            • true: The deployment proceeds even if alarm status information can't be retrieved from Amazon CloudWatch.

            • false: The deployment stops if alarm status information can't be retrieved from Amazon CloudWatch.

          • alarms — (Array<map>)

            A list of alarms configured for the deployment or deployment group. A maximum of 10 alarms can be added.

            • name — (String)

              The name of the alarm. Maximum length is 255 characters. Each alarm name can be used only once in a list of alarms.

        • autoRollbackConfiguration — (map)

          Information about the automatic rollback configuration associated with the deployment group.

          • enabled — (Boolean)

            Indicates whether a defined automatic rollback configuration is currently enabled.

          • events — (Array<String>)

            The event type or types that trigger a rollback.

        • deploymentStyle — (map)

          Information about the type of deployment, either in-place or blue/green, you want to run and whether to route deployment traffic behind a load balancer.

          • deploymentType — (String)

            Indicates whether to run an in-place deployment or a blue/green deployment.

            Possible values include:
            • "IN_PLACE"
            • "BLUE_GREEN"
          • deploymentOption — (String)

            Indicates whether to route deployment traffic behind a load balancer.

            Possible values include:
            • "WITH_TRAFFIC_CONTROL"
            • "WITHOUT_TRAFFIC_CONTROL"
        • outdatedInstancesStrategy — (String)

          Indicates what happens when new Amazon EC2 instances are launched mid-deployment and do not receive the deployed application revision.

          If this option is set to UPDATE or is unspecified, CodeDeploy initiates one or more 'auto-update outdated instances' deployments to apply the deployed application revision to the new Amazon EC2 instances.

          If this option is set to IGNORE, CodeDeploy does not initiate a deployment to update the new Amazon EC2 instances. This may result in instances having different revisions.

          Possible values include:
          • "UPDATE"
          • "IGNORE"
        • blueGreenDeploymentConfiguration — (map)

          Information about blue/green deployment options for a deployment group.

          • terminateBlueInstancesOnDeploymentSuccess — (map)

            Information about whether to terminate instances in the original fleet during a blue/green deployment.

            • action — (String)

              The action to take on instances in the original environment after a successful blue/green deployment.

              • TERMINATE: Instances are terminated after a specified wait time.

              • KEEP_ALIVE: Instances are left running after they are deregistered from the load balancer and removed from the deployment group.

              Possible values include:
              • "TERMINATE"
              • "KEEP_ALIVE"
            • terminationWaitTimeInMinutes — (Integer)

              For an Amazon EC2 deployment, the number of minutes to wait after a successful blue/green deployment before terminating instances from the original environment.

              For an Amazon ECS deployment, the number of minutes before deleting the original (blue) task set. During an Amazon ECS deployment, CodeDeploy shifts traffic from the original (blue) task set to a replacement (green) task set.

              The maximum setting is 2880 minutes (2 days).

          • deploymentReadyOption — (map)

            Information about the action to take when newly provisioned instances are ready to receive traffic in a blue/green deployment.

            • actionOnTimeout — (String)

              Information about when to reroute traffic from an original environment to a replacement environment in a blue/green deployment.

              • CONTINUE_DEPLOYMENT: Register new instances with the load balancer immediately after the new application revision is installed on the instances in the replacement environment.

              • STOP_DEPLOYMENT: Do not register new instances with a load balancer unless traffic rerouting is started using ContinueDeployment. If traffic rerouting is not started before the end of the specified wait period, the deployment status is changed to Stopped.

              Possible values include:
              • "CONTINUE_DEPLOYMENT"
              • "STOP_DEPLOYMENT"
            • waitTimeInMinutes — (Integer)

              The number of minutes to wait before the status of a blue/green deployment is changed to Stopped if rerouting is not started manually. Applies only to the STOP_DEPLOYMENT option for actionOnTimeout.

          • greenFleetProvisioningOption — (map)

            Information about how instances are provisioned for a replacement environment in a blue/green deployment.

            • action — (String)

              The method used to add instances to a replacement environment.

              • DISCOVER_EXISTING: Use instances that already exist or will be created manually.

              • COPY_AUTO_SCALING_GROUP: Use settings from a specified Auto Scaling group to define and create instances in a new Auto Scaling group.

              Possible values include:
              • "DISCOVER_EXISTING"
              • "COPY_AUTO_SCALING_GROUP"
        • loadBalancerInfo — (map)

          Information about the load balancer to use in a deployment.

          • elbInfoList — (Array<map>)

            An array that contains information about the load balancers to use for load balancing in a deployment. If you're using Classic Load Balancers, specify those load balancers in this array.

            Note: You can add up to 10 load balancers to the array.
            Note: If you're using Application Load Balancers or Network Load Balancers, use the targetGroupInfoList array instead of this one.
            • name — (String)

              For blue/green deployments, the name of the Classic Load Balancer that is used to route traffic from original instances to replacement instances in a blue/green deployment. For in-place deployments, the name of the Classic Load Balancer that instances are deregistered from so they are not serving traffic during a deployment, and then re-registered with after the deployment is complete.

          • targetGroupInfoList — (Array<map>)

            An array that contains information about the target groups to use for load balancing in a deployment. If you're using Application Load Balancers and Network Load Balancers, specify their associated target groups in this array.

            Note: You can add up to 10 target groups to the array.
            Note: If you're using Classic Load Balancers, use the elbInfoList array instead of this one.
            • name — (String)

              For blue/green deployments, the name of the target group that instances in the original environment are deregistered from, and instances in the replacement environment are registered with. For in-place deployments, the name of the target group that instances are deregistered from, so they are not serving traffic during a deployment, and then re-registered with after the deployment is complete.

          • targetGroupPairInfoList — (Array<map>)

            The target group pair information. This is an array of TargeGroupPairInfo objects with a maximum size of one.

            • targetGroups — (Array<map>)

              One pair of target groups. One is associated with the original task set. The second is associated with the task set that serves traffic after the deployment is complete.

              • name — (String)

                For blue/green deployments, the name of the target group that instances in the original environment are deregistered from, and instances in the replacement environment are registered with. For in-place deployments, the name of the target group that instances are deregistered from, so they are not serving traffic during a deployment, and then re-registered with after the deployment is complete.

            • prodTrafficRoute — (map)

              The path used by a load balancer to route production traffic when an Amazon ECS deployment is complete.

              • listenerArns — (Array<String>)

                The Amazon Resource Name (ARN) of one listener. The listener identifies the route between a target group and a load balancer. This is an array of strings with a maximum size of one.

            • testTrafficRoute — (map)

              An optional path used by a load balancer to route test traffic after an Amazon ECS deployment. Validation can occur while test traffic is served during a deployment.

              • listenerArns — (Array<String>)

                The Amazon Resource Name (ARN) of one listener. The listener identifies the route between a target group and a load balancer. This is an array of strings with a maximum size of one.

        • lastSuccessfulDeployment — (map)

          Information about the most recent successful deployment to the deployment group.

          • deploymentId — (String)

            The unique ID of a deployment.

          • status — (String)

            The status of the most recent deployment.

            Possible values include:
            • "Created"
            • "Queued"
            • "InProgress"
            • "Baking"
            • "Succeeded"
            • "Failed"
            • "Stopped"
            • "Ready"
          • endTime — (Date)

            A timestamp that indicates when the most recent deployment to the deployment group was complete.

          • createTime — (Date)

            A timestamp that indicates when the most recent deployment to the deployment group started.

        • lastAttemptedDeployment — (map)

          Information about the most recent attempted deployment to the deployment group.

          • deploymentId — (String)

            The unique ID of a deployment.

          • status — (String)

            The status of the most recent deployment.

            Possible values include:
            • "Created"
            • "Queued"
            • "InProgress"
            • "Baking"
            • "Succeeded"
            • "Failed"
            • "Stopped"
            • "Ready"
          • endTime — (Date)

            A timestamp that indicates when the most recent deployment to the deployment group was complete.

          • createTime — (Date)

            A timestamp that indicates when the most recent deployment to the deployment group started.

        • ec2TagSet — (map)

          Information about groups of tags applied to an Amazon EC2 instance. The deployment group includes only Amazon EC2 instances identified by all of the tag groups. Cannot be used in the same call as ec2TagFilters.

          • ec2TagSetList — (Array<Array<map>>)

            A list that contains other lists of Amazon EC2 instance tag groups. For an instance to be included in the deployment group, it must be identified by all of the tag groups in the list.

            • Key — (String)

              The tag filter key.

            • Value — (String)

              The tag filter value.

            • Type — (String)

              The tag filter type:

              • KEY_ONLY: Key only.

              • VALUE_ONLY: Value only.

              • KEY_AND_VALUE: Key and value.

              Possible values include:
              • "KEY_ONLY"
              • "VALUE_ONLY"
              • "KEY_AND_VALUE"
        • onPremisesTagSet — (map)

          Information about groups of tags applied to an on-premises instance. The deployment group includes only on-premises instances identified by all the tag groups. Cannot be used in the same call as onPremisesInstanceTagFilters.

          • onPremisesTagSetList — (Array<Array<map>>)

            A list that contains other lists of on-premises instance tag groups. For an instance to be included in the deployment group, it must be identified by all of the tag groups in the list.

            • Key — (String)

              The on-premises instance tag filter key.

            • Value — (String)

              The on-premises instance tag filter value.

            • Type — (String)

              The on-premises instance tag filter type:

              • KEY_ONLY: Key only.

              • VALUE_ONLY: Value only.

              • KEY_AND_VALUE: Key and value.

              Possible values include:
              • "KEY_ONLY"
              • "VALUE_ONLY"
              • "KEY_AND_VALUE"
        • computePlatform — (String)

          The destination platform type for the deployment (Lambda, Server, or ECS).

          Possible values include:
          • "Server"
          • "Lambda"
          • "ECS"
        • ecsServices — (Array<map>)

          The target Amazon ECS services in the deployment group. This applies only to deployment groups that use the Amazon ECS compute platform. A target Amazon ECS service is specified as an Amazon ECS cluster and service name pair using the format <clustername>:<servicename>.

          • serviceName — (String)

            The name of the target Amazon ECS service.

          • clusterName — (String)

            The name of the cluster that the Amazon ECS service is associated with.

        • terminationHookEnabled — (Boolean)

          Indicates whether the deployment group was configured to have CodeDeploy install a termination hook into an Auto Scaling group.

          For more information about the termination hook, see How Amazon EC2 Auto Scaling works with CodeDeploy in the CodeDeploy User Guide.

      • errorMessage — (String)

        Information about errors that might have occurred during the API call.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

batchGetDeploymentInstances(params = {}, callback) ⇒ AWS.Request

Note: This method works, but is deprecated. Use BatchGetDeploymentTargets instead.

Returns an array of one or more instances associated with a deployment. This method works with EC2/On-premises and Lambda compute platforms. The newer BatchGetDeploymentTargets works with all compute platforms. The maximum number of instances that can be returned is 25.

Service Reference:

Examples:

Calling the batchGetDeploymentInstances operation

var params = {
  deploymentId: 'STRING_VALUE', /* required */
  instanceIds: [ /* required */
    'STRING_VALUE',
    /* more items */
  ]
};
codedeploy.batchGetDeploymentInstances(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • deploymentId — (String)

      The unique ID of a deployment.

    • instanceIds — (Array<String>)

      The unique IDs of instances used in the deployment. The maximum number of instance IDs you can specify is 25.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • instancesSummary — (Array<map>)

        Information about the instance.

        • deploymentId — (String)

          The unique ID of a deployment.

        • instanceId — (String)

          The instance ID.

        • status — (String)

          The deployment status for this instance:

          • Pending: The deployment is pending for this instance.

          • In Progress: The deployment is in progress for this instance.

          • Succeeded: The deployment has succeeded for this instance.

          • Failed: The deployment has failed for this instance.

          • Skipped: The deployment has been skipped for this instance.

          • Unknown: The deployment status is unknown for this instance.

          Possible values include:
          • "Pending"
          • "InProgress"
          • "Succeeded"
          • "Failed"
          • "Skipped"
          • "Unknown"
          • "Ready"
        • lastUpdatedAt — (Date)

          A timestamp that indicates when the instance information was last updated.

        • lifecycleEvents — (Array<map>)

          A list of lifecycle events for this instance.

          • lifecycleEventName — (String)

            The deployment lifecycle event name, such as ApplicationStop, BeforeInstall, AfterInstall, ApplicationStart, or ValidateService.

          • diagnostics — (map)

            Diagnostic information about the deployment lifecycle event.

            • errorCode — (String)

              The associated error code:

              • Success: The specified script ran.

              • ScriptMissing: The specified script was not found in the specified location.

              • ScriptNotExecutable: The specified script is not a recognized executable file type.

              • ScriptTimedOut: The specified script did not finish running in the specified time period.

              • ScriptFailed: The specified script failed to run as expected.

              • UnknownError: The specified script did not run for an unknown reason.

              Possible values include:
              • "Success"
              • "ScriptMissing"
              • "ScriptNotExecutable"
              • "ScriptTimedOut"
              • "ScriptFailed"
              • "UnknownError"
            • scriptName — (String)

              The name of the script.

            • message — (String)

              The message associated with the error.

            • logTail — (String)

              The last portion of the diagnostic log.

              If available, CodeDeploy returns up to the last 4 KB of the diagnostic log.

          • startTime — (Date)

            A timestamp that indicates when the deployment lifecycle event started.

          • endTime — (Date)

            A timestamp that indicates when the deployment lifecycle event ended.

          • status — (String)

            The deployment lifecycle event status:

            • Pending: The deployment lifecycle event is pending.

            • InProgress: The deployment lifecycle event is in progress.

            • Succeeded: The deployment lifecycle event ran successfully.

            • Failed: The deployment lifecycle event has failed.

            • Skipped: The deployment lifecycle event has been skipped.

            • Unknown: The deployment lifecycle event is unknown.

            Possible values include:
            • "Pending"
            • "InProgress"
            • "Succeeded"
            • "Failed"
            • "Skipped"
            • "Unknown"
        • instanceType — (String)

          Information about which environment an instance belongs to in a blue/green deployment.

          • BLUE: The instance is part of the original environment.

          • GREEN: The instance is part of the replacement environment.

          Possible values include:
          • "Blue"
          • "Green"
      • errorMessage — (String)

        Information about errors that might have occurred during the API call.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

batchGetDeployments(params = {}, callback) ⇒ AWS.Request

Gets information about one or more deployments. The maximum number of deployments that can be returned is 25.

Service Reference:

Examples:

Calling the batchGetDeployments operation

var params = {
  deploymentIds: [ /* required */
    'STRING_VALUE',
    /* more items */
  ]
};
codedeploy.batchGetDeployments(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • deploymentIds — (Array<String>)

      A list of deployment IDs, separated by spaces. The maximum number of deployment IDs you can specify is 25.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • deploymentsInfo — (Array<map>)

        Information about the deployments.

        • applicationName — (String)

          The application name.

        • deploymentGroupName — (String)

          The deployment group name.

        • deploymentConfigName — (String)

          The deployment configuration name.

        • deploymentId — (String)

          The unique ID of a deployment.

        • previousRevision — (map)

          Information about the application revision that was deployed to the deployment group before the most recent successful deployment.

          • revisionType — (String)

            The type of application revision:

            • S3: An application revision stored in Amazon S3.

            • GitHub: An application revision stored in GitHub (EC2/On-premises deployments only).

            • String: A YAML-formatted or JSON-formatted string (Lambda deployments only).

            • AppSpecContent: An AppSpecContent object that contains the contents of an AppSpec file for an Lambda or Amazon ECS deployment. The content is formatted as JSON or YAML stored as a RawString.

            Possible values include:
            • "S3"
            • "GitHub"
            • "String"
            • "AppSpecContent"
          • s3Location — (map)

            Information about the location of a revision stored in Amazon S3.

            • bucket — (String)

              The name of the Amazon S3 bucket where the application revision is stored.

            • key — (String)

              The name of the Amazon S3 object that represents the bundled artifacts for the application revision.

            • bundleType — (String)

              The file type of the application revision. Must be one of the following:

              • tar: A tar archive file.

              • tgz: A compressed tar archive file.

              • zip: A zip archive file.

              • YAML: A YAML-formatted file.

              • JSON: A JSON-formatted file.

              Possible values include:
              • "tar"
              • "tgz"
              • "zip"
              • "YAML"
              • "JSON"
            • version — (String)

              A specific version of the Amazon S3 object that represents the bundled artifacts for the application revision.

              If the version is not specified, the system uses the most recent version by default.

            • eTag — (String)

              The ETag of the Amazon S3 object that represents the bundled artifacts for the application revision.

              If the ETag is not specified as an input parameter, ETag validation of the object is skipped.

          • gitHubLocation — (map)

            Information about the location of application artifacts stored in GitHub.

            • repository — (String)

              The GitHub account and repository pair that stores a reference to the commit that represents the bundled artifacts for the application revision.

              Specified as account/repository.

            • commitId — (String)

              The SHA1 commit ID of the GitHub commit that represents the bundled artifacts for the application revision.

          • string — (map)

            Information about the location of an Lambda deployment revision stored as a RawString.

            • content — (String)

              The YAML-formatted or JSON-formatted revision string. It includes information about which Lambda function to update and optional Lambda functions that validate deployment lifecycle events.

            • sha256 — (String)

              The SHA256 hash value of the revision content.

          • appSpecContent — (map)

            The content of an AppSpec file for an Lambda or Amazon ECS deployment. The content is formatted as JSON or YAML and stored as a RawString.

            • content — (String)

              The YAML-formatted or JSON-formatted revision string.

              For an Lambda deployment, the content includes a Lambda function name, the alias for its original version, and the alias for its replacement version. The deployment shifts traffic from the original version of the Lambda function to the replacement version.

              For an Amazon ECS deployment, the content includes the task name, information about the load balancer that serves traffic to the container, and more.

              For both types of deployments, the content can specify Lambda functions that run at specified hooks, such as BeforeInstall, during a deployment.

            • sha256 — (String)

              The SHA256 hash value of the revision content.

        • revision — (map)

          Information about the location of stored application artifacts and the service from which to retrieve them.

          • revisionType — (String)

            The type of application revision:

            • S3: An application revision stored in Amazon S3.

            • GitHub: An application revision stored in GitHub (EC2/On-premises deployments only).

            • String: A YAML-formatted or JSON-formatted string (Lambda deployments only).

            • AppSpecContent: An AppSpecContent object that contains the contents of an AppSpec file for an Lambda or Amazon ECS deployment. The content is formatted as JSON or YAML stored as a RawString.

            Possible values include:
            • "S3"
            • "GitHub"
            • "String"
            • "AppSpecContent"
          • s3Location — (map)

            Information about the location of a revision stored in Amazon S3.

            • bucket — (String)

              The name of the Amazon S3 bucket where the application revision is stored.

            • key — (String)

              The name of the Amazon S3 object that represents the bundled artifacts for the application revision.

            • bundleType — (String)

              The file type of the application revision. Must be one of the following:

              • tar: A tar archive file.

              • tgz: A compressed tar archive file.

              • zip: A zip archive file.

              • YAML: A YAML-formatted file.

              • JSON: A JSON-formatted file.

              Possible values include:
              • "tar"
              • "tgz"
              • "zip"
              • "YAML"
              • "JSON"
            • version — (String)

              A specific version of the Amazon S3 object that represents the bundled artifacts for the application revision.

              If the version is not specified, the system uses the most recent version by default.

            • eTag — (String)

              The ETag of the Amazon S3 object that represents the bundled artifacts for the application revision.

              If the ETag is not specified as an input parameter, ETag validation of the object is skipped.

          • gitHubLocation — (map)

            Information about the location of application artifacts stored in GitHub.

            • repository — (String)

              The GitHub account and repository pair that stores a reference to the commit that represents the bundled artifacts for the application revision.

              Specified as account/repository.

            • commitId — (String)

              The SHA1 commit ID of the GitHub commit that represents the bundled artifacts for the application revision.

          • string — (map)

            Information about the location of an Lambda deployment revision stored as a RawString.

            • content — (String)

              The YAML-formatted or JSON-formatted revision string. It includes information about which Lambda function to update and optional Lambda functions that validate deployment lifecycle events.

            • sha256 — (String)

              The SHA256 hash value of the revision content.

          • appSpecContent — (map)

            The content of an AppSpec file for an Lambda or Amazon ECS deployment. The content is formatted as JSON or YAML and stored as a RawString.

            • content — (String)

              The YAML-formatted or JSON-formatted revision string.

              For an Lambda deployment, the content includes a Lambda function name, the alias for its original version, and the alias for its replacement version. The deployment shifts traffic from the original version of the Lambda function to the replacement version.

              For an Amazon ECS deployment, the content includes the task name, information about the load balancer that serves traffic to the container, and more.

              For both types of deployments, the content can specify Lambda functions that run at specified hooks, such as BeforeInstall, during a deployment.

            • sha256 — (String)

              The SHA256 hash value of the revision content.

        • status — (String)

          The current state of the deployment as a whole.

          Possible values include:
          • "Created"
          • "Queued"
          • "InProgress"
          • "Baking"
          • "Succeeded"
          • "Failed"
          • "Stopped"
          • "Ready"
        • errorInformation — (map)

          Information about any error associated with this deployment.

          • code — (String)

            For more information, see Error Codes for CodeDeploy in the CodeDeploy User Guide.

            The error code:

            • APPLICATION_MISSING: The application was missing. This error code is most likely raised if the application is deleted after the deployment is created, but before it is started.

            • DEPLOYMENT_GROUP_MISSING: The deployment group was missing. This error code is most likely raised if the deployment group is deleted after the deployment is created, but before it is started.

            • HEALTH_CONSTRAINTS: The deployment failed on too many instances to be successfully deployed within the instance health constraints specified.

            • HEALTH_CONSTRAINTS_INVALID: The revision cannot be successfully deployed within the instance health constraints specified.

            • IAM_ROLE_MISSING: The service role cannot be accessed.

            • IAM_ROLE_PERMISSIONS: The service role does not have the correct permissions.

            • INTERNAL_ERROR: There was an internal error.

            • NO_EC2_SUBSCRIPTION: The calling account is not subscribed to Amazon EC2.

            • NO_INSTANCES: No instances were specified, or no instances can be found.

            • OVER_MAX_INSTANCES: The maximum number of instances was exceeded.

            • THROTTLED: The operation was throttled because the calling account exceeded the throttling limits of one or more Amazon Web Services services.

            • TIMEOUT: The deployment has timed out.

            • REVISION_MISSING: The revision ID was missing. This error code is most likely raised if the revision is deleted after the deployment is created, but before it is started.

            Possible values include:
            • "AGENT_ISSUE"
            • "ALARM_ACTIVE"
            • "APPLICATION_MISSING"
            • "AUTOSCALING_VALIDATION_ERROR"
            • "AUTO_SCALING_CONFIGURATION"
            • "AUTO_SCALING_IAM_ROLE_PERMISSIONS"
            • "CODEDEPLOY_RESOURCE_CANNOT_BE_FOUND"
            • "CUSTOMER_APPLICATION_UNHEALTHY"
            • "DEPLOYMENT_GROUP_MISSING"
            • "ECS_UPDATE_ERROR"
            • "ELASTIC_LOAD_BALANCING_INVALID"
            • "ELB_INVALID_INSTANCE"
            • "HEALTH_CONSTRAINTS"
            • "HEALTH_CONSTRAINTS_INVALID"
            • "HOOK_EXECUTION_FAILURE"
            • "IAM_ROLE_MISSING"
            • "IAM_ROLE_PERMISSIONS"
            • "INTERNAL_ERROR"
            • "INVALID_ECS_SERVICE"
            • "INVALID_LAMBDA_CONFIGURATION"
            • "INVALID_LAMBDA_FUNCTION"
            • "INVALID_REVISION"
            • "MANUAL_STOP"
            • "MISSING_BLUE_GREEN_DEPLOYMENT_CONFIGURATION"
            • "MISSING_ELB_INFORMATION"
            • "MISSING_GITHUB_TOKEN"
            • "NO_EC2_SUBSCRIPTION"
            • "NO_INSTANCES"
            • "OVER_MAX_INSTANCES"
            • "RESOURCE_LIMIT_EXCEEDED"
            • "REVISION_MISSING"
            • "THROTTLED"
            • "TIMEOUT"
            • "CLOUDFORMATION_STACK_FAILURE"
          • message — (String)

            An accompanying error message.

        • createTime — (Date)

          A timestamp that indicates when the deployment was created.

        • startTime — (Date)

          A timestamp that indicates when the deployment was deployed to the deployment group.

          In some cases, the reported value of the start time might be later than the complete time. This is due to differences in the clock settings of backend servers that participate in the deployment process.

        • completeTime — (Date)

          A timestamp that indicates when the deployment was complete.

        • deploymentOverview — (map)

          A summary of the deployment status of the instances in the deployment.

          • Pending — (Integer)

            The number of instances in the deployment in a pending state.

          • InProgress — (Integer)

            The number of instances in which the deployment is in progress.

          • Succeeded — (Integer)

            The number of instances in the deployment to which revisions have been successfully deployed.

          • Failed — (Integer)

            The number of instances in the deployment in a failed state.

          • Skipped — (Integer)

            The number of instances in the deployment in a skipped state.

          • Ready — (Integer)

            The number of instances in a replacement environment ready to receive traffic in a blue/green deployment.

        • description — (String)

          A comment about the deployment.

        • creator — (String)

          The means by which the deployment was created:

          • user: A user created the deployment.

          • autoscaling: Amazon EC2 Auto Scaling created the deployment.

          • codeDeployRollback: A rollback process created the deployment.

          • CodeDeployAutoUpdate: An auto-update process created the deployment when it detected outdated Amazon EC2 instances.

          Possible values include:
          • "user"
          • "autoscaling"
          • "codeDeployRollback"
          • "CodeDeploy"
          • "CodeDeployAutoUpdate"
          • "CloudFormation"
          • "CloudFormationRollback"
          • "autoscalingTermination"
        • ignoreApplicationStopFailures — (Boolean)

          If true, then if an ApplicationStop, BeforeBlockTraffic, or AfterBlockTraffic deployment lifecycle event to an instance fails, then the deployment continues to the next deployment lifecycle event. For example, if ApplicationStop fails, the deployment continues with DownloadBundle. If BeforeBlockTraffic fails, the deployment continues with BlockTraffic. If AfterBlockTraffic fails, the deployment continues with ApplicationStop.

          If false or not specified, then if a lifecycle event fails during a deployment to an instance, that deployment fails. If deployment to that instance is part of an overall deployment and the number of healthy hosts is not less than the minimum number of healthy hosts, then a deployment to the next instance is attempted.

          During a deployment, the CodeDeploy agent runs the scripts specified for ApplicationStop, BeforeBlockTraffic, and AfterBlockTraffic in the AppSpec file from the previous successful deployment. (All other scripts are run from the AppSpec file in the current deployment.) If one of these scripts contains an error and does not run successfully, the deployment can fail.

          If the cause of the failure is a script from the last successful deployment that will never run successfully, create a new deployment and use ignoreApplicationStopFailures to specify that the ApplicationStop, BeforeBlockTraffic, and AfterBlockTraffic failures should be ignored.

        • autoRollbackConfiguration — (map)

          Information about the automatic rollback configuration associated with the deployment.

          • enabled — (Boolean)

            Indicates whether a defined automatic rollback configuration is currently enabled.

          • events — (Array<String>)

            The event type or types that trigger a rollback.

        • updateOutdatedInstancesOnly — (Boolean)

          Indicates whether only instances that are not running the latest application revision are to be deployed to.

        • rollbackInfo — (map)

          Information about a deployment rollback.

          • rollbackDeploymentId — (String)

            The ID of the deployment rollback.

          • rollbackTriggeringDeploymentId — (String)

            The deployment ID of the deployment that was underway and triggered a rollback deployment because it failed or was stopped.

          • rollbackMessage — (String)

            Information that describes the status of a deployment rollback (for example, whether the deployment can't be rolled back, is in progress, failed, or succeeded).

        • deploymentStyle — (map)

          Information about the type of deployment, either in-place or blue/green, you want to run and whether to route deployment traffic behind a load balancer.

          • deploymentType — (String)

            Indicates whether to run an in-place deployment or a blue/green deployment.

            Possible values include:
            • "IN_PLACE"
            • "BLUE_GREEN"
          • deploymentOption — (String)

            Indicates whether to route deployment traffic behind a load balancer.

            Possible values include:
            • "WITH_TRAFFIC_CONTROL"
            • "WITHOUT_TRAFFIC_CONTROL"
        • targetInstances — (map)

          Information about the instances that belong to the replacement environment in a blue/green deployment.

          • tagFilters — (Array<map>)

            The tag filter key, type, and value used to identify Amazon EC2 instances in a replacement environment for a blue/green deployment. Cannot be used in the same call as ec2TagSet.

            • Key — (String)

              The tag filter key.

            • Value — (String)

              The tag filter value.

            • Type — (String)

              The tag filter type:

              • KEY_ONLY: Key only.

              • VALUE_ONLY: Value only.

              • KEY_AND_VALUE: Key and value.

              Possible values include:
              • "KEY_ONLY"
              • "VALUE_ONLY"
              • "KEY_AND_VALUE"
          • autoScalingGroups — (Array<String>)

            The names of one or more Auto Scaling groups to identify a replacement environment for a blue/green deployment.

          • ec2TagSet — (map)

            Information about the groups of Amazon EC2 instance tags that an instance must be identified by in order for it to be included in the replacement environment for a blue/green deployment. Cannot be used in the same call as tagFilters.

            • ec2TagSetList — (Array<Array<map>>)

              A list that contains other lists of Amazon EC2 instance tag groups. For an instance to be included in the deployment group, it must be identified by all of the tag groups in the list.

              • Key — (String)

                The tag filter key.

              • Value — (String)

                The tag filter value.

              • Type — (String)

                The tag filter type:

                • KEY_ONLY: Key only.

                • VALUE_ONLY: Value only.

                • KEY_AND_VALUE: Key and value.

                Possible values include:
                • "KEY_ONLY"
                • "VALUE_ONLY"
                • "KEY_AND_VALUE"
        • instanceTerminationWaitTimeStarted — (Boolean)

          Indicates whether the wait period set for the termination of instances in the original environment has started. Status is 'false' if the KEEP_ALIVE option is specified. Otherwise, 'true' as soon as the termination wait period starts.

        • blueGreenDeploymentConfiguration — (map)

          Information about blue/green deployment options for this deployment.

          • terminateBlueInstancesOnDeploymentSuccess — (map)

            Information about whether to terminate instances in the original fleet during a blue/green deployment.

            • action — (String)

              The action to take on instances in the original environment after a successful blue/green deployment.

              • TERMINATE: Instances are terminated after a specified wait time.

              • KEEP_ALIVE: Instances are left running after they are deregistered from the load balancer and removed from the deployment group.

              Possible values include:
              • "TERMINATE"
              • "KEEP_ALIVE"
            • terminationWaitTimeInMinutes — (Integer)

              For an Amazon EC2 deployment, the number of minutes to wait after a successful blue/green deployment before terminating instances from the original environment.

              For an Amazon ECS deployment, the number of minutes before deleting the original (blue) task set. During an Amazon ECS deployment, CodeDeploy shifts traffic from the original (blue) task set to a replacement (green) task set.

              The maximum setting is 2880 minutes (2 days).

          • deploymentReadyOption — (map)

            Information about the action to take when newly provisioned instances are ready to receive traffic in a blue/green deployment.

            • actionOnTimeout — (String)

              Information about when to reroute traffic from an original environment to a replacement environment in a blue/green deployment.

              • CONTINUE_DEPLOYMENT: Register new instances with the load balancer immediately after the new application revision is installed on the instances in the replacement environment.

              • STOP_DEPLOYMENT: Do not register new instances with a load balancer unless traffic rerouting is started using ContinueDeployment. If traffic rerouting is not started before the end of the specified wait period, the deployment status is changed to Stopped.

              Possible values include:
              • "CONTINUE_DEPLOYMENT"
              • "STOP_DEPLOYMENT"
            • waitTimeInMinutes — (Integer)

              The number of minutes to wait before the status of a blue/green deployment is changed to Stopped if rerouting is not started manually. Applies only to the STOP_DEPLOYMENT option for actionOnTimeout.

          • greenFleetProvisioningOption — (map)

            Information about how instances are provisioned for a replacement environment in a blue/green deployment.

            • action — (String)

              The method used to add instances to a replacement environment.

              • DISCOVER_EXISTING: Use instances that already exist or will be created manually.

              • COPY_AUTO_SCALING_GROUP: Use settings from a specified Auto Scaling group to define and create instances in a new Auto Scaling group.

              Possible values include:
              • "DISCOVER_EXISTING"
              • "COPY_AUTO_SCALING_GROUP"
        • loadBalancerInfo — (map)

          Information about the load balancer used in the deployment.