This file contains hidden or 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
variable "resource_group_name_prefix" { | |
default = "rg" | |
description = "Prefix of the resource group name" | |
} | |
variable "resource_group_name" { | |
default = "prefix_SomeName" | |
description = "Resource group name" | |
} |
This file contains hidden or 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
terraform { | |
required_providers { | |
azurerm = { | |
source = "hashicorp/azurerm" | |
version = "2.92.0" | |
} | |
} | |
backend "azurerm" { | |
resource_group_name = "${var.resource_group_name}" |
This file contains hidden or 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
output "public_ip_address" { | |
value = azurerm_linux_virtual_machine.yourvmname.public_ip_address | |
} | |
output "azurerm_linux_virtual_machine_name" { | |
value = azurerm_linux_virtual_machine.yourvmname.name | |
} | |
output "resource_group_name" { | |
value = azurerm_linux_virtual_machine.yourvmname.resource_group_name |
This file contains hidden or 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
locals { | |
secrules= { | |
ssh = { | |
name = "SSH" | |
priority = 300 | |
direction = "Inbound" | |
access = "Allow" | |
protocol = "Tcp" | |
source_port_range = "*" | |
destination_port_range = "22" |
This file contains hidden or 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
resource "azurerm_network_interface" "networkinterfacename" { | |
name = "${var.resource_group_name}-department-nic" | |
location = var.vm_location | |
resource_group_name = var.resource_group_name | |
ip_configuration { | |
name = "${var.resource_group_name}-department-IpConfig" | |
subnet_id = azurerm_subnet.subnetname.id | |
private_ip_address_allocation = "Dynamic" | |
} | |
} |
This file contains hidden or 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
- task: Bash@3 | |
displayName: create tunnel | |
inputs: | |
targetType: 'inline' | |
script: | | |
'docker run -w /datadrive -d \ | |
-t saucelabs/sauce-connect:4.7.0 \ | |
-u $(user) \ | |
-k $(key) \ | |
-x https://eu-central-1.saucelabs.com/rest/v1 \ |
This file contains hidden or 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
resource "azurerm_virtual_network" "networkname" { | |
name = "${var.resource_group_name}-deparment-vnet" | |
address_space = ["addressspace/port"] | |
location = var.vm_location | |
resource_group_name = var.resource_group_name | |
} |
This file contains hidden or 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
resource "azurerm_subnet" "subnetname" { | |
name = "${var.resource_group_name}-deparment-subnet" | |
resource_group_name = var.resource_group_name | |
virtual_network_name = azurerm_virtual_network.qanetwork.name | |
address_prefixes = ["addressprefix/port"] | |
} |
This file contains hidden or 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
resource "azurerm_network_interface" "networkinterfacename" { | |
name = "${var.resource_group_name}-department-nic" | |
location = var.vm_location | |
resource_group_name = var.resource_group_name | |
ip_configuration { | |
name = "${var.resource_group_name}-department-IpConfig" | |
subnet_id = azurerm_subnet.subnetname.id | |
private_ip_address_allocation = "Dynamic" | |
} | |
} |
This file contains hidden or 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
resource "azurerm_linux_virtual_machine" "yourvmname" { | |
name = var.azurerm_linux_virtual_machine_name | |
location = var.vm_location | |
resource_group_name = var.resource_group_name | |
network_interface_ids = [azurerm_network_interface.qanic.id] | |
size = "Standard_D2s_v3" | |
os_disk { | |
name = "diskname" | |
caching = "ReadWrite" | |
storage_account_type = "Premium_LRS" |
OlderNewer