Bind a azure DNS to a google domain

Create the terraform code to initialize a Azure DNS #

First let’s create a variable file. This file will store all variables definitions, descriptions, types and validations.

variable "location" {
  type        = string
  description = "Resources location"

variable "domain_name" {
  default     = ""
  type        = string
  description = "Domain name for the dns zone"

After that, create a file and add to it the resource group creation code.

resource "azurerm_resource_group" "this" {
  name     = "rg-resource-group-name"
  location = var.location

And finally create your dns zone.

resource "azurerm_dns_zone" "this" {
  name                = var.domain_name
  resource_group_name =

Add Azure dns to your google domain #

Go to My Domains/

Select the custom name server and add the azure name servers. They are visible in the Azure DNS zone panel like