Deploying Terraform IAC Using Azure DevOps Runtime Parameters

Introduction

While deploying your same terraform code manually multiple times you must have got through the thoughts:

  • If we can automate the whole deployment process and replace the whole tedious process with few clicks.
  • If we can dynamically change the values of terraform.tfvars.
  • If we can restrict the regions of deployments.
  • If we can limit our VM types to maintain better cost optimization.

In this article, we will touch upon these problems and try to resolve them in a way that the same concepts can also be applied to similar requirements. Continue reading “Deploying Terraform IAC Using Azure DevOps Runtime Parameters”

Increasing Code Reusability Using Task Groups in Azure DevOps

Introduction

Let’s assume a scenario in which you are repeating a few tasks from your pipeline into multiple stages and/or pipelines or projects. In that case, it gets really tiring to repeat and configure each task individually over and over again. Azure DevOps provides the feature of Task Group in which we can encapsulate a sequence of tasks from our build or release pipelines and reuse those tasks in other pipelines. Continue reading “Increasing Code Reusability Using Task Groups in Azure DevOps”

How To Setup An Agent On Azure Devops

Introduction

To set up a self-hosted agent in Azure DevOps, follow these steps: First, generate a Personal Access Token (PAT). Next, go to Organization Settings to create an agent pool. Next, download the appropriate agent package for your operating system (whether it’s Windows or Linux). Then, run the `config.cmd` or `./config.sh` command to register the agent. Be sure to install the agent in a directory that doesn’t contain spaces, such as `C:\agents`.

Azure DevOps is an integrated service provided by Azure. In recent times, it is observed that Azure DevOps is increasing its penetration into the DevOps community. Being a SaaS service, it doesn’t come with a pre-configured host or better say, an agent to execute its commands. That’s why whenever we want to use our Azure DevOps Pipeline we need to have an agent configured in our Agent Pool. In this blog, we will learn how to configure an agent and later on how to create a service for our host. Continue reading “How To Setup An Agent On Azure Devops”

Terraform CI-CD With Azure DevOps

Let’s consider a scenario in which you are deploying your infrastructure using a Terraform code (infrastructure-as-code) which is stored in a remote git repository. Now working in an organization you need to make sure that all your deployments are always tracked without an exception, an add-on to that whether your Terraform code is following your security and compliance policies or not. Or maybe what is the monthly cost that you can expect with that infra and whether it lies under your budget or not. You may also want to take note that all your resources are being created in the same region… etc… etc.

Sounds magical right !!! We all know that these concerns are very important when you’re looking for a highly consistent, fully tracked, and automated approach. That’s why in this article we are going to look for a simple step-by-step way to automate and streamline our Terraform code using Azure DevOps (ADO).

Soo… Let’s Get Started !!!

Continue reading “Terraform CI-CD With Azure DevOps”

What is a Bare Git Repository?

A Git bare repository is a specialized version of a Git repository that serves a different purpose than a regular Git repository. Many platforms, such as GitHub, rely on bare repositories stored on their servers. When you clone a repository from GitHub, you’re actually accessing one of these bare repositories. They’re designed for server-side use, helping to securely and efficiently manage and distribute code, without the ability to directly modify files like a normal repository. Here’s a simple explanation:

  • Lack of a working directory: Unlike standard Git repositories, bare repositories don’t have a working directory. This means you can’t view or edit files directly. You also won’t be able to run Git commands that typically require a working directory.
  • Only contains Git data: A bare repository only contains the .git folder data you’d find in a normal repository. This includes version history, configuration, branches, etc., but it doesn’t include the actual project files that you can edit.
  • Used for Sharing: Bare repositories are typically found on servers where multiple developers share code. Instead of working directly in the bare repository, developers clone it to their local computers, make changes, and then push those changes back to the bare repository. Services like GitHub use a similar process.
  • Prevents direct editing: By not having a working directory, there’s no risk of users directly editing files on the server. This helps avoid conflicts and maintain version control.
  • Simplifies management: If you’re managing a server-side repository and only need to monitor history and branches, a bare repository is a more efficient and secure option.

By understanding these details, you can appreciate the role of bare repositories in a collaborative coding environment.

Continue reading “What is a Bare Git Repository?”