Create an AWS IAM account to deploy our applications with ASP.NET
Tags: cloud, aws, dotnet, tutorial
Published: 2022-01-14 13:26:39

Amazon Web Services, also known as AWS, is a suite of cloud computing tools and services from Amazon. In this first article, our goal will be to create an IAM (AWS Identity and Access Management) account, focused on deploying web applications ASP.NET. In this sense, this will be the process: 

- Get an AWS Free Tier account.
- Set up an IAM account.
- Set policies for a given user in IAM.

## 1. Sign up for an AWS Free Tier account

AWS has a free tier to test and consume services for 12 months. At the following address we can make the corresponding registration: [aws.amazon.com/free](https://aws.amazon.com/free).

This is a fairly simple process, however, we must bear in mind that we must provide the data of our credit / debit card to activate it.  

## 2. Set up an IAM account

AWS _Identity and Access Management_ (IAM) provides fine-grained access control across AWS. With IAM, we can specify who can access which services and resources, and under what conditions. With IAM policies, we can also manage permissions for other users and systems we have in place to ensure least-privilege permissions.

All right, assuming we've already created a root account, or if we already have one, when you sign in, you'll see the AWS console:


![](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/5qwxj3f845iqg6z684e3.png)

When entering this IAM service, we will go to the Users section within the options menu and select Add User. The goal is to create a user, which will be used to associate the AWS services to be used, as it is not recommended to provide our root user access privileges. 

![](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/h3vk2g1orymii71s3t87.png)

The form to add a new user will look like this:

![](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/o66e32s3wgwf3lsiapgq.png) 

Once you are done creating the new IAM user, you need to download the credentials. These can be used later to perform an AWS configuration from Visual Studio for example. 

![](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/put010of4ls7pwvqdp26.png)

Note: It is very important to keep this CSV file in a safe place, as the access credentials are located there. 

## 3. Set user policies

Depending on our purpose, we may provide permissions to access and use AWS services for our users. Suppose that in this case we want to deploy our applications with ASP.NET Core from Visual Studio to AWS, for this our new IAM user needs to be able to access certain AWS services. In this case, we will address the user in question within IAM on AWS and select the option |Add inline policy|. 


![](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/5w6w00f7ch8nrhpjpf5g.png)

Then, we will perform this process for each of the following services, which will be useful to be able to deploy our web applications ASP.NET:

- Elastic Beanstalk
- EC2
- S3
- CloudFormation

![](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/vl1h4b5ck84jfy9kfxyo.png)

After adding each of the services, we will assign a name for this policy and save it. In the end we will have something like this: 


![](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/28njfw2xm8ga3hw3ywyi.png)

##**Thanks for reading!**

With this process, our IAM will be created, and policies will be in place. In future articles we will review how to access AWS from Visual Studio 2019 thanks to this configuration. 

If you have any questions or ideas in mind, it will be a pleasure to be able to be in communication and together exchange knowledge with each other.

See you at [Twitter](https://twitter.com/esDanielGomez)! Or if you like you can also write to me by other means: [esDanielGomez.com](https://esdanielgomez.com).