Search code examples
bashmacosamazon-web-servicesaws-cliamazon-elastic-beanstalk

Installing aws eb cli on Mac OS


I follow the instructions from here:

http://docs.aws.amazon.com/elasticbeanstalk/latest/dg/eb-cli3-install.html

This pip install --upgrade --user awsebcli ran fine but when I type $ eb

it says command not found.

Apparently I must modify path variable:

echo $SHELL. gives me: /bin/bash.

Here are the instructions:

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 profile script.

export PATH=~/.local/bin:$PATH
This command adds a path, `~/.local/bin` in this example, to the current PATH variable.

3) Load the profile into your current session.

$ source ~/.bash_profile

This doesn't make any sense to me: why should i run $ ls -a ~ ? I ran

export PATH=~/.local/bin:$PATH

and it didn't change anything. Same for 3.

Please advise on how to get eb working. Thanks.

UPDATE:echo $PATH gives me:

/Users/ME/bin/bash:/Users/ME/bin/bash.:/Users/ME/.local/bin:/Library/Frameworks/Python.framework/Versions/3.5/bin:/usr/local/mysql-5.7.11-osx10.9-x86_64/bin:/Library/Frameworks/Python.framework/Versions/3.5/bin:/Library/Frameworks/Python.framework/Versions/3.5/bin:/Library/Frameworks/Python.framework/Versions/3.4/bin:/Users/ME/.local/bin:/Library/Frameworks/Python.framework/Versions/3.5/bin:/usr/local/mysql-5.7.11-osx10.9-x86_64/bin:/Library/Frameworks/Python.framework/Versions/3.5/bin:/Library/Frameworks/Python.framework/Versions/3.5/bin:/Library/Frameworks/Python.framework/Versions/3.4/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/share/dotnet


Solution

  • Use:

    $ brew install awsebcli
    

    as described in: Install the EB CLI on OS X

    Homebrew is specifically for OSX and handles dependencies well.