Skip to content
Ercan Ermis
Ercan Ermis

notes for everyone about cloud technology

  • Cloud
    • AWS
    • GCP
  • Container
    • Kubernetes
    • Docker
  • Linux
  • DevOps
  • Privacy Policy
  • Contact
Ercan Ermis

notes for everyone about cloud technology

Differences between AWS CLI v1 and v2

Ercan, June 9, 2022July 9, 2022

Sometimes, aws-cli doesn’t run your cli commands if you are using v1. If your aws cli is v1, I should recommend updating. In this article, you’ll learn in which conditions you should use an AWS CLI v2.

AWS CLI v1 is written in Python language and for v1, you should install Python first but if you are using v2, it comes embedded and a Python interpreter is not needed

Auto Prompt feature is amazing! The AWS CLI v2 can prompt you for commands, parameters, and resources when you run an aws command.

You can import your config! Yes, AWS CLI v2 comes with aws configure import option and you can import your .csv credentials generated from the AWS Management Console. A .csv file is imported with the profile name matching the IAM user name. For example aws configure import.

Metadata Support for high-level S3 commands: You can configure additional metadata support for high-level S3 commands with the --copy-props argument.

AWS_REGION: is absolutely a lifesaver! It’s an SDK-compatible variable and it overrides the AWS_DEFAULT_REGION variable on your environment. It’s only available in the AWS CLI.

ddb put and ddb select commands are available on AWS CLI v2 for DynamoDB operations. You can put the items into DynamoDB and search in DynamoDB tables or indexes.

YAML Support: Previously, AWS CLI v1 is only using JSON but in v2, it’s more dynamic for
stream-formats and the yaml.

aws configure list-profiles: You can list all aws cli profiles with one command.

Docker Support: This means you don’t have to install AWS CLI v2 anymore. You can just run the docker container and run your aws cli commands easily. You can run into your CI/CD directly without no worries.

aws logs tail: For CloudWatch Logs groups, you can use aws logs tail command to tails the logs. By default, the command returns logs from all CloudWatch Logs streams during the last 10 minutes.

Single Sign-On: If you are an enterprise user, you probably use an SSO to login to AWS Console. Now, AWS CLI v2 is supporting IdP for sign in requests. For example, maybe you are using the Active Directory or Google Cloud SSO Service. You can also use it via AWS CLI v2.

Client-Side Pager Program: The AWS CLI v2 provides the use of a client-side pager program for output. Default, this feature comes with turned on and returns all output through into your OS default pager program.

Wizards: This is really interesting feature I guess. You can use wizard for some configure, dynamodb, events, iam and lambda. You can follow the example on GitHub. https://github.com/aws/aws-cli/tree/v2/awscli/customizations/wizard/wizards

I hope this article helped you.








Share on Social Media
x facebook linkedin reddit
AWS awsawscliawscliv2

Post navigation

Previous post
Next post
  • AWS (45)
    • Serverless (4)
  • Best (9)
  • DevOps (16)
  • Docker (10)
  • GCP (3)
  • Kubernetes (3)
  • Linux (13)
  • Uncategorized (6)

Recent Posts

  • Automating AWS CloudWatch Log Group Tagging with Python and Boto3
  • Automating AWS ECR Tagging with Python and Boto3
  • Automating ECR Image Cleanup with Bash
  • Update ECR Repositories with Bash Script
  • Why Automated Tests Are Essential in Your CI/CD Pipeline and Development Flow
  • Streamline Your AWS ECR Management with This Powerful Bash Script
  • Setting up DKIM for Google Workspace (Gmail) using Terraform and AWS Route 53
  • Automate AWS Site-to-Site VPN Monitoring
  • Optimizing Docker Images: Tips for Reducing Image Size and Build Time
  • Monitoring EC2 Disk Space with a Simple Bash Script and Slack Alerts
  • Securing Docker Containers: Best Practices for Container Security
  • Mastering Dockerfile: Writing Efficient, Scalable Container Builds
  • Migrating a Git Repository from GitLab to GitHub with GPG-Signed Commits
  • Accessing AWS Services in Private Subnets Without 0.0.0.0/0
  • Understanding AWS Regions, Availability Zones, and VPCs: A Comprehensive Guide
©2025 Ercan Ermis | WordPress Theme by SuperbThemes