module.linuxservers.provider.azurerm is not present
Closed this issue · 1 comments
writeameer commented
Hi there,
I'm trying out this example here
provider "azurerm" {
version = "~> 1.0"
}
variable "resource_group_name" {
default = "terraform-vmss-cloudinit"
}
variable "location" {
default = "eastus"
}
module "network" {
source = "Azure/network/azurerm"
location = "${var.location}"
resource_group_name = "${var.resource_group_name}"
}
module "loadbalancer" {
source = "Azure/loadbalancer/azurerm"
resource_group_name = "${var.resource_group_name}"
location = "${var.location}"
prefix = "terraform-test"
"remote_port" {
ssh = ["Tcp", "22"]
}
"lb_port" {
http = ["80", "Tcp", "80"]
}
}
module "vmss-cloudinit" {
source = "Azure/vmss-cloudinit/azurerm"
resource_group_name = "${var.resource_group_name}"
cloudconfig_file = "${path.module}/cloudconfig.tpl"
location = "${var.location}"
vm_size = "Standard_DS2_v2"
admin_username = "azureuser"
admin_password = "ComplexPassword"
ssh_key = "~/.ssh/id_rsa.pub"
nb_instance = 2
vm_os_simple = "UbuntuServer"
vnet_subnet_id = "${module.network.vnet_subnets[0]}"
load_balancer_backend_address_pool_ids = "${module.loadbalancer.azurerm_lb_backend_address_pool_id}"
}
output "vmss_id" {
value = "${module.vmss-cloudinit.vmss_id}"
}
and I get the following error:
Error: Error asking for user input: 1 error(s) occurred:
* module.linuxservers.azurerm_resource_group.vm: configuration for module.linuxservers.provider.azurerm is not present; a provider configuration block is required for all operations
Can you please help ? Appreciate any pointers in the right direction.
Thanks.
yupwei68 commented
@writeameer Sorry, this is not using the module "network_security_group
" here, and I need to close it.