-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from sfinetworks/feature/module-init
Initialize azurerm-resource-group module
- Loading branch information
Showing
12 changed files
with
180 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
.terraform | ||
terraform.tfstate* | ||
.terragrunt-cache | ||
.vscode | ||
*.sw* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
--- | ||
formatter: markdown table | ||
|
||
version: "" | ||
|
||
header-from: ABOUT.md | ||
|
||
footer-from: "" | ||
|
||
recursive: | ||
enabled: false | ||
|
||
sections: | ||
hide: [] | ||
|
||
show: [] | ||
|
||
content: |- | ||
{{ .Header }} | ||
{{ .Requirements }} | ||
{{ .Resources }} | ||
{{ .Inputs }} | ||
{{ .Outputs }} | ||
output: | ||
file: README.md | ||
mode: inject | ||
template: |- | ||
<!-- BEGIN_TF_DOCS --> | ||
{{ .Content }} | ||
<!-- END_TF_DOCS --> | ||
output-values: | ||
enabled: false | ||
from: "" | ||
|
||
sort: | ||
enabled: true | ||
by: name | ||
|
||
settings: | ||
anchor: true | ||
color: true | ||
default: true | ||
description: false | ||
escape: true | ||
hide-empty: false | ||
html: true | ||
indent: 2 | ||
lockfile: true | ||
read-comments: true | ||
required: true | ||
sensitive: true | ||
type: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
plugin "terraform" { | ||
enabled = true | ||
preset = "all" | ||
} | ||
|
||
plugin "azurerm" { | ||
enabled = true | ||
version = "0.26.0" | ||
source = "github.com/terraform-linters/tflint-ruleset-azurerm" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
## Resource Group Terraform module | ||
|
||
This module allows creating Resource Groups in Azure | ||
|
||
| Name | Description | | ||
| --------------- | ------------------------------------------- | | ||
| [basic](basic/) | Basic example for creating a Resource Group | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,39 @@ | ||
# terraform-azurerm-resource-group | ||
Terraform module for provisioning Resource Groups in Azure | ||
|
||
<!-- BEGIN_TF_DOCS --> | ||
## Resource Group Terraform module | ||
|
||
This module allows creating Resource Groups in Azure | ||
|
||
| Name | Description | | ||
| --------------- | ------------------------------------------- | | ||
| [basic](basic/) | Basic example for creating a Resource Group | | ||
|
||
## Requirements | ||
|
||
| Name | Version | | ||
|------|---------| | ||
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | >= 1.4.0 | | ||
| <a name="requirement_azurerm"></a> [azurerm](#requirement\_azurerm) | >= 3.0.0 | | ||
|
||
## Resources | ||
|
||
| Name | Type | | ||
|------|------| | ||
| [azurerm_resource_group.this](https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/resources/resource_group) | resource | | ||
|
||
## Inputs | ||
|
||
| Name | Description | Type | Default | Required | | ||
|------|-------------|------|---------|:--------:| | ||
| <a name="input_location"></a> [location](#input\_location) | Resource group location | `string` | n/a | yes | | ||
| <a name="input_name"></a> [name](#input\_name) | Resource group name | `string` | n/a | yes | | ||
| <a name="input_tags"></a> [tags](#input\_tags) | Tags for the resource | `map(string)` | `{}` | no | | ||
|
||
## Outputs | ||
|
||
| Name | Description | | ||
|------|-------------| | ||
| <a name="output_id"></a> [id](#output\_id) | The ID of the Resource Group. | | ||
<!-- END_TF_DOCS --> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
|
||
module "resource_group" { | ||
source = "../../" | ||
|
||
name = "arengifo-test" | ||
location = "eastus2" | ||
|
||
tags = { | ||
owner = "Angel Rengifo - [email protected]" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
output "id" { | ||
description = "The ID of the Resource Group." | ||
value = module.resource_group.id | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
terraform { | ||
required_version = ">= 1.4.0" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
## -------------------------------------------------------- | ||
## Providers | ||
## -------------------------------------------------------- | ||
provider "azurerm" { | ||
features {} | ||
} | ||
|
||
## -------------------------------------------------------- | ||
## Resources | ||
## -------------------------------------------------------- | ||
resource "azurerm_resource_group" "this" { | ||
name = var.name | ||
location = var.location | ||
|
||
tags = var.tags | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
output "id" { | ||
description = "The ID of the Resource Group." | ||
value = azurerm_resource_group.this.id | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
variable "name" { | ||
description = "Resource group name" | ||
type = string | ||
} | ||
|
||
variable "location" { | ||
description = "Resource group location" | ||
type = string | ||
} | ||
|
||
variable "tags" { | ||
description = "Tags for the resource" | ||
type = map(string) | ||
default = {} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
terraform { | ||
required_version = ">= 1.4.0" | ||
|
||
required_providers { | ||
azurerm = { | ||
source = "hashicorp/azurerm" | ||
version = ">= 3.0.0" | ||
} | ||
} | ||
} |