Skip to content

Unable to import resources using terraform import command #88

Description

@pwolthausen

Description

Unable to import resources using terraform import [resource address] [resource ID]

Actual Behavior

Error is returned showing Error: [resource] (id=) not found

tf import -var-file=variables.tfvars cloudca_instance.cmc[0] cd63b525-0992-4121-b818-89f8b4fc731b
cloudca_instance.cmc[0]: Importing from ID "cd63b525-0992-4121-b818-89f8b4fc731b"...
cloudca_instance.cmc[0]: Import prepared!
  Prepared cloudca_instance for import
cloudca_instance.cmc[0]: Refreshing state... [id=cd63b525-0992-4121-b818-89f8b4fc731b]

Error: Instance (id=) not found

Expected Behavior

I expect the resource to be imported and added to the terraform state file

Replication Case

  1. Manually create a resource in cloud.ca (an instance will do)
  2. Write the equivalent terraform code that would create the instance
  3. use `terraform import [resource_address] [resource ID]

Environment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions