Skip to content

Commit 274cb6b

Browse files
authored
Merge pull request #4 from kumarvna/release/relese-2.2.0-remove-provider-dependency
Release/release 2.2.0 remove provider dependency
2 parents 671450b + 32405a0 commit 274cb6b

File tree

9 files changed

+75
-66
lines changed

9 files changed

+75
-66
lines changed

README.md

Lines changed: 16 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,10 @@
22

33
This terraform module is designed to deploy azure Windows or Linux virtual machines with Public IP, Availability Set and Network Security Group support.
44

5-
These types of resources supported:
5+
> **[NOTE]**
6+
> **This module now supports the meta arguments including `providers`, `depends_on`, `count`, and `for_each`.**
7+
8+
## Resources Supported
69

710
* [Linux Virtual Machine](https://www.terraform.io/docs/providers/azurerm/r/linux_virtual_machine.html)
811
* [Windows Virtual Machine](https://www.terraform.io/docs/providers/azurerm/r/windows_virtual_machine.html)
@@ -17,9 +20,14 @@ These types of resources supported:
1720
## Module Usage
1821

1922
```hcl
23+
# Azurerm provider configuration
24+
provider "azurerm" {
25+
features {}
26+
}
27+
2028
module "virtual-machine" {
2129
source = "kumarvna/virtual-machine/azurerm"
22-
version = "2.1.0"
30+
version = "2.2.0"
2331
2432
# Resource Group, location, VNet and Subnet details
2533
resource_group_name = "rg-shared-westeurope-01"
@@ -115,7 +123,7 @@ If the pre-defined Windows or Linux variants are not sufficient then, you can sp
115123
```hcl
116124
module "virtual-machine" {
117125
source = "kumarvna/virtual-machine/azurerm"
118-
version = "2.1.0"
126+
version = "2.2.0"
119127
120128
# .... omitted
121129
@@ -207,7 +215,7 @@ In the Source and Destination columns, `VirtualNetwork`, `AzureLoadBalancer`, an
207215
```hcl
208216
module "virtual-machine" {
209217
source = "kumarvna/virtual-machine/azurerm"
210-
version = "2.1.0"
218+
version = "2.2.0"
211219
212220
# .... omitted
213221
@@ -235,55 +243,14 @@ module "virtual-machine" {
235243

236244
## Recommended naming and tagging conventions
237245

238-
Well-defined naming and metadata tagging conventions help to quickly locate and manage resources. These conventions also help associate cloud usage costs with business teams via chargeback and show back accounting mechanisms.
246+
Applying tags to your Azure resources, resource groups, and subscriptions to logically organize them into a taxonomy. Each tag consists of a name and a value pair. For example, you can apply the name `Environment` and the value `Production` to all the resources in production.
247+
For recommendations on how to implement a tagging strategy, see Resource naming and tagging decision guide.
239248

240-
### Resource naming
249+
>**Important** :
250+
Tag names are case-insensitive for operations. A tag with a tag name, regardless of the casing, is updated or retrieved. However, the resource provider might keep the casing you provide for the tag name. You'll see that casing in cost reports. **Tag values are case-sensitive.**
241251

242252
An effective naming convention assembles resource names by using important resource information as parts of a resource's name. For example, using these [recommended naming conventions](https://docs.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/naming-and-tagging#example-names), a public IP resource for a production SharePoint workload is named like this: `pip-sharepoint-prod-westus-001`.
243253

244-
> ### Metadata tags
245-
246-
When applying metadata tags to the cloud resources, you can include information about those assets that couldn't be included in the resource name. You can use that information to perform more sophisticated filtering and reporting on resources. This information can be used by IT or business teams to find resources or generate reports about resource usage and billing.
247-
248-
The following list provides the recommended common tags that capture important context and information about resources. Use this list as a starting point to establish your tagging conventions.
249-
250-
Tag Name|Description|Key|Example Value|Required?
251-
--------|-----------|---|-------------|---------|
252-
Project Name|Name of the Project for the infra is created. This is mandatory to create a resource names.|ProjectName|{Project name}|Yes
253-
Application Name|Name of the application, service, or workload the resource is associated with.|ApplicationName|{app name}|Yes
254-
Approver|Name Person responsible for approving costs related to this resource.|Approver|{email}|Yes
255-
Business Unit|Top-level division of your company that owns the subscription or workload the resource belongs to. In smaller organizations, this may represent a single corporate or shared top-level organizational element.|BusinessUnit|FINANCE, MARKETING,{Product Name},CORP,SHARED|Yes
256-
Cost Center|Accounting cost center associated with this resource.|CostCenter|{number}|Yes
257-
Disaster Recovery|Business criticality of this application, workload, or service.|DR|Mission Critical, Critical, Essential|Yes
258-
Environment|Deployment environment of this application, workload, or service.|Env|Prod, Dev, QA, Stage, Test|Yes
259-
Owner Name|Owner of the application, workload, or service.|Owner|{email}|Yes
260-
Requester Name|User that requested the creation of this application.|Requestor| {email}|Yes
261-
Service Class|Service Level Agreement level of this application, workload, or service.|ServiceClass|Dev, Bronze, Silver, Gold|Yes
262-
Start Date of the project|Date when this application, workload, or service was first deployed.|StartDate|{date}|No
263-
End Date of the Project|Date when this application, workload, or service is planned to be retired.|EndDate|{date}|No
264-
265-
> This module allows you to manage the above metadata tags directly or as an variable using `variables.tf`. All Azure resources which support tagging can be tagged by specifying key-values in argument `tags`. Tag `ResourceName` is added automatically to all resources.
266-
267-
```hcl
268-
module "virtual-machine" {
269-
source = "kumarvna/virtual-machine/azurerm"
270-
version = "2.1.0"
271-
272-
# Resource Group, location, VNet and Subnet details
273-
resource_group_name = "rg-hub-demo-internal-shared-westeurope-001"
274-
275-
# ... omitted
276-
277-
tags = {
278-
ProjectName = "demo-internal"
279-
Env = "dev"
280-
281-
BusinessUnit = "CORP"
282-
ServiceClass = "Gold"
283-
}
284-
}
285-
```
286-
287254
## Requirements
288255

289256
| Name | Version |

examples/README.md

Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,14 @@ This terraform module is designed to deploy azure Windows or Linux virtual machi
77
### Linux virtual Machine creation
88

99
```hcl
10+
# Azurerm provider configuration
11+
provider "azurerm" {
12+
features {}
13+
}
14+
1015
module "virtual-machine" {
1116
source = "kumarvna/virtual-machine/azurerm"
12-
version = "2.1.0"
17+
version = "2.2.0"
1318
1419
# Resource Group, location, VNet and Subnet details
1520
resource_group_name = "rg-shared-westeurope-01"
@@ -79,9 +84,14 @@ module "virtual-machine" {
7984
### Windows virtual Machine creation
8085

8186
```hcl
87+
# Azurerm provider configuration
88+
provider "azurerm" {
89+
features {}
90+
}
91+
8292
module "virtual-machine" {
8393
source = "kumarvna/virtual-machine/azurerm"
84-
version = "2.1.0"
94+
version = "2.2.0"
8595
8696
# Resource Group, location, VNet and Subnet details
8797
resource_group_name = "rg-shared-westeurope-01"
@@ -151,9 +161,14 @@ module "virtual-machine" {
151161
### MSSQL Windows virtual Machine creation
152162

153163
```hcl
164+
# Azurerm provider configuration
165+
provider "azurerm" {
166+
features {}
167+
}
168+
154169
module "virtual-machine" {
155170
source = "kumarvna/virtual-machine/azurerm"
156-
version = "2.1.0"
171+
version = "2.2.0"
157172
158173
159174
# Resource Group, location, VNet and Subnet details

examples/linux_virtual_machine/README.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,14 @@ This terraform module is designed to deploy azure Linux virtual machines with Pu
55
## Module Usage
66

77
```hcl
8+
# Azurerm provider configuration
9+
provider "azurerm" {
10+
features {}
11+
}
12+
813
module "virtual-machine" {
914
source = "kumarvna/virtual-machine/azurerm"
10-
version = "2.1.0"
15+
version = "2.2.0"
1116
1217
# Resource Group, location, VNet and Subnet details
1318
resource_group_name = "rg-shared-westeurope-01"

examples/linux_virtual_machine/main.tf

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
1+
# Azurerm provider configuration
2+
provider "azurerm" {
3+
features {}
4+
}
5+
16
module "virtual-machine" {
27
source = "kumarvna/virtual-machine/azurerm"
3-
version = "2.1.0"
8+
version = "2.2.0"
49

510
# Resource Group, location, VNet and Subnet details
611
resource_group_name = "rg-shared-westeurope-01"

examples/mssql_windows_virtual_machine/README.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,14 @@ This terraform module is designed to deploy azure MSSQL Windows virtual machines
55
## Module Usage
66

77
```hcl
8+
# Azurerm provider configuration
9+
provider "azurerm" {
10+
features {}
11+
}
12+
813
module "virtual-machine" {
914
source = "kumarvna/virtual-machine/azurerm"
10-
version = "2.1.0"
15+
version = "2.2.0"
1116
1217
1318
# Resource Group, location, VNet and Subnet details

examples/mssql_windows_virtual_machine/main.tf

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
1+
# Azurerm provider configuration
2+
provider "azurerm" {
3+
features {}
4+
}
5+
16
module "virtual-machine" {
27
source = "kumarvna/virtual-machine/azurerm"
3-
version = "2.1.0"
8+
version = "2.2.0"
49

510

611
# Resource Group, location, VNet and Subnet details

examples/windows_virtual_machine/README.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,14 @@ This terraform module is designed to deploy azure Windows virtual machines with
55
## Module Usage
66

77
```hcl
8+
# Azurerm provider configuration
9+
provider "azurerm" {
10+
features {}
11+
}
12+
813
module "virtual-machine" {
914
source = "kumarvna/virtual-machine/azurerm"
10-
version = "2.1.0"
15+
version = "2.2.0"
1116
1217
# Resource Group, location, VNet and Subnet details
1318
resource_group_name = "rg-shared-westeurope-01"

examples/windows_virtual_machine/main.tf

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,12 @@
1+
2+
# Azurerm provider configuration
3+
provider "azurerm" {
4+
features {}
5+
}
6+
17
module "virtual-machine" {
28
source = "kumarvna/virtual-machine/azurerm"
3-
version = "2.1.0"
9+
version = "2.2.0"
410

511
# Resource Group, location, VNet and Subnet details
612
resource_group_name = "rg-shared-westeurope-01"
@@ -26,10 +32,10 @@ module "virtual-machine" {
2632
# RHEL8 images: mssql2019ent-rhel8, mssql2019std-rhel8, mssql2019dev-rhel8
2733
# Ubuntu images: mssql2019ent-ubuntu1804, mssql2019std-ubuntu1804, mssql2019dev-ubuntu1804
2834
# Bring your own License (BOYL) images: mssql2019ent-byol, mssql2019std-byol
29-
os_flavor = "windows"
30-
windows_distribution_name = "windows2019dc"
31-
virtual_machine_size = "Standard_A2_v2"
32-
admin_username = "azureadmin"
35+
os_flavor = "windows"
36+
windows_distribution_name = "windows2019dc"
37+
virtual_machine_size = "Standard_A2_v2"
38+
admin_username = "azureadmin"
3339
admin_password = "P@$$w0rd1234!"
3440
instances_count = 2
3541
enable_vm_availability_set = true

versions.tf

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,3 @@ terraform {
1313
}
1414
required_version = ">= 0.13"
1515
}
16-
17-
provider "azurerm" {
18-
features {}
19-
}

0 commit comments

Comments
 (0)