AWS CodeDeploy
User Guide (API Version 2014-10-06)

The procedures in this guide support the new console design. If you choose to use the older version of the console, you will find many of the concepts and basic procedures in this guide still apply. To access help in the new console, choose the information icon.

Create an Application for an AWS Lambda Function Deployment (Console)

You can use the AWS CodeDeploy console to create an application for an AWS Lambda function deployment.

  1. Sign in to the AWS Management Console and open the AWS CodeDeploy console at https://console.aws.amazon.com/codedeploy.

    Note

    Sign in with the same account or IAM user information that you used in Getting Started with AWS CodeDeploy.

  2. In the navigation pane, expand Deploy, and choose Getting started.

  3. On the Create application page, choose Use CodeDeploy.

  4. Enter the name of your application in Application name.

  5. From Compute platform, choose AWS Lambda.

  6. Choose Create application.

  7. On your application page, from the Deployment groups tab, choose Create deployment group.

  8. In Deployment group name, enter a name that describes the deployment group.

    Note

    If you want to use the same settings used in another deployment group (including the deployment group name and the deployment configuration), choose those settings on this page. Although this new deployment group and the existing deployment group might have the same name, AWS CodeDeploy treats them as separate deployment groups, because each is associated with a separate application.

  9. In Service role, choose a service role that grants AWS CodeDeploy access to AWS Lambda. For more information, see Step 3: Create a Service Role for AWS CodeDeploy.

  10. If you want to use a predefined deployment configuration, choose one from Deployment configuration, and then skip to step 12. To create a custom configuration, continue to the next step.

    For more information about deployment configurations, see Deployment Configurations on an AWS Lambda Compute Platform .

  11. To create a custom configuration, choose Create deployment configuration, and then do the following:

    1. For Deployment configuration name, enter a name for the configuration.

    2. From Type, choose a configuration type. If you choose Canary, traffic is shifted in two increments. If you choose Linear, traffic is shifted in equal increments, with an equal number of minutes between each increment.

    3. For Step, enter a percentage of traffic, between 1 and 99, to be shifted. If your configuration type is Canary, this is the percentage of traffic that is shifted in the first increment. The remaining traffic is shifted after the selected interval in the second increment. If your configuration type is Linear, this is the percentage of traffic that is shifted at the start of each interval.

    4. In Interval, enter the number of minutes. If your configuration type is Canary, this is the number of minutes between the first and second traffic shift. If your configuration type is Linear, this is the number of minutes between each incremental shift.

      Note

      The maximum length of an AWS Lambda deployment is two days, or 2,880 minutes. Therefore, the maximum value specified for Interval for a canary configuration is 2,800 minutes. The maximum value for a linear configuration depends on the value for Step. For example, if the step percentage of a linear traffic shift is 25%, then there are four traffic shifts. The maximum interval value is 2,880 divided by four, or 720 minutes.

    5. Choose Create deployment configuration.

  12. (Optional) In Advanced, configure any options you want to include in the deployment, such as Amazon SNS notification triggers, Amazon CloudWatch alarms, or automatic rollbacks.

    For more information, see Configure Advanced Options for a Deployment Group.

  13. Choose Create deployment group.