Setting up AWS CLI

Prerequisites

  1. python(python >2.7 version or python3 >3.14 version)
  2. pip OR pip3
  3. AWS CLI
  4. awscli_plugin_endpoint

Steps to install above in CentOS

  1. Install python via following command
    sudo yum install python OR sudo yum install python3
  2. Install pip via following command
    curl -O https://bootstrap.pypa.io/get-pip.py python get-pip.py --user OR python3 get-pip.py --user
  3. Install AWS CLI
    pip install awscli --upgrade --user OR pip3 install awscli --upgrade --user
  4. Install awscli_plugin
    pip install awscli_plugin_endpoint --upgrade --user OR pip3 install awscli_plugin_endpoint --upgrade --user

Verify above installations by checking versions by using the following commands:

  1. Check python version via following commands
    python --version OR python3 --version
  2. Check pip version via following commands
    pip --version OR pip3 --version
  3. Check AWS CLI version
    aws --version

Prerequisites

  1. Create .aws directory to keep config and credentials file using following command $ mkdir ~/.aws
  2. Create aws 'config' file as below with correct 'signature_version' and 'endpoint_url' 'signature_version' can be either s3v4 (for v4 signs) or s3 (for v2 signs)
    $ vi ~/.aws/config [plugins] endpoint = awscli_plugin_endpoint s3 = signature_version = s3v4 endpoint_url = https://s3.us-west-1.idrivecloud.io s3api = signature_version = s3v4 endpoint_url = https://s3.us-west-1.idrivecloud.io
  3. Create aws 'credentials' file as below with correct 'access' and 'secret'
    $ cat ~/.aws/credentials [default] aws_access_key_id = aws_secret_access_key =