I am following the AWS CLI Setup guide. I have managed to successfully install the tool on my Mac OS X terminal with the following output:
Running cmd: /usr/bin/
This appears to be the Virtual Environment method at: https://docs.aws.amazon.com/cli/latest/userguide/awscli-install-virtualenv.html
without activating the virtualenv:
source ~/cli-ve/bin/activate
in the documented example.
This happened to me as well and did not want to install brew anymore, because everything was running fine already. I also followed the 'tutorial' on AWS site and had problem in the export path step.
Basically, it added a different python folder as the one, where awscli was downloaded. So instead of export PATH=~/.local/bin:$PATH
what they suggested I used a full path from disk:
export PATH=/Users/abc/Library/Python/3.6/bin/:$PATH
If you have Anaconda version of python on your system, please use conda to install awscli:
conda install -c conda-forge awscli
I personally had the same issue with aws CodeBuild - I couldn't use the aws cli. I solved it by installing aws globally on my docker image (instead of installing it locally to a user).
RUN pip install awscli --upgrade
(instead of RUN pip install awscli --upgrade --user)
It worked for me, if that can help anyone !
Take a look at the note on https://docs.aws.amazon.com/cli/latest/userguide/install-bundle.html
By default, the install script runs under the system default version of Python. If you have installed an alternative version of Python and want to use that to install the AWS CLI, run the install script with that version by absolute path to the Python executable.
For the step where you run the install executable
instead of doing just:
$ sudo ./awscli-bundle/install -i /usr/local/aws -b /usr/local/bin/aws
Find out where your python is installed for example
$ which python
and then use the path to install the executable like
$ sudo <path from executing which python> awscli-bundle/install -i /usr/local/aws -b /usr/local/bin/aws
The above should fix the problem.
when you run the command:
pip3 install awscli --upgrade --user
watch closely where the aws cli tool gets installed, you can see the path on terminal log, in my case I got something like this:
awscli in ./Library/Python/3.6/lib/python/site-packages
Now you should add to your .bash_profile the same path but on the bin folder(removing from the lib path and instead put your bin path) like this:
export PATH=/Users/xuser/Library/Python/3.6/bin/:$PATH