ARM Templates
ARM (Azure Resource Manager) template is a block of code that defines the infrastructure and configuration for your project. These templates use a declarative syntax to let you define your deployment in the form of JSON (JavaScript Object Notation) files. All the resources and their properties are defined in this template. This helps in automating the deployment process in a constant flow.
Advantages:
ARM Template provides multiple advantages over the deployment process.
Using ARM Templates, we can declare network infrastructure, storage and any other resources.
Over the development lifecycle, ARM Templates allows the deployment of resources repeatedly in a consistent manner.
User can deploy templates parallelly, and only one command is sufficient to deploy all your resource settings.
Templates can be divided into different modules. In other words, templates can be broken into multiple templates so that a parent template can consist of small templates.
The PowerShell or Bash Scripts can be added to the templates using deployment scripts.
The working of ARM Templates can be tested using the ARM template toolkit.
A user can see the preview of the template. All the resources that are being created or deleted in this template will be shown in the preview.
A user can integrate templates with Continuous Integration (CI) and Continuous Deployment (CD) tools to automate the release.
Terraform
Terraform is a tool for building, changing, and versioning infrastructure. It is essentially an infrastructure as a code (IaC) tool that helps you build, manage, and scale your infrastructure easily and effectively. It is a powerful tool that supports multi-cloud like Amazon Web Services, Microsoft Azure, and Google Cloud Platform, or on-prem in private clouds such as VMWare vSphere, OpenStack, or CloudStack. The primary use of the terraform is to ensure that the infrastructure never drifts away from its desired configuration. The language used for configuration is Hashicorp Configuration Language (HCL).
Advantages:
Support of various cloud solutions
Highly Expandable
Storage and Import function for existing architectures
Ability to generate dependency graphs
Disadvantages:
Demanding entry
No automatic rollback function for incorrect changes to resources
Collaboration and security features available only in expensive enterprise plans
Comparison Table
Features | ARM | Terraform |
Language | JSON + Bicep | HCL/DSL |
Language (preview) | Bicep DSL | CDK for Terraform, Python and TypeScript Support |
Clouds | Azure only | Agnostic + on-prem |
Preview Changes | az deployment.... what-if | terraform plan |
Rollback Changes | Rollback | Revert Code & Re-deploy |
Infrastructure Clean Up | No | Terraform destroy |
Deployment History | Deployment History | SCM + Auditing |
Code Re-Use | Hosted JSON URI's | Modules + Registry |
State Files | No State Files | Plain-text |
Terms:
Bicep - It is s declarative language for describing and deploying Azure Resources
CDK for Terraform - Cloud Development Kit for Terraform allows you to use familiar programming languages to define cloud infrastructure and provision it through HashiCorp Terraform
Rollback - When a deployment fails, you can automatically redeploy an earlier, successful deployment from your deployment history. ... This feature rollbacks a failed deployment by redeploying an earlier deployment. This result may be different than what you would expect from undoing the failed deployment.
Auditing - Azure Audit Logs is a data source that provides a wealth of information on the operations on your Azure resources. The most important data within Azure Audit Logs is the operational logs from all your resources. This includes all control-plane operations of your resources tracked by Azure Resource Manager.
Deployment History - Azure Resource Manager enables you to view your deployment history. You can examine specific operations in past deployments and see which resources were deployed. This history contains information about any errors. The deployment history for a resource group is limited to 800 deployments
Modules - Azure Automation supports custom PowerShell modules that you create to use with your runbooks and DSC configurations. One type of custom module is an integration module that optionally contains a file of metadata to define the custom functionality for the module cmdlets.
Registry - The Azure container registry is Microsoft's own hosting platform for Docker images. It is a private registry where you can store and manage private docker container images and other related artifacts. These images can then be pulled and run locally or used for container-based deployments to hosting platforms.
The Tech Platform
Comentarios