Run AWS CLI & CDK commands

The AWS CLI and AWS CDK actions let you interact with various Amazon Web Services resources and services, as well as provision and manage AWS Cloud Development Kit projects.

Example pipeline with AWS CLI commandsExample pipeline with AWS CLI commands

Tip
If you are new to Buddy, check out our quickstart guides that will tell you how to create build, test and deploy your type of application.
Hint

📚 Learn more about AWS CLI version 2 action features, integrations and alternatives.

Configure pipeline in Buddy

  1. Create a new project in Buddy and select your Git provider.

Creating a new projectCreating a new project

  1. Add a new pipeline and configure the details: name, trigger mode, and a branch from which you want to deploy.

Adding a new pipelineAdding a new pipeline

Configure the CLI action

Warning
Before you add the action, make sure that your AWS user has proper permissions assigned and full programmatic access to AWS.
  1. Look up and click the CLI on the action list to add it to the pipeline:

AWS actionsAWS actions

  1. The action launches a container either with AWS CLI or AWS CDK CLI preinstalled in the container. Both actions are very similar and have five configuration tabs:
  • Run – here you select the AWS integration and provide the commands to run
  • Environment – if your process requires specific dependencies, you can install them here. The files will stay cached in the container for future pipeline runs
  • Variables – here you can view your AWS integration variables, and create your own if required
  • Conditions – here you configure the trigger conditions for which the action will run
  • Options – here you define the action's name and behavior on failure and timeout

AWS CLI action configurationAWS CLI action configuration

  1. When ready, click Add this action to finish configuration.
Success
Congratulations – you have just automated your AWS command execution! 🥳
Last update:
Sep 17, 2024