Azure Classroomnotes 18/Oct/2022

InfraProvisioning in Azure

  • To realize applications we need to create resources, Azure has the following ways of creating resources

    • Portal
    • Command Line
      • Azure CLI
      • Azure Powershell
    • SDK (Software Development Kit)
    • Templates:
      • ARM Templates
      • Azure Bicep
        Preview
  • To create any resource we need to have active subscription. In the subscription we create resource group. Resources will be part of resource group
  • Every subscription will have resource providers. Each resource provider has one of two states registered or unregistred. We will be able to create resources belonging to registered resource providers only
    Preview
  • Each resource provider has
    • resourceTypes: resources which can be created
    • ApiVersions: Whenever a New functionality is added, generally we see new api version
      Preview
      Preview
  • When you create infra from any approach, the resource creation is carried out by resource provider.
  • Refer Here for the azure resource provider and types
  • Refer Here for resource and it resource provider
  • Every resource in Azure will have a unique resource id Refer Here

Which Approach to use

  • Portal:
    • This approach is sensible when the activity of creating resources is not repetitive.
    • We follow UI
  • CLI/Powershell:
    • This approach can be used to create the resources from automation so we need not repeat ourselves. But if there are lot of changes in terms of values to be passed with various environments or deployments CLI/Powershell becomes complex
    • We follow CLI/Powershell commands which generally are about how to create
  • Templates:
    • To automate creation with the intention of reusability with multiple values to support various environments and also various Azure accounts/subscriptions.
    • Here we define what we want (desired state) and Azure will do the rest to match the desired state when template is executed.
  • SDK: If there is a need for us to create resources programatically
  • In Azure when we create resources from Portal this will create a template.
    Preview
    Preview
    Preview
  • Now Download the template
  • Now navigate to resource group and click on deployments we should be able to view templates
    Preview
  • Pre-reqs for Template

    • Manual Creation for resources or infrastructure
    • JSON: Refer Here for video tutorial on json and yaml

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

About continuous learner

devops & cloud enthusiastic learner