Skip to content

opsstation/terraform-azure-resource-group

Repository files navigation

Terraform Infrastructure as Code (IaC) - Azure Resource Group Module

Table of Contents

Introduction

This Terraform module creates structured labels for Azure resources with specific attributes.

Usage

  • Use the module by referencing its source and providing the required variables.
module "resource_group" {
  source = "git::https://github.com/opsstation/terraform-azure-resource-group.git?ref=v1.0.0"

  environment = "-resource-group"
  label_order = ["name", "environment", ]

  name     = "OpsStation"
  location = "North Europe"

  #resource lock
  resource_lock_enabled = true
  lock_level            = "CanNotDelete"
}

Please ensure you specify the correct 'source' path for the module.

Module Inputs

  • name: The name of the resource group.
  • environment: The environment (e.g., "test", "production").
  • location: The Azure region for the resource group.
  • resource_lock_enabled: Enable or disable resource lock (true/false).
  • lock_level: The lock level (e.g., "CanNotDelete").

Module Outputs

  • This module currently does not provide any outputs.

Examples

For detailed examples on how to use this module, please refer to the 'example' directory within this repository.

Authors

Your Name Replace '[License Name]' and '[Your Name]' with the appropriate license and your information. Feel free to expand this README with additional details or usage instructions as needed for your specific use case.

License

This project is licensed under the MIT License - see the LICENSE file for details.

Requirements

Name Version
terraform >= 1.0.0
azurerm >=2.90.0

Providers

Name Version
azurerm >=2.90.0

Modules

Name Source Version
labels git::https://github.com/opsstation/terraform-azure-labels.git v1.0.0

Resources

Name Type
azurerm_management_lock.resource_group_lock resource
azurerm_resource_group.rg resource

Inputs

Name Description Type Default Required
create Used when creating the Resource Group string "30m" no
delete Used when deleting the Resource Group string "70m" no
enabled Flag to control the module creation bool true no
environment Environment (e.g. prod, dev, staging). string "-OpsStation" no
label_order Label order, e.g. name,application. list(any)
[
"name",
"environment"
]
no
location Location where resource should be created string "West Europe" no
lock_level n/a string "CanNotDelete" no
managedby ManageBY, eg, 'OpsStation' string "company/opsstation" no
name The Name which should be used for this Resource Group.Changing this forces a new Resource Group to be created. string "resource-group" no
read Used when retrieving the Resource Group string "90m" no
repository Terraform current module repo string "https://github.com/opsstation/terraform-azure-resource-group" no
resource_lock_enabled enable or disable lock resource bool false no
update Used when updating the Resource Group string "50m" no

Outputs

Name Description
resource_group_id The ID of the Resource Group.
resource_group_location The Azure Region where the Resource Group should exist. Changing this forces a new Resource Group to be created.
resource_group_name The Name which should be used for this Resource Group. Changing this forces a new Resource Group to be created.
tags A mapping of tags which should be assigned to the Resource Group.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 2

  •  
  •  

Languages