Getting control over your deployment pipelines to Microsoft Azure Resources Manager with VSTS
When deploying resources on Azure with Azure Resource Manager you want to be in control of which resources are deployed and control their life span. To get the control you need to do deploy in a tested, standardized and reusable manner. This can be done by managing your resource creation as Infrastructure as Code.
Continue reading “Versioning ARM Template deployments”
When you are developing Powershell scripts, creating some unit tests will help you in monitoring the quality of the scripts. Writing some tests will give you some assurance that your code still works after you make some changes. Writing Powershell unit tests can be done with Pester. Pester will enable you to test your Powershell scripts from within Powershell. It is a set of Powershell functions for unit testing Powershell. These functions will allow you to mock and isolate the Powershell code under test. When you want to integrate your unit test into your VSTS build pipeline, you need an build extension to run then in your build pipeline.
Continue reading “Powershell Pester in a VSTS build pipeline”
Create a VSTS release pipeline for Azure Functions
Azure Functions enable you to easily run small pieces of code in the cloud. To do this right, you need to setup continuous delivery of the infrastructure and the code involved. Otherwise you will end with an uncontrolled environment where nobody knows what code is actually running. In this blog post I’ll describe how to setup a deployment pipeline for Functions with VSTS. This will enable you to deploy Functions as Infrastructure as Code.
From an deployment perspective an Azure Function contains of two parts:
- Azure infrastructure
- Function code
Both the ARM template and the code can be deployed from VSTS. By doing this, you can manage functions like any other Azure resource.
Continue reading “Use VSTS to deploy Functions as Infrastructure as Code”
Your team is in the process of developing a new application feature, and the infrastructure has to be adapted. The first step is to change a file in your source control system that describes your infrastructure. When the changed definition file is saved in your source control system, it triggers a new build and release. Your new infrastructure is deployed to your test environment, and the whole process to get the new infrastructure deployed took minutes while you only changed a definition file and you did not touch the infrastructure itself.
Continue reading “Infrastructure as Code VSTS”
When testing deployment of resources in release pipelines, the resource groups need to be cleaned after you are done testing the deployment of the resources. In many scenarios you do not want or have no rights to remove the resource group it self. For removing the resources in the resource group you can use the VSTS task clean resources. This tasks removes all resources in a resource group.
When creating reusable ARM templates you have a number of options on how to manage conditional parts in your templates. The smallest conditions can be done by parameters, medium differences can be done by t-shirt sizes and large differences by linked templates. In this blog post I’ll show how to use implement conditions by linked templates.
Continue reading “Conditional parts in ARM Templates”
Protect your data at rest with disk encryption on Linux VMs and deploying them as Infrastructure as Code.
Terraform is able to generate graph files in dot (graph description language) format from your deployment plan. With some tooling the dot files be generated into image files. This makes reviewing and talking about Terraform templates easier. You are able to review a visual graph before deployment.
Continue reading “Visualizing your cloud resources with dot and Terraform”
Running Azure PowerShell commands in parallel to speed up your deployments
Making better software starts with shortening the time it takes to get feedback. The less time between you start an action and its result, the bigger the chance you will do anything with the feedback. Faster is better!
Continue reading “Parallel deployment with Azure PowerShell VSTS Release Tasks”
Removing deployments with Powershell to solve the ‘DeploymentQuotaExceeded’ error in Azure.
For some time we have been using Visual Studio Team Services Release Manager for our continuous deployments to Azure. Today our Continuous Deployments to Azure Resource Manager came to a halt with the following error:
[error]DeploymentQuotaExceeded: Creating the deployment 'deployModule-0408-0956' would exceed the quota of '800'. The current deployment count is '800', please delete some deployments before creating a new one. Please see http://aka.ms/arm-deploy for usage details.
Unfortunately we had to find out what was going on, before we could do any new deployments. This was very time consuming, because there were only two google hits on the error. They where not very helpful in solving the error.
Continue reading “Deployment limit in Azure Resource Group”