I am trying to create an instance of OpenStack using Terraform, but I am getting the following error:
Error applying plan: 1 error(s) occurred: * openstack_compute_instance_v2.basic: Error creating OpenStack server: Invalid request due to incorrect syntax or missing required parameters. Terraform does not automatically rollback in the face of errors. Instead, your Terraform state file has been partially updated with
but the same Terraform code successfully creates a security group, a pair of keys and volumes in my OpenStack account
Here is my Terraform code:
provider "openstack" { user_name = "admin" tenant_name = "admin" password = "admin" auth_url = "http://my_IP():5000/v2.0" } resource "openstack_blockstorage_volume_v1" "myvol" { name = "myvol" size = 1 } resource "openstack_compute_instance_v2" "basic" { name = "basic" image_id = "8ce1c922-ad0-81a3-823ea1b0af9b" flavor_id = "2" key_pair = "tf-keypair-1" security_groups = ["default"] metadata { this = "that" } network { name = "8b510300-610a--9cc3-6e76e33395b4" } volume { volume_id = "${openstack_blockstorage_volume_v1.myvol.id}" } }
source share