From 2f5bd9590398cd0d0bf51e93065941a42cc63224 Mon Sep 17 00:00:00 2001 From: Philippe Caseiro Date: Mon, 22 Mar 2021 21:21:48 +0100 Subject: [PATCH] Try to fix network id issue --- terraform/main.tf | 2 +- terraform/modules/virtualMachine/main.tf | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/terraform/main.tf b/terraform/main.tf index 25bf0e4..e106866 100644 --- a/terraform/main.tf +++ b/terraform/main.tf @@ -69,7 +69,7 @@ module "vms" { data_image_source = "" depends = [ - opennebula_virtual_network["vnet"] + opennebula_virtual_network.vnet["internet"].id ] } diff --git a/terraform/modules/virtualMachine/main.tf b/terraform/modules/virtualMachine/main.tf index 0e06c65..d3ea601 100644 --- a/terraform/modules/virtualMachine/main.tf +++ b/terraform/modules/virtualMachine/main.tf @@ -71,7 +71,7 @@ resource "opennebula_template" "vm_template" { for_each = var.network_interfaces content { - network_id = nic.value.network_id + network_name = nic.value.network_name model = "virtio" ip = nic.value.ip }