AWS Elastic Beanstalk Command Line Interface (EB CLI)

3.27.1 · active · verified Tue Apr 14

The AWS Elastic Beanstalk Command Line Interface (EB CLI) is an open-source tool that simplifies the deployment and management of AWS Elastic Beanstalk applications and environments directly from the command line. It provides an intuitive interface, integrates with Git, and supports all key Elastic Beanstalk operations. The current version is 3.27.1, with a frequent release cadence that often includes new region support, features, and bug fixes.

Warnings

Install

Quickstart

This quickstart guides you through initializing a new Elastic Beanstalk application, creating an environment, deploying a simple 'Hello World' web application, updating it, and finally terminating the environment. Ensure AWS credentials are configured (e.g., via `aws configure` or environment variables) before running `eb init`.

# 1. Create a new project directory and navigate into it
mkdir my-hello-app
cd my-hello-app

# 2. Create a simple index.html file
echo "Hello World" > index.html

# 3. Initialize your directory with EB CLI and configure Elastic Beanstalk
eb init
# Follow the prompts to select region, application, platform (e.g., Python, Docker), and set up SSH.
# You will be prompted for AWS credentials (access key ID and secret access key).

# 4. Create your running environment and deploy the application
eb create
# Follow the prompts to create an environment. This can take several minutes.

# 5. Open your application in a browser once the environment is healthy
eb open

# 6. Make a change to your application and deploy an update (requires Git commit)
echo " to you!" >> index.html
git init
git add .
git commit -m "Updated message"
eb deploy

# 7. Terminate the environment when no longer needed
eb terminate

view raw JSON →