The AWS CDK CLI uses the AWS CLI’s credential chain to authenticate every API call it makes — bootstrapping, deployment, context lookups, and diffs all require valid AWS credentials to be present. This page covers installing the AWS CLI v2 from the bundled installer included in the repository, configuring your credentials, and verifying that everything is working before you runDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/okruti-raghuraj/aws-1/llms.txt
Use this file to discover all available pages before exploring further.
cdk deploy.
Installing the AWS CLI v2
The repository includes a pre-built AWS CLI v2 installer underaws-pipeline/aws/. This is a self-contained executable bundle — you do not need internet access to install from it.
Navigate to the aws/ directory and run the install script with sudo:
aws binary at /usr/local/bin/aws. Once the script completes, verify the installation:
Installing Without sudo
If you do not havesudo privileges, or if you want to install the AWS CLI only for your current user, use the -i (install directory) and -b (bin directory) options:
~/.local/aws-cli and creates symlinks for aws and aws_completer in ~/.local/bin. Make sure ~/.local/bin is on your PATH. For a full list of install options, run:
Updating an Existing Installation
If you have a previous version of the AWS CLI v2 already installed, theinstall script will refuse to overwrite it. Pass the --update flag to replace the existing version with the one bundled in the repository:
Removing the Installation
To completely uninstall the AWS CLI v2 installed from this bundle, delete the installation directory and its symlinks:-i and -b flags during installation, remove the corresponding directories and symlinks you specified instead.
Configuring Credentials
After installation, runaws configure to store your IAM credentials locally. The CLI will prompt you for four values:
| Prompt | What to enter |
|---|---|
| AWS Access Key ID | The access key ID from your IAM user’s security credentials |
| AWS Secret Access Key | The corresponding secret access key |
| Default region name | Enter ap-south-1 to match the project default, or your preferred region |
| Default output format | json is recommended; also accepts text, table, or yaml |
~/.aws/credentials and the region/output settings in ~/.aws/config.
Verifying Your Credentials
After configuration, confirm that the CLI can successfully authenticate to AWS and that the correct account is active:Account value must match the account ID configured in bin/aws-cdk-pipeline.ts. If you see an error or the wrong account, check that your access key and secret are entered correctly, or switch profiles with AWS_PROFILE=your-profile aws sts get-caller-identity.