AWS CLI (Amazon Web Services Command Line Interface) is the command utility that is used to manage the AWS resources, also it allows the users to manage their AWS tasks through the command-line interface.
It helps users create and manage the Amazon EC2 and Amazon S3 through the terminal. Also, the Amazon Relational Database Services can be managed using the AWS CLI.
This post explains the methods for the installation and updation of the AWS CLI on Debian 12 using the terminal.
How to Install the AWS CLI on Debian 12 using the Terminal?
AWS CLI can be installed on Debian 12 using one of the below-mentioned methods:
Method 1: Install the AWS CLI on Debian 12 Using the Pipx
Pipx package manager can be used for the installation of AWS CLI with the next mentioned commands.
Step 1: Launch the Terminal
First, launch the terminal as shown below:
Step 2: Update the Packages
Make sure all the packages of the default repository are up to date:
$ sudo apt update
Step 3: Install the Pipx
Now install the Pipx package manager using the command:
$ sudo apt install pipx -y
To use it from any directory, run the command:
$ pipx ensurepath
Step 4: Install the AWS CLI
Use the pipx package manager for installing the AWS CLI on Debian 12:
$ sudo pipx install awscli
Method 2: Install the AWS CLI on Debian 12 Using the Source Package
Another installation method for the AWS CLI on Debian 12 is by downloading the zip package from its official website:
$ curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip"
Extract the downloaded zip folder with the zip command:
$ unzip awscliv2.zip
Finally, install the extracted folder of the AWS CLI using the command:
$ sudo ./aws/install
Display the installed version of the AWS CLI by executing the command:
$ aws --version
How to Update the AWS CLI on Debian 12?
If the AWS CLI has been installed using the source package, then download the new package and reinstall it by following the steps of Method 2. If it is installed using the pipx, then follow the below-mentioned command:
$ pipx install --upgrade aswcli
How to Uninstall AWS CLI on Debian 12?
If the package is installed using the Pipx package manager, then execute the command:
$ sudo pipx uninstall awscli
This is all about the installation and updating of the AWS CLI on Debian 12.
To install or update the latest version of AWS CLI on Debian 12 either use the pipx Python package manager or the source package. This post has explained both methods in detail with a demonstration of each command involved in these methods.