You use the AWS CLI to sign in to KIMS's account, write your kubeconfig for EKS, check buckets and CloudFront, and reach private resources. This page only installs it; AWS access signs you in (SSO or IAM user), sets up profiles and the region.
The Jenkins site build does not need the AWS CLI: it reaches S3 and CloudFront through the AWS SDK. The Jenkins agent needs it only for aws eks update-kubeconfig and ECR login, if KIMS chooses those (Jenkins agent).
Install version 2. Version 1 (pip install awscli) uses the same aws command but lacks SSO sign-in and the commands this site uses. If aws --version shows aws-cli/1.x, uninstall it first.
#Install
The official installer (any distribution). Pick your CPU: uname -m prints x86_64 (amd64) or aarch64 (arm64).
x86_64:
curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip"
unzip awscliv2.zip
sudo ./aws/installarm64:
curl "https://awscli.amazonaws.com/awscli-exe-linux-aarch64.zip" -o "awscliv2.zip"
unzip awscliv2.zip
sudo ./aws/installIt installs into /usr/local/aws-cli with a link in /usr/local/bin. If unzip is missing: sudo apt install -y unzip or sudo dnf install -y unzip. Amazon Linux 2023 already has the CLI v2.
To update an existing install: sudo ./aws/install --update with a fresh zip, or sudo aws update on CLI 2.36 and later.
Avoid the distribution's awscli package (often version 1) and the snap (works, but lags behind).
The official package (Apple silicon and Intel, one package):
curl "https://awscli.amazonaws.com/AWSCLIV2.pkg" -o "AWSCLIV2.pkg"
sudo installer -pkg AWSCLIV2.pkg -target /Or with Homebrew: brew install awscli (community-maintained, usually current).
To update: sudo aws update (CLI 2.36 and later, official package), or brew upgrade awscli.
The official MSI, for all users (needs administrator rights):
msiexec.exe /i https://awscli.amazonaws.com/AWSCLIV2.msiFor your user only, with no administrator rights:
msiexec.exe /i https://awscli.amazonaws.com/AWSCLIV2-User.msiOr with winget: winget install -e --id Amazon.AWSCLI.
AWS also offers an install script (irm https://awscli.amazonaws.com/v2/install.ps1 | iex). On a laptop where PowerShell runs in Constrained Language Mode (as the engineer's did) a script like that may be blocked; the MSI is the dependable way.
Close every PowerShell window and open a new one afterwards, so PATH is refreshed.
#Check
aws --versionYou should see aws-cli/2.x.y Python/3.x.y <OS>/...; on Windows, for example (your numbers will differ):
aws-cli/2.32.10 Python/3.13.9 Windows/11 exe/AMD64The first number must be 2. Then check it can talk to AWS at all (this needs no credentials and returns an error that proves the network path works):
aws sts get-caller-identityBefore signing in you should see Unable to locate credentials. That is expected: AWS access is next. A timeout instead means your network cannot reach AWS's endpoints (a proxy is needed; see below).
#The Session Manager plugin (optional)
The database is private: nothing outside KIMS's VPC can reach it. If KIMS has an EC2 instance in that VPC managed by AWS Systems Manager (a "bastion" or any managed node), you can forward a local port through it to RDS with no SSH and no open ports. That needs the Session Manager plugin next to the AWS CLI. Install it only if KIMS offers this route; Database tools uses it.
Ubuntu or Debian, x86_64:
curl "https://s3.amazonaws.com/session-manager-downloads/plugin/latest/ubuntu_64bit/session-manager-plugin.deb" -o "session-manager-plugin.deb"
sudo dpkg -i session-manager-plugin.debUbuntu or Debian, arm64: the same with ubuntu_arm64 in place of ubuntu_64bit.
RHEL family and Amazon Linux, x86_64 (linux_arm64 for arm64):
sudo dnf install -y https://s3.amazonaws.com/session-manager-downloads/plugin/latest/linux_64bit/session-manager-plugin.rpmbrew install --cask session-manager-pluginOr AWS's bundled installer for your chip, from the Session Manager documentation linked in Sources.
Download and run the installer:
curl.exe -Lo SessionManagerPluginSetup.exe https://s3.amazonaws.com/session-manager-downloads/plugin/latest/windows/SessionManagerPluginSetup.exe
.\SessionManagerPluginSetup.exeOpen a new PowerShell window afterwards.
Check:
session-manager-plugin --versionYou should see a version, 1.2.764.0 or later (AWS asks for at least that).
#AWS CloudShell, when your laptop cannot
The AWS console has a browser shell, CloudShell (the >_ icon in the console's top bar), with the AWS CLI already signed in as your console user, in the region you have selected. Use it when your laptop cannot install the CLI or cannot reach AWS, for read-only checks such as:
aws rds describe-db-engine-versions --engine postgres --region ap-south-2 --query "DBEngineVersions[?starts_with(EngineVersion, '18')].EngineVersion"(That one tells you whether RDS offers PostgreSQL 18 in Hyderabad: a list of 18.x means yes.) CloudShell has 1 GB of persistent storage and cannot reach resources inside KIMS's private VPC unless it is started in "VPC environment" mode.
#Behind a proxy
HTTPS_PROXY=http://<PROXY_HOST>:<PROXY_PORT>Set it as an environment variable (Which shell to use). If the proxy re-signs TLS, set AWS_CA_BUNDLE=<PATH_TO_KIMS_CA_PEM> too. Never use --no-verify-ssl.
#If it goes wrong
| What you see | Cause | Fix |
|---|---|---|
aws: command not found / 'aws' is not recognized |
Window opened before install, or /usr/local/bin not on PATH |
New window; ls -l /usr/local/bin/aws; on Windows check C:\Program Files\Amazon\AWSCLIV2\ |
aws --version shows aws-cli/1.x |
Version 1 installed earlier (pip or the distribution) and first on PATH |
pip uninstall awscli or remove the package; command -v aws / where.exe aws |
Unable to locate credentials |
Not signed in yet | AWS access |
Could not connect to the endpoint URL / timeout |
No route to AWS, or a proxy is needed | Behind a proxy |
SSL validation failed ... certificate verify failed |
TLS-inspecting proxy | AWS_CA_BUNDLE with KIMS's CA certificate |
SessionManagerPlugin is not found |
Plugin missing, or window opened before install | Install it; open a new window |
| The install script fails with a language-mode error (Windows) | Constrained Language Mode | Use the MSI |
#Sources
kims-v2/deploy/jenkins/README-site.md(the site build needs no AWS CLI)kims-v2/docs/ON-SITE-DEPLOYMENT.md(branchmain: the PostgreSQL 18 check in Hyderabad with CloudShell)kims-deploy-info/scripts/README.md(Constrained Language Mode on the engineer's laptop)- https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html
- https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-proxy.html
- https://docs.aws.amazon.com/systems-manager/latest/userguide/session-manager-working-with-install-plugin.html
- https://docs.aws.amazon.com/cloudshell/latest/userguide/welcome.html
- https://formulae.brew.sh/formula/awscli