Added aztexport of template project
This commit is contained in:
parent
e3f5954739
commit
148b9c3166
|
@ -0,0 +1,22 @@
|
||||||
|
# This file is maintained automatically by "terraform init".
|
||||||
|
# Manual edits may be lost in future updates.
|
||||||
|
|
||||||
|
provider "registry.terraform.io/hashicorp/azurerm" {
|
||||||
|
version = "3.65.0"
|
||||||
|
constraints = "3.65.0"
|
||||||
|
hashes = [
|
||||||
|
"h1:Wpq9+x8PynJqzfxaI1hnxhFgHSXkCz07UqroUVJCseU=",
|
||||||
|
"zh:0077d19c1cbd8916a6d96bad17e72f88535ac207fb7f88b714c6fc6da736f80d",
|
||||||
|
"zh:084f9de2f0f84e6508f81b6578ff195afeed79e5d18a0c8d2348abd7d22611c9",
|
||||||
|
"zh:0ea05826c0f9d2e4a5a9887e6d182ba1a5db6eba52b22eb45f0b8576d2d5ddb5",
|
||||||
|
"zh:5142f9cf59f8152bdb9debcdc39c04cb4ca8b26bd50e44f4605b2bcdc4fc514e",
|
||||||
|
"zh:67af71aa233dbe5e2ce59f8b8aa02a7ce71f55b4389dc6bdd1c85e463f810f37",
|
||||||
|
"zh:785b2c4845a0e99fc1a00d1c293cee49cf150a4f1a83d86632dd3fcd9e953d9c",
|
||||||
|
"zh:aae6352ff80d760bebd2148cd86a544cd6df8e1e5abd6d472143e40875983428",
|
||||||
|
"zh:aff6914ad258d27781ba66a915ef714a3f0d31136eeb06b12ed2220cc6530b4b",
|
||||||
|
"zh:b21ca9e271db7a57e5f08bf2b47bd8db291faf699fabf14bb38d4a73a9a05c21",
|
||||||
|
"zh:c8ff94c42249a9fdab87b6c974d6eb59af4c01c955cd76279b7a4f66eacd9754",
|
||||||
|
"zh:f4053b76a6efd46f79b45098c3e3df06b8e6340532970c91d1a9ead63dcf72b6",
|
||||||
|
"zh:f569b65999264a9416862bca5cd2a6177d94ccb0424f3a4ef424428912b9cb3c",
|
||||||
|
]
|
||||||
|
}
|
|
@ -0,0 +1,132 @@
|
||||||
|
{
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/VARONIS-ASSIGNMENT-03/providers/Microsoft.Compute/virtualMachines/TMPL-USE-VM1": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/VARONIS-ASSIGNMENT-03/providers/Microsoft.Compute/virtualMachines/TMPL-USE-VM1",
|
||||||
|
"resource_type": "azurerm_linux_virtual_machine",
|
||||||
|
"resource_name": "res-0"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03",
|
||||||
|
"resource_type": "azurerm_resource_group",
|
||||||
|
"resource_name": "res-1"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Compute/virtualMachines/tmpl-eun-vm01": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Compute/virtualMachines/tmpl-eun-vm01",
|
||||||
|
"resource_type": "azurerm_linux_virtual_machine",
|
||||||
|
"resource_name": "res-2"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/loadBalancers/tmpl-eun-lb": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/loadBalancers/tmpl-eun-lb",
|
||||||
|
"resource_type": "azurerm_lb",
|
||||||
|
"resource_name": "res-3"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/loadBalancers/tmpl-eun-lb/backendAddressPools/tmpl-eun-be-pool": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/loadBalancers/tmpl-eun-lb/backendAddressPools/tmpl-eun-be-pool",
|
||||||
|
"resource_type": "azurerm_lb_backend_address_pool",
|
||||||
|
"resource_name": "res-4"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/loadBalancers/tmpl-use-lb": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/loadBalancers/tmpl-use-lb",
|
||||||
|
"resource_type": "azurerm_lb",
|
||||||
|
"resource_name": "res-5"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/loadBalancers/tmpl-use-lb/backendAddressPools/tmpl-use-be-pool": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/loadBalancers/tmpl-use-lb/backendAddressPools/tmpl-use-be-pool",
|
||||||
|
"resource_type": "azurerm_lb_backend_address_pool",
|
||||||
|
"resource_name": "res-6"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkInterfaces/tmpl-eun-vm01457": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkInterfaces/tmpl-eun-vm01457",
|
||||||
|
"resource_type": "azurerm_network_interface",
|
||||||
|
"resource_name": "res-7"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkInterfaces/tmpl-eun-vm01457/ipConfigurations/ipconfig1/loadBalancerBackendAddressPools/L3N1YnNjcmlwdGlvbnMvY2VkNjE5OTEtMDljZi00ZTE5LWE3NzMtZmE0NTQ2MDllMWVkL3Jlc291cmNlR3JvdXBzL3Zhcm9uaXMtYXNzaWdubWVudC0wMy9wcm92aWRlcnMvTWljcm9zb2Z0Lk5ldHdvcmsvbG9hZEJhbGFuY2Vycy90bXBsLWV1bi1sYi9iYWNrZW5kQWRkcmVzc1Bvb2xzL3RtcGwtZXVuLWJlLXBvb2w=": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkInterfaces/tmpl-eun-vm01457/ipConfigurations/ipconfig1|/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/loadBalancers/tmpl-eun-lb/backendAddressPools/tmpl-eun-be-pool",
|
||||||
|
"resource_type": "azurerm_network_interface_backend_address_pool_association",
|
||||||
|
"resource_name": "res-8"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkInterfaces/tmpl-eun-vm01457/networkSecurityGroups/L3N1YnNjcmlwdGlvbnMvY2VkNjE5OTEtMDljZi00ZTE5LWE3NzMtZmE0NTQ2MDllMWVkL3Jlc291cmNlR3JvdXBzL3Zhcm9uaXMtYXNzaWdubWVudC0wMy9wcm92aWRlcnMvTWljcm9zb2Z0Lk5ldHdvcmsvbmV0d29ya1NlY3VyaXR5R3JvdXBzL3RtcGwtZXVuLXZtMDEtbnNn": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkInterfaces/tmpl-eun-vm01457|/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkSecurityGroups/tmpl-eun-vm01-nsg",
|
||||||
|
"resource_type": "azurerm_network_interface_security_group_association",
|
||||||
|
"resource_name": "res-9"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkInterfaces/tmpl-use-vm1329": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkInterfaces/tmpl-use-vm1329",
|
||||||
|
"resource_type": "azurerm_network_interface",
|
||||||
|
"resource_name": "res-10"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkInterfaces/tmpl-use-vm1329/ipConfigurations/ipconfig1/loadBalancerBackendAddressPools/L3N1YnNjcmlwdGlvbnMvY2VkNjE5OTEtMDljZi00ZTE5LWE3NzMtZmE0NTQ2MDllMWVkL3Jlc291cmNlR3JvdXBzL3Zhcm9uaXMtYXNzaWdubWVudC0wMy9wcm92aWRlcnMvTWljcm9zb2Z0Lk5ldHdvcmsvbG9hZEJhbGFuY2Vycy90bXBsLXVzZS1sYi9iYWNrZW5kQWRkcmVzc1Bvb2xzL3RtcGwtdXNlLWJlLXBvb2w=": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkInterfaces/tmpl-use-vm1329/ipConfigurations/ipconfig1|/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/loadBalancers/tmpl-use-lb/backendAddressPools/tmpl-use-be-pool",
|
||||||
|
"resource_type": "azurerm_network_interface_backend_address_pool_association",
|
||||||
|
"resource_name": "res-11"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkInterfaces/tmpl-use-vm1329/networkSecurityGroups/L3N1YnNjcmlwdGlvbnMvY2VkNjE5OTEtMDljZi00ZTE5LWE3NzMtZmE0NTQ2MDllMWVkL3Jlc291cmNlR3JvdXBzL3Zhcm9uaXMtYXNzaWdubWVudC0wMy9wcm92aWRlcnMvTWljcm9zb2Z0Lk5ldHdvcmsvbmV0d29ya1NlY3VyaXR5R3JvdXBzL3RtcGwtdXNlLXZtMS1uc2c=": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkInterfaces/tmpl-use-vm1329|/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkSecurityGroups/tmpl-use-vm1-nsg",
|
||||||
|
"resource_type": "azurerm_network_interface_security_group_association",
|
||||||
|
"resource_name": "res-12"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkSecurityGroups/tmpl-eun-vm01-nsg": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkSecurityGroups/tmpl-eun-vm01-nsg",
|
||||||
|
"resource_type": "azurerm_network_security_group",
|
||||||
|
"resource_name": "res-13"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkSecurityGroups/tmpl-eun-vm01-nsg/securityRules/SSH": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkSecurityGroups/tmpl-eun-vm01-nsg/securityRules/SSH",
|
||||||
|
"resource_type": "azurerm_network_security_rule",
|
||||||
|
"resource_name": "res-14"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkSecurityGroups/tmpl-use-vm1-nsg": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkSecurityGroups/tmpl-use-vm1-nsg",
|
||||||
|
"resource_type": "azurerm_network_security_group",
|
||||||
|
"resource_name": "res-15"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkSecurityGroups/tmpl-use-vm1-nsg/securityRules/SSH": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkSecurityGroups/tmpl-use-vm1-nsg/securityRules/SSH",
|
||||||
|
"resource_type": "azurerm_network_security_rule",
|
||||||
|
"resource_name": "res-16"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/publicIPAddresses/tmpl-eun-public-ip": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/publicIPAddresses/tmpl-eun-public-ip",
|
||||||
|
"resource_type": "azurerm_public_ip",
|
||||||
|
"resource_name": "res-17"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/publicIPAddresses/tmpl-eun-vm01-ip": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/publicIPAddresses/tmpl-eun-vm01-ip",
|
||||||
|
"resource_type": "azurerm_public_ip",
|
||||||
|
"resource_name": "res-18"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/publicIPAddresses/tmpl-use-public-ip": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/publicIPAddresses/tmpl-use-public-ip",
|
||||||
|
"resource_type": "azurerm_public_ip",
|
||||||
|
"resource_name": "res-19"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/publicIPAddresses/tmpl-use-vm1-ip": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/publicIPAddresses/tmpl-use-vm1-ip",
|
||||||
|
"resource_type": "azurerm_public_ip",
|
||||||
|
"resource_name": "res-20"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/trafficmanagerprofiles/tmpl-traffic-mgr": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/trafficManagerProfiles/tmpl-traffic-mgr",
|
||||||
|
"resource_type": "azurerm_traffic_manager_profile",
|
||||||
|
"resource_name": "res-21"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/virtualNetworks/tmpl-eun-vm01-vnet": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/virtualNetworks/tmpl-eun-vm01-vnet",
|
||||||
|
"resource_type": "azurerm_virtual_network",
|
||||||
|
"resource_name": "res-22"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/virtualNetworks/tmpl-eun-vm01-vnet/subnets/default": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/virtualNetworks/tmpl-eun-vm01-vnet/subnets/default",
|
||||||
|
"resource_type": "azurerm_subnet",
|
||||||
|
"resource_name": "res-23"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/virtualNetworks/tmpl-use-vm1-vnet": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/virtualNetworks/tmpl-use-vm1-vnet",
|
||||||
|
"resource_type": "azurerm_virtual_network",
|
||||||
|
"resource_name": "res-24"
|
||||||
|
},
|
||||||
|
"/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/virtualNetworks/tmpl-use-vm1-vnet/subnets/default": {
|
||||||
|
"resource_id": "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/virtualNetworks/tmpl-use-vm1-vnet/subnets/default",
|
||||||
|
"resource_type": "azurerm_subnet",
|
||||||
|
"resource_name": "res-25"
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,311 @@
|
||||||
|
resource "azurerm_linux_virtual_machine" "res-0" {
|
||||||
|
admin_username = "sz"
|
||||||
|
location = "eastus"
|
||||||
|
name = "TMPL-USE-VM1"
|
||||||
|
network_interface_ids = ["/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkInterfaces/tmpl-use-vm1329"]
|
||||||
|
resource_group_name = "VARONIS-ASSIGNMENT-03"
|
||||||
|
secure_boot_enabled = true
|
||||||
|
size = "Standard_B1s"
|
||||||
|
vtpm_enabled = true
|
||||||
|
admin_ssh_key {
|
||||||
|
public_key = "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDYnCJkpvIoEzjoYBmGKekFXGEOOlfcxD3RTtoYYy+b8PTVeyhY609UTn713hUxC/WKtY2QZgxs02GMmPfkqDTnt8JiD+PRMANBwYZPEe3BkuLoLFznFAb81ATpNbhqX26yauYLDSfoqUZ2EoRoKZvgKu0woNUrEHcQ1/Be28lF3vHdHga+Xo3xsH7cxIl5yHlbgfgtSPlqPckuiuu+V0I8rsPSW+fiP4NqZWjirm85QQPh0+CriFm5N+EKRhanLN+w5O//Ev0ZgOMR8CX+S62BqqG+DiW11irL7//1Z0oeRuBaeiuw1H5g38Gk6PFX1+GjaBm5bAg/ymej5f+F3HBpMvpSFKcUhe1hoqDP2cy6kSTGjl5HxOmL9uclq9NApyw+einkvL/t69ET1OzN4LMTjQjeWLzmrouG5suarhVlp8Lrup3/L6AaPyN2I81+lFlOTh2PJMlPlxtzcD1lT8IFhb7OFuk1Y7fC/gzDVgmH6E1Gqsw4+eg3k0IsdNZxa5M= szkolnik@Sygin"
|
||||||
|
username = "sz"
|
||||||
|
}
|
||||||
|
boot_diagnostics {
|
||||||
|
}
|
||||||
|
os_disk {
|
||||||
|
caching = "ReadWrite"
|
||||||
|
storage_account_type = "Premium_LRS"
|
||||||
|
}
|
||||||
|
source_image_reference {
|
||||||
|
offer = "0001-com-ubuntu-server-jammy"
|
||||||
|
publisher = "canonical"
|
||||||
|
sku = "22_04-lts-gen2"
|
||||||
|
version = "latest"
|
||||||
|
}
|
||||||
|
depends_on = [
|
||||||
|
azurerm_network_interface.res-10,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_resource_group" "res-1" {
|
||||||
|
location = "northeurope"
|
||||||
|
name = "varonis-assignment-03"
|
||||||
|
}
|
||||||
|
resource "azurerm_linux_virtual_machine" "res-2" {
|
||||||
|
admin_username = "sz"
|
||||||
|
location = "northeurope"
|
||||||
|
name = "tmpl-eun-vm01"
|
||||||
|
network_interface_ids = ["/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkInterfaces/tmpl-eun-vm01457"]
|
||||||
|
resource_group_name = "varonis-assignment-03"
|
||||||
|
secure_boot_enabled = true
|
||||||
|
size = "Standard_B1s"
|
||||||
|
vtpm_enabled = true
|
||||||
|
admin_ssh_key {
|
||||||
|
public_key = "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDYnCJkpvIoEzjoYBmGKekFXGEOOlfcxD3RTtoYYy+b8PTVeyhY609UTn713hUxC/WKtY2QZgxs02GMmPfkqDTnt8JiD+PRMANBwYZPEe3BkuLoLFznFAb81ATpNbhqX26yauYLDSfoqUZ2EoRoKZvgKu0woNUrEHcQ1/Be28lF3vHdHga+Xo3xsH7cxIl5yHlbgfgtSPlqPckuiuu+V0I8rsPSW+fiP4NqZWjirm85QQPh0+CriFm5N+EKRhanLN+w5O//Ev0ZgOMR8CX+S62BqqG+DiW11irL7//1Z0oeRuBaeiuw1H5g38Gk6PFX1+GjaBm5bAg/ymej5f+F3HBpMvpSFKcUhe1hoqDP2cy6kSTGjl5HxOmL9uclq9NApyw+einkvL/t69ET1OzN4LMTjQjeWLzmrouG5suarhVlp8Lrup3/L6AaPyN2I81+lFlOTh2PJMlPlxtzcD1lT8IFhb7OFuk1Y7fC/gzDVgmH6E1Gqsw4+eg3k0IsdNZxa5M= szkolnik@Sygin"
|
||||||
|
username = "sz"
|
||||||
|
}
|
||||||
|
boot_diagnostics {
|
||||||
|
}
|
||||||
|
os_disk {
|
||||||
|
caching = "ReadWrite"
|
||||||
|
storage_account_type = "Premium_LRS"
|
||||||
|
}
|
||||||
|
source_image_reference {
|
||||||
|
offer = "0001-com-ubuntu-server-jammy"
|
||||||
|
publisher = "canonical"
|
||||||
|
sku = "22_04-lts-gen2"
|
||||||
|
version = "latest"
|
||||||
|
}
|
||||||
|
depends_on = [
|
||||||
|
azurerm_network_interface.res-7,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_lb" "res-3" {
|
||||||
|
location = "northeurope"
|
||||||
|
name = "tmpl-eun-lb"
|
||||||
|
resource_group_name = "varonis-assignment-03"
|
||||||
|
sku = "Standard"
|
||||||
|
frontend_ip_configuration {
|
||||||
|
name = "tmpl-eun-fe-ip-conf"
|
||||||
|
}
|
||||||
|
depends_on = [
|
||||||
|
azurerm_resource_group.res-1,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_lb_backend_address_pool" "res-4" {
|
||||||
|
loadbalancer_id = "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/loadBalancers/tmpl-eun-lb"
|
||||||
|
name = "tmpl-eun-be-pool"
|
||||||
|
depends_on = [
|
||||||
|
azurerm_lb.res-3,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_lb" "res-5" {
|
||||||
|
location = "eastus"
|
||||||
|
name = "tmpl-use-lb"
|
||||||
|
resource_group_name = "varonis-assignment-03"
|
||||||
|
sku = "Standard"
|
||||||
|
frontend_ip_configuration {
|
||||||
|
name = "tmpl-use-fe-ip-conf"
|
||||||
|
}
|
||||||
|
depends_on = [
|
||||||
|
azurerm_resource_group.res-1,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_lb_backend_address_pool" "res-6" {
|
||||||
|
loadbalancer_id = "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/loadBalancers/tmpl-use-lb"
|
||||||
|
name = "tmpl-use-be-pool"
|
||||||
|
depends_on = [
|
||||||
|
azurerm_lb.res-5,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_network_interface" "res-7" {
|
||||||
|
location = "northeurope"
|
||||||
|
name = "tmpl-eun-vm01457"
|
||||||
|
resource_group_name = "varonis-assignment-03"
|
||||||
|
ip_configuration {
|
||||||
|
name = "ipconfig1"
|
||||||
|
private_ip_address_allocation = "Dynamic"
|
||||||
|
public_ip_address_id = "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/publicIPAddresses/tmpl-eun-vm01-ip"
|
||||||
|
subnet_id = "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/virtualNetworks/tmpl-eun-vm01-vnet/subnets/default"
|
||||||
|
}
|
||||||
|
depends_on = [
|
||||||
|
azurerm_public_ip.res-18,
|
||||||
|
azurerm_subnet.res-23,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_network_interface_backend_address_pool_association" "res-8" {
|
||||||
|
backend_address_pool_id = "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/loadBalancers/tmpl-eun-lb/backendAddressPools/tmpl-eun-be-pool"
|
||||||
|
ip_configuration_name = "ipconfig1"
|
||||||
|
network_interface_id = "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkInterfaces/tmpl-eun-vm01457"
|
||||||
|
depends_on = [
|
||||||
|
azurerm_lb_backend_address_pool.res-4,
|
||||||
|
azurerm_network_interface.res-7,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_network_interface_security_group_association" "res-9" {
|
||||||
|
network_interface_id = "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkInterfaces/tmpl-eun-vm01457"
|
||||||
|
network_security_group_id = "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkSecurityGroups/tmpl-eun-vm01-nsg"
|
||||||
|
depends_on = [
|
||||||
|
azurerm_network_interface.res-7,
|
||||||
|
azurerm_network_security_group.res-13,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_network_interface" "res-10" {
|
||||||
|
location = "eastus"
|
||||||
|
name = "tmpl-use-vm1329"
|
||||||
|
resource_group_name = "varonis-assignment-03"
|
||||||
|
ip_configuration {
|
||||||
|
name = "ipconfig1"
|
||||||
|
private_ip_address_allocation = "Dynamic"
|
||||||
|
public_ip_address_id = "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/publicIPAddresses/tmpl-use-vm1-ip"
|
||||||
|
subnet_id = "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/virtualNetworks/tmpl-use-vm1-vnet/subnets/default"
|
||||||
|
}
|
||||||
|
depends_on = [
|
||||||
|
azurerm_public_ip.res-20,
|
||||||
|
azurerm_subnet.res-25,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_network_interface_backend_address_pool_association" "res-11" {
|
||||||
|
backend_address_pool_id = "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/loadBalancers/tmpl-use-lb/backendAddressPools/tmpl-use-be-pool"
|
||||||
|
ip_configuration_name = "ipconfig1"
|
||||||
|
network_interface_id = "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkInterfaces/tmpl-use-vm1329"
|
||||||
|
depends_on = [
|
||||||
|
azurerm_lb_backend_address_pool.res-6,
|
||||||
|
azurerm_network_interface.res-10,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_network_interface_security_group_association" "res-12" {
|
||||||
|
network_interface_id = "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkInterfaces/tmpl-use-vm1329"
|
||||||
|
network_security_group_id = "/subscriptions/ced61991-09cf-4e19-a773-fa454609e1ed/resourceGroups/varonis-assignment-03/providers/Microsoft.Network/networkSecurityGroups/tmpl-use-vm1-nsg"
|
||||||
|
depends_on = [
|
||||||
|
azurerm_network_interface.res-10,
|
||||||
|
azurerm_network_security_group.res-15,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_network_security_group" "res-13" {
|
||||||
|
location = "northeurope"
|
||||||
|
name = "tmpl-eun-vm01-nsg"
|
||||||
|
resource_group_name = "varonis-assignment-03"
|
||||||
|
depends_on = [
|
||||||
|
azurerm_resource_group.res-1,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_network_security_rule" "res-14" {
|
||||||
|
access = "Allow"
|
||||||
|
destination_address_prefix = "*"
|
||||||
|
destination_port_range = "22"
|
||||||
|
direction = "Inbound"
|
||||||
|
name = "SSH"
|
||||||
|
network_security_group_name = "tmpl-eun-vm01-nsg"
|
||||||
|
priority = 300
|
||||||
|
protocol = "Tcp"
|
||||||
|
resource_group_name = "varonis-assignment-03"
|
||||||
|
source_address_prefix = "*"
|
||||||
|
source_port_range = "*"
|
||||||
|
depends_on = [
|
||||||
|
azurerm_network_security_group.res-13,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_network_security_group" "res-15" {
|
||||||
|
location = "eastus"
|
||||||
|
name = "tmpl-use-vm1-nsg"
|
||||||
|
resource_group_name = "varonis-assignment-03"
|
||||||
|
depends_on = [
|
||||||
|
azurerm_resource_group.res-1,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_network_security_rule" "res-16" {
|
||||||
|
access = "Allow"
|
||||||
|
destination_address_prefix = "*"
|
||||||
|
destination_port_range = "22"
|
||||||
|
direction = "Inbound"
|
||||||
|
name = "SSH"
|
||||||
|
network_security_group_name = "tmpl-use-vm1-nsg"
|
||||||
|
priority = 300
|
||||||
|
protocol = "Tcp"
|
||||||
|
resource_group_name = "varonis-assignment-03"
|
||||||
|
source_address_prefix = "*"
|
||||||
|
source_port_range = "*"
|
||||||
|
depends_on = [
|
||||||
|
azurerm_network_security_group.res-15,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_public_ip" "res-17" {
|
||||||
|
allocation_method = "Static"
|
||||||
|
domain_name_label = "tmpl-eun-lb-addr"
|
||||||
|
location = "northeurope"
|
||||||
|
name = "tmpl-eun-public-ip"
|
||||||
|
resource_group_name = "varonis-assignment-03"
|
||||||
|
sku = "Standard"
|
||||||
|
zones = ["1", "2", "3"]
|
||||||
|
depends_on = [
|
||||||
|
azurerm_resource_group.res-1,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_public_ip" "res-18" {
|
||||||
|
allocation_method = "Static"
|
||||||
|
domain_name_label = "tmpl-eun-vm1"
|
||||||
|
location = "northeurope"
|
||||||
|
name = "tmpl-eun-vm01-ip"
|
||||||
|
resource_group_name = "varonis-assignment-03"
|
||||||
|
sku = "Standard"
|
||||||
|
depends_on = [
|
||||||
|
azurerm_resource_group.res-1,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_public_ip" "res-19" {
|
||||||
|
allocation_method = "Static"
|
||||||
|
domain_name_label = "tmpl-use-lb-addr"
|
||||||
|
location = "eastus"
|
||||||
|
name = "tmpl-use-public-ip"
|
||||||
|
resource_group_name = "varonis-assignment-03"
|
||||||
|
sku = "Standard"
|
||||||
|
zones = ["1", "2", "3"]
|
||||||
|
depends_on = [
|
||||||
|
azurerm_resource_group.res-1,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_public_ip" "res-20" {
|
||||||
|
allocation_method = "Static"
|
||||||
|
domain_name_label = "tmpl-use-vm1"
|
||||||
|
location = "eastus"
|
||||||
|
name = "tmpl-use-vm1-ip"
|
||||||
|
resource_group_name = "varonis-assignment-03"
|
||||||
|
sku = "Standard"
|
||||||
|
depends_on = [
|
||||||
|
azurerm_resource_group.res-1,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_traffic_manager_profile" "res-21" {
|
||||||
|
name = "tmpl-traffic-mgr"
|
||||||
|
resource_group_name = "varonis-assignment-03"
|
||||||
|
traffic_routing_method = "Geographic"
|
||||||
|
dns_config {
|
||||||
|
relative_name = "tmpl-traffic-mgr"
|
||||||
|
ttl = 60
|
||||||
|
}
|
||||||
|
monitor_config {
|
||||||
|
path = "/"
|
||||||
|
port = 443
|
||||||
|
protocol = "HTTP"
|
||||||
|
}
|
||||||
|
depends_on = [
|
||||||
|
azurerm_resource_group.res-1,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_virtual_network" "res-22" {
|
||||||
|
address_space = ["10.0.0.0/16"]
|
||||||
|
location = "northeurope"
|
||||||
|
name = "tmpl-eun-vm01-vnet"
|
||||||
|
resource_group_name = "varonis-assignment-03"
|
||||||
|
depends_on = [
|
||||||
|
azurerm_resource_group.res-1,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_subnet" "res-23" {
|
||||||
|
address_prefixes = ["10.0.0.0/24"]
|
||||||
|
name = "default"
|
||||||
|
resource_group_name = "varonis-assignment-03"
|
||||||
|
virtual_network_name = "tmpl-eun-vm01-vnet"
|
||||||
|
depends_on = [
|
||||||
|
azurerm_virtual_network.res-22,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_virtual_network" "res-24" {
|
||||||
|
address_space = ["10.1.0.0/16"]
|
||||||
|
location = "eastus"
|
||||||
|
name = "tmpl-use-vm1-vnet"
|
||||||
|
resource_group_name = "varonis-assignment-03"
|
||||||
|
depends_on = [
|
||||||
|
azurerm_resource_group.res-1,
|
||||||
|
]
|
||||||
|
}
|
||||||
|
resource "azurerm_subnet" "res-25" {
|
||||||
|
address_prefixes = ["10.1.0.0/24"]
|
||||||
|
name = "default"
|
||||||
|
resource_group_name = "varonis-assignment-03"
|
||||||
|
virtual_network_name = "tmpl-use-vm1-vnet"
|
||||||
|
depends_on = [
|
||||||
|
azurerm_virtual_network.res-24,
|
||||||
|
]
|
||||||
|
}
|
|
@ -0,0 +1,4 @@
|
||||||
|
provider "azurerm" {
|
||||||
|
features {
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,9 @@
|
||||||
|
terraform {
|
||||||
|
backend "local" {}
|
||||||
|
required_providers {
|
||||||
|
azurerm = {
|
||||||
|
source = "hashicorp/azurerm"
|
||||||
|
version = "3.65.0"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue