How to manage access with Azure Role-based Access Control (RBAC)
Tags: cloud, azure, devops, cloudcomputing
Published: 2023-05-22 16:58:10

Azure role-based access control (Azure RBAC) is a system that provides fine-grained access management of Azure resources. Using Azure RBAC, you can segregate duties within your team and grant only the amount of access to users that they need to perform their jobs.

In this guide we will be using Azure RBAC to assign roles and view activity logs

**_Creating User_**

**Step 1:**
Visit [portal.azure.com](url), login or sign up if you don't have an account, you can get a free account at [azure.microsoft.com/en-us/free/](url)

**Step 2:**
On the Azure portal page **click search box** and **enter Azure active directory**, then **select Azure active directory**

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

**Step 3:**
On default directory page **click users** on the left

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

**Step 4:**
On the User page **click new user** and **select create new user**

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

**Step 5:**
**Enter a principal name** of your choice, **enter a display name** and leave the rest of the settings as default, then **click review + create**

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

**Step 6:**
**Click create**

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

**Step 7:**
**Click on the user** we just created

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

**Step 8:**
On the user page **click reset password** to get a temporary password

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

**_Assigning Role to User_**

**Step 1:**
On the Azure portal page **click the search box** and **enter resource group**, then **click resource group**

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

**Step 2:**
On the resource group page **click create button**

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/1tahkjr6xdd0u4sw6si0.png)

**Step 3:**
**Enter a resource group name** of your choice and choose a region of your choice then **click review and create button**

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

**Step 4:**
After validation has passed **click create button**

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

**Step 5:**
After the resource group has been created, **click go to resource group**

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

**Step 6:**
On the resource group page **click Access control (IAM)** on the left side

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9hs7camhbbtx6fwf6812.png)

**Step 7:**
On the access control page **click add button**, then **click add role assignment**

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

**Step 8:**
On the Add role assignment page **search for Virtual Contributor** in the search box

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0org6es29teeq68gkr4w.png)

**Step 9:**
Scroll down and **select Virtual Machine Contributor** then **click next**

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/47evp9vflsfkjf41p0mw.png)

**Step 10:**
On the Add role assignment page **click select members**, then **select a member** and **click select**

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

**Step 11:**
**Add description** and **click review + assign button**

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/4b1cayjy4nnq09kr1s15.png)

**Step 12:**
Viola!!! role has been added, now to view activity log, click activity log on the left

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/84uuoy10erhr39zfe1re.png)