From ae2656119e48ca776f59eb017cb83f76c893f275 Mon Sep 17 00:00:00 2001 From: gaupt Date: Wed, 24 Jul 2024 23:14:23 +0300 Subject: [PATCH 1/5] check some task --- main.tf | 7 +++++++ modules/resource_group_storage/main.tf | 12 ++++++++++++ modules/resource_group_storage/outputs.tf | 7 +++++++ modules/resource_group_storage/variables.tf | 17 +++++++++++++++++ 4 files changed, 43 insertions(+) create mode 100644 main.tf create mode 100644 modules/resource_group_storage/main.tf create mode 100644 modules/resource_group_storage/outputs.tf create mode 100644 modules/resource_group_storage/variables.tf diff --git a/main.tf b/main.tf new file mode 100644 index 0000000..83c898b --- /dev/null +++ b/main.tf @@ -0,0 +1,7 @@ +module "resource_group_storage" { + source = "github.com/gaupt/terraform-azurerm-resource_group_storage" + + resource_group_name = "example-rg" + location = "East US" + storage_account_name = "examplestorage" +} \ No newline at end of file diff --git a/modules/resource_group_storage/main.tf b/modules/resource_group_storage/main.tf new file mode 100644 index 0000000..21ebc0a --- /dev/null +++ b/modules/resource_group_storage/main.tf @@ -0,0 +1,12 @@ +resource "azurerm_resource_group" "tk6" { + name = var.resource_group_name + location = var.location +} + +resource "azurerm_storage_account" "tk6" { + name = var.storage_account_name + resource_group_name = azurerm_resource_group.tk6.name + location = azurerm_resource_group.tk6.location + account_tier = "Standard" + account_replication_type = "LRS" +} \ No newline at end of file diff --git a/modules/resource_group_storage/outputs.tf b/modules/resource_group_storage/outputs.tf new file mode 100644 index 0000000..b649de9 --- /dev/null +++ b/modules/resource_group_storage/outputs.tf @@ -0,0 +1,7 @@ +output "resource_group_name" { + value = azurerm_resource_group.tk6.name +} + +output "storage_account_name" { + value = azurerm_storage_account.tk6.name +} \ No newline at end of file diff --git a/modules/resource_group_storage/variables.tf b/modules/resource_group_storage/variables.tf new file mode 100644 index 0000000..86d8bf1 --- /dev/null +++ b/modules/resource_group_storage/variables.tf @@ -0,0 +1,17 @@ +variable "resource_group_name" { + description = "Resource group name" + type = string + default = "tk6" +} + +variable "location" { + description = "Resource group location" + type = string + default = "East US" +} + +variable "storage_account_name" { + description = "Storage account name" + type = string + default = "tk6-storage-account" +} \ No newline at end of file From 5e188eace5489c6a2de75601da8e4645e60fc4c8 Mon Sep 17 00:00:00 2001 From: gaupt Date: Thu, 25 Jul 2024 23:02:19 +0300 Subject: [PATCH 2/5] add EoF --- main.tf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main.tf b/main.tf index 83c898b..6621e87 100644 --- a/main.tf +++ b/main.tf @@ -4,4 +4,4 @@ module "resource_group_storage" { resource_group_name = "example-rg" location = "East US" storage_account_name = "examplestorage" -} \ No newline at end of file +} From 76f6831a9a7250e3105b3ef0e4a238f30a57a829 Mon Sep 17 00:00:00 2001 From: gaupt Date: Fri, 26 Jul 2024 12:45:00 +0300 Subject: [PATCH 3/5] add EoF --- modules/resource_group_storage/outputs.tf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/resource_group_storage/outputs.tf b/modules/resource_group_storage/outputs.tf index b649de9..c607616 100644 --- a/modules/resource_group_storage/outputs.tf +++ b/modules/resource_group_storage/outputs.tf @@ -4,4 +4,4 @@ output "resource_group_name" { output "storage_account_name" { value = azurerm_storage_account.tk6.name -} \ No newline at end of file +} From 73404423969c62009b5bd26354aba8069c38fbff Mon Sep 17 00:00:00 2001 From: gaupt Date: Fri, 26 Jul 2024 12:45:25 +0300 Subject: [PATCH 4/5] add EoF --- modules/resource_group_storage/variables.tf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/resource_group_storage/variables.tf b/modules/resource_group_storage/variables.tf index 86d8bf1..ebccbee 100644 --- a/modules/resource_group_storage/variables.tf +++ b/modules/resource_group_storage/variables.tf @@ -14,4 +14,4 @@ variable "storage_account_name" { description = "Storage account name" type = string default = "tk6-storage-account" -} \ No newline at end of file +} From a55f9020fbe233d0ecd2574813207d45395b78cf Mon Sep 17 00:00:00 2001 From: gaupt Date: Fri, 26 Jul 2024 12:45:48 +0300 Subject: [PATCH 5/5] add EoF --- modules/resource_group_storage/main.tf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/resource_group_storage/main.tf b/modules/resource_group_storage/main.tf index 21ebc0a..5381696 100644 --- a/modules/resource_group_storage/main.tf +++ b/modules/resource_group_storage/main.tf @@ -9,4 +9,4 @@ resource "azurerm_storage_account" "tk6" { location = azurerm_resource_group.tk6.location account_tier = "Standard" account_replication_type = "LRS" -} \ No newline at end of file +}