Azure Resource Manager
If you are studying for Microsoft Azure Fundamentals Exam, this guide will help you with quick revision before the exam. it can use as study notes for your preparation.
Dashboard Other Certification NotesAzure Resource Manager
Azure Resource
- Anythings you create in an Azure subscription
- E.g. virtual machines, Application Gateways, and CosmosDB instances
- ๐ก Good to have consistent naming convention e.g.:
cloudarchitecture-prod-infrastructure-rg
- what itโs used for (
cloudarchitecture
) - environment (
prod
) - the types of resources contained within (
infrastructure
) - type of resource it is itself (
rg
= resource group)
- what itโs used for (
- Provides fine-grained access management through role-based access control (RBAC)
- ๐ You can move some resources that supports move to a new resource group or subscription if they support move operation.
Tagging
- Helps you better search, filter, and organize these resources
- Name/value pairs of text data that you can apply to resources and resource groups
- E.g.
- department (like finance, marketing, and more)
- environment (prod, test, dev)
- cost center
- life cycle and automation (like shutdown and startup of virtual machines)
- ๐ก๐ Good way to group your billing data
- E.g. VMs on production that belongs to a cost center A.
- ๐ก Help with monitoring
- You can set-up alerts based on tags e.g. if a resource fails notification goes to the finance department.
- ๐ก Help with automation
- E.g.
shutdown:6PM
andstartup:7AM
tag TO automate the shutdown and startup of virtual machines in development environments during off-hours to save costs.
- E.g.
- ๐ก Help with automation Governance through Policies
- E.g. ensure that all resources have the Department tag associated with them and block creation if it doesnโt exist.
- โ Limitations:
- A resource can have up to 50 tags.
- ๐ Tags arenโt inherited from parent resources.
- ๐ Not all resource types support tags
Resource locks
- ๐ Blocks modification (Read-only) or deletion (Delete) of the resource.
- For more granular control of what can be deployed e.g. see Azure policies
- Read-only allows only
HTTP GET
requests- โ Can lead to unexpected results e.g. listing all objects in a storage account requires
POST
request is denied
- โ Can lead to unexpected results e.g. listing all objects in a storage account requires
- ๐ You must remove the lock in order to perform forbidden activity.
- Apply regardless of RBAC permissions
- ๐ Protects against accidental deletion
- ๐ก Use to protect key resources that could have a large impact if they were removed or modified
- E.g. ExpressRoute circuits, virtual networks, critical databases, and domain controllers
- Only โOwnerโ and โUser Access Administratorโ can create/delete locks
- It requires access to
Microsoft.Authorization/locks/*
- It requires access to
Azure Resource Group
- Also an Azure resource so it can have locks, tags, RBAC permissions etc.
- Itโs free!
- Logical container for resources deployed on Azure.
- Tied to a region & subscription itself.
- ๐ But can contain resources from different regions
- โIf region the RG goes down, the management of the RG would not work.
- ๐ But can contain resources from different regions
- Helps you organize resources
- You can place resources of e.g. similar usage, type, or location in same group.
- ๐ If you delete a resource group, all resources contained within are also deleted.
- Authorization
- Scope for applying role-based access control (RBAC) permissions.
- Permissions are inherited in all resources that the group has.
- โ All resources must be in a resource group and a resource can only be a member of a single resource group.
- Before any resource can be provisioned, you need a resource group
- โ Some services has specific limitations or requirements to move from one resource group to another
- โ Canโt be nested.
- Can see history of the deployments to a resource group
Organizing resource groups
- By type (virtual networks, virtual machines, cosmos dbs)
- By environment (prod, qa, dev)
- By department (marketing, finance, human resources)
- Combining strategies e.g. environment and department:
- By authorization
- By who needs to administer them.
- See RBAC
- E.g. databases in database administration group to give access to database administrators.
- By life cycle
- Allows you to e.g. delete after experimentation.
- By billing
- A way to filter and sort the data to better understand where costs are allocated.
Management Groups
- ๐ Groups multiple subscriptions.
- ๐ Can have RBAC assignments and policies
- Inherited by underlying subscriptions
- Good for enterprises
- E.g.