{"id":49533135,"url":"https://github.com/khanmaster/az_terraform_iac","last_synced_at":"2026-05-02T08:36:17.746Z","repository":{"id":261490574,"uuid":"884459965","full_name":"khanmaster/az_terraform_iac","owner":"khanmaster","description":null,"archived":false,"fork":false,"pushed_at":"2024-11-06T20:04:09.000Z","size":18,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-11-06T21:17:52.639Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"HCL","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/khanmaster.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-11-06T19:41:44.000Z","updated_at":"2024-11-06T20:04:13.000Z","dependencies_parsed_at":"2024-11-06T21:17:54.515Z","dependency_job_id":"3528f8f8-70fd-4468-9ed1-32ad6fdd6000","html_url":"https://github.com/khanmaster/az_terraform_iac","commit_stats":null,"previous_names":["khanmaster/az_terraform_iac"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/khanmaster/az_terraform_iac","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/khanmaster%2Faz_terraform_iac","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/khanmaster%2Faz_terraform_iac/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/khanmaster%2Faz_terraform_iac/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/khanmaster%2Faz_terraform_iac/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/khanmaster","download_url":"https://codeload.github.com/khanmaster/az_terraform_iac/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/khanmaster%2Faz_terraform_iac/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32528580,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-02T01:12:54.858Z","status":"online","status_checked_at":"2026-05-02T02:00:05.923Z","response_time":132,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-05-02T08:36:17.086Z","updated_at":"2026-05-02T08:36:17.741Z","avatar_url":"https://github.com/khanmaster.png","language":"HCL","funding_links":[],"categories":[],"sub_categories":[],"readme":"![Recourse Group](./source/resource_group.png)\n![Azure Vnet Architecture](./source/vnet-diagram.png)\n\n\n#### Creating a resource group for all resources under a specified name and location\n\n```hcl\nresource \"azurerm_resource_group\" \"DevOps\" {\n  name     = var.name         # Name of the resource group, provided as a variable\n  location = var.location     # Location of the resource group, e.g., \"East US\"\n}\n```\n- Sets up a Network Security Group (NSG) within the resource group to control subnet traffic\n\n```hcl\nresource \"azurerm_network_security_group\" \"DevOps\" {\n  name                = \"devops-security-group\"              # Unique name for the NSG\n  location            = azurerm_resource_group.DevOps.location # Uses location of the resource group\n  resource_group_name = azurerm_resource_group.DevOps.name     # Assigns NSG to the created resource group\n}\n\n# Creates a Virtual Network with defined subnets within the specified resource group\nresource \"azurerm_virtual_network\" \"DevOps\" {\n  name                = \"devops-network\"                     # Name for the virtual network\n  location            = azurerm_resource_group.DevOps.location # Same location as the resource group\n  resource_group_name = azurerm_resource_group.DevOps.name     # Assigns to the existing resource group\n  address_space       = var.address_space                      # CIDR address space for the VNet, provided as a variable\n\n  # Public subnet configuration\n  subnet {\n    name             = \"public\"                               # Name of the subnet for public resources\n    address_prefixes = var.subnet_address_prefixes[\"public\"]  # Address prefix for the public subnet from variable map\n  }\n\n  # Private subnet configuration, protected by a Network Security Group (NSG)\n  subnet {\n    name             = \"private\"                              # Name of the subnet for private resources\n    address_prefixes = var.subnet_address_prefixes[\"private\"] # Address prefix for the private subnet from variable map\n    security_group   = azurerm_network_security_group.DevOps.id # Associates NSG to manage traffic rules\n  }\n\n  tags = {\n    environment = \"production\"                                # Tags for easier resource identification\n  }\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkhanmaster%2Faz_terraform_iac","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkhanmaster%2Faz_terraform_iac","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkhanmaster%2Faz_terraform_iac/lists"}