func resourceVIXVMCreate(d *schema.ResourceData, meta interface{}) error { config := meta.(*Config) vm := new(vix.VM) vm.Provider = config.Product vm.VerifySSL = config.VerifySSL if err := tf_to_vix(d, vm); err != nil { return err } id, err := vm.Create() if err != nil { return err } log.Printf("[DEBUG] Resource ID: %s\n", id) d.SetId(id) // Initialize the connection info d.SetConnInfo(map[string]string{ "type": "ssh", "host": vm.IPAddress, }) return resourceVIXVMRead(d, meta) }