AWS

How to Install AWS SAM CLI on Ubuntu

AWS SAM CLI can be installed on Linux using a series of commands and is a very easy process. The Serverless Application Model can be used from Linux with the help of commands. SAM is a template that is used to build, develop, and test a serverless application. It is also an extension for handling serverless components like API, gateway, Lambda, etc.

Let’s start with the installation of AWS SAM CLI:

Install AWS SAM CLI on Ubuntu

To install AWS SAM CLI on Ubuntu simply open the terminal by right-clicking from the mouse and choosing “Open a terminal”, After that, start with the following command to update the apt packages:

sudo apt update

Running this command will display the following output:

Download the AWS CLI before the installation of the AWS SAM using the following command:

wget https://github.com/aws/aws-sam-cli/releases/latest/download/aws-sam-cli-linux-x86_64.zip

This command will download the SAM CLI file using the AWS CLI:

Once the file is downloaded, use the following command to unzip it:

unzip aws-sam-cli-linux-x86_64.zip -d sam-installation

This command will unzip the SAM CLI file:

Install the SAM CLI by using the following command:

sudo ./sam-installation/install

This command will install the AWS SAM CLI:

You have successfully installed the AWS SAM CLI on Ubuntu.

Conclusion

The AWS CLI can easily be installed on Ubuntu OS. The first step is to download it in the form of a zipped file, unzipping it using the “unzip“ command and after that running the installer script. After the installation, confirm the installation with the help of the command “sam –version”. This post has taught you the process of installing the AWS SAM CLI on ubuntu.

About the author

Abdul Mannan

I am curious about technology and writing and exploring it is my passion. I am interested in learning new skills and improving my knowledge and I hold a bachelor's degree in computer science.