Configure application settings for Azure Web App using Azure ARM template

In last post, we have discussed how to create azure web app along with the deployment slots using Azure ARM template. We are going to expand on the template created and learn how to configure application settings, web app properties like alwaysOn, remote debugging, etc and connection strings for azure web app in this blog post.

Define Web App Properties

Method 1: Use of Object variables
Variables are not only useful for declaring text that is used in multiple places and standardize them; they can be objects as well. Continue reading “Configure application settings for Azure Web App using Azure ARM template”

Deploy Azure Web App with slots using Azure ARM

Azure ARM uses simple JSON files for deploying infrastructure in Azure. While creating an azure web app or app service is not that tricky, usually you would require additional settings like deployment slots, application settings, connection strings, custom time zone etc. as well. It would be certainly nice if we can incorporate some of that as part of ARM templates itself so that we need not worry about it later. Since this topic is going to be lengthy, we’ll break into 3-4 smaller posts and also learn few azure resource manager tricks as well along the way. In this blog post, we’ll see how to create an Azure Web app and a slot associated with it using Azure ARM template.

Continue reading “Deploy Azure Web App with slots using Azure ARM”

Create Azure service endpoint in VSTS

To deploy resources on Azure using VSTS as part of ci/cd process, first VSTS needs to establish an connection with the Azure and ensure it has proper permissions to manage resources. For this purpose, if you are using VSTS to manage azure resources, you would need to create an Azure Service endpoint first. In this blog post, we’ll learn how to do the same.

If you are doing in this your personal subscription, you will probably already have required permissions on Azure AD. In that case, you can skip directly to section: Create Azure endpoints in VSTS and use short version of dialog only. VSTS will automatically query and create required configuration for you. If you are working with medium or large sized organizations, you’ll need to create it via long way which provides more granular level of access and control.  Continue reading “Create Azure service endpoint in VSTS”

Add a private build agent to VSTS and configure for capabilities

VSTS or Visual Studio Team Services is a great DevOps tool from Microsoft and it comes as a Software-as-a-Service. While configuring build pipelines, once can choose the option to build and deploy using a hosted agent. A hosted agent is provided by Microsoft and is pre-configured with all major build tools installed like Visual Studio, Java, Ant, etc. So for many organizations, this is the simplest way to build and deploy.

However, the hosted agent might not suffice for your needs. For example, you may want to use your own testing engine or compilation engine, or you are working on a not so common programming language, etc. In such cases, you will need to setup your private build server. Private agents give you more control to install dependent software needed for your builds and deployments. In this blog post, we’ll learn how to add a build server to VSTS and also configure it for build capabilities.

Continue reading “Add a private build agent to VSTS and configure for capabilities”

Configure CI/CD for dockerized apps using VSTS and deploy to ACS

n this blog post, we’ll discuss how to configure CI/CD for dockerized apps using Visual Studio Team Services (VSTS) and deploy to a Linux based kubernetes cluster in Azure Container Services (ACS). For building dockerized app, we’ll use .NET core and build a linux based docker image. Also we’ll be using Azure Container Services to deploy Linux based Kubernetes cluster and Azure Container Registry for providing docker registry.

Deploy Kubernetes cluster on ACS

For this, please refer to this blog post here.

Deploy Azure Container Registry

Continue reading “Configure CI/CD for dockerized apps using VSTS and deploy to ACS”

Deploy kubernetes cluster on Azure Container Service from Ubuntu based build server

Azure Container Service is an offering from Microsoft which makes it simple to create, configure, and manage a cluster of virtual machines that are preconfigured to run containerized applications.  The following guide is based on steps mentioned in https://docs.microsoft.com/en-us/azure/container-service/kubernetes/container-service-kubernetes-walkthrough but deviates a little. First, the guide is based on using Azure Cloud Shell which creates two issues. In my experience, this cloud shell is not ready for prime time usage as you will keep getting issues like authentication failure, for some reason the shell will expire after every 20 mins, etc. Also CI/CD cannot be build on top of the cloud shell.

Most likely scenario would be using a CI/CD tool like Jenkins, VSTS etc. using a custom agent and then you would need to run shell commands for deploying containers. In this blog post, we’ll examine how to prepare a ubuntu based workstation for this and deploy a kubernetes cluster on Azure Container Service.

Continue reading “Deploy kubernetes cluster on Azure Container Service from Ubuntu based build server”

Docker Cheat Sheet

I have spent some time to gather list of most used docker commands and below is a summary for same. These are not full blown commands, just to get you started and then you can use inbuilt command help.

Lifecycle

  • docker create Creates a container
  • docker rename Renames a container
  • docker run Creates and runs a container
  • docker rm Removes a container
  • docker update Updates a container resource limits

Continue reading “Docker Cheat Sheet”