Installing AWS CLI on Mac

The AWS guide is still a good starting point for this. The main piece I had trouble with was using `aws –version` once it was installed.

Prerequisite: have Python3 and Pip3 installed

Quick answer: adjust $PATH so it has the path to the AWS executable.

1) Find where it installed AWS.  The guide says to use which python3 – but when I installed Python it installed it to my user, not the system. When you ran `pip3 install awscli –updgrade –user` it should have spit out something like this `… awscli in ./Library/Python/3.8/lib/python/site-packages (1.18.18)`.  The “./” indicated it is a local path, NOT the system path. You can confirm by checking `ls -la /Users/<insert_user_name>/Library/Python/3.8/bin/aws`

2) Edit  ~./bash_profile and add the path

export PATH=/Users/<insert_user_name>/Library/Python/3.8/bin:$PATH

3) Reload the profile

source .bash_profile

4) Test – aws –version should output

aws-cli/1.18.18 Python/3.8.2 Darwin/17.7.0 botocore/1.15.18

 

 

Leave a Reply

Your email address will not be published. Required fields are marked *