AWS Elastic Beanstalk
Developer Guide (API Version 2010-12-01)
AWS services or capabilities described in AWS Documentation may vary by region/location. Click Getting Started with Amazon AWS to see specific differences applicable to the China (Beijing) Region.

Install the EB CLI on macOS

If you use the Homebrew package manager, you can install the EB CLI with the brew command. You can also install Python and pip, and then use pip to install the EB CLI.

Install the EB CLI with Homebrew

If you have Homebrew, you can use it to install the EB CLI. The latest version of the EB CLI is typically available from Homebrew a couple of days after it appears in pip.

To install the EB CLI with Homebrew

  1. Make sure you have the latest version of Homebrew

    $ brew update
  2. Run brew install awsebcli:

    $ brew install awsebcli
  3. Verify that the EB CLI is installed correctly:

    $ eb --version
    EB CLI 3.2.2 (Python 3.4.3)

Install Python, pip, and the EB CLI on macOS

You can install the latest version of Python and pip and then use them to install the EB CLI.

To install the EB CLI on macOS

  1. Download and install Python 3.4 from the downloads page of Python.org.

  2. Install pip with the script provided by the Python Packaging Authority.

    $ curl -O https://bootstrap.pypa.io/get-pip.py
    $ python3 get-pip.py --user
  3. Use pip to install the EB CLI.

    $ pip3 install --user --upgrade awsebcli
  4. Add the path to the executable (~/Library/Python/3.4/bin) to your path variable:

    To modify your PATH variable (Linux, OS X, or Unix)

    1. Find your shell's profile script in your user folder. If you are not sure which shell you have, run echo $SHELL.

      $ ls -a ~
      .  ..  .bash_logout  .bash_profile  .bashrc  Desktop  Documents  Downloads
      • Bash.bash_profile, .profile, or .bash_login.

      • Zsh.zshrc

      • Tcsh.tcshrc, .cshrc or .login.

    2. Add an export command to your profile script. The following example adds the path represented by LOCAL_PATH to the current PATH variable.

      export PATH=LOCAL_PATH:$PATH
    3. Load the profile script described in the first step into your current session. The following example loads the profile script represented by PROFILE_SCRIPT into your current session.

      $ source ~/PROFILE_SCRIPT
  5. Verify that the EB CLI is installed correctly.

    $ eb --version
    EB CLI 3.7.8 (Python 3.4.1)

To upgrade to the latest version, run the installation command again:

$ pip3 install --user --upgrade awsebcli