Skip to content

Implement support for move from unversioned to versioned resource types. #2829

@peak-stephen

Description

@peak-stephen

Description

it's been possible for providers to moving an existing resource to a new resource type since Terraform 1.8 (release notes).

The recent deprecation of all unversioned resources would be a lot simpler to handle if this provider supported that. In my case the project uses terraform HCP which does not allow for the terraform import command, so I either have to live with endless deprecation warnings, or do some very dangerous state-file editing.

Potential Terraform Configuration

moved {
  from = kubernetes_service.whatever
  to = kubernetes_service_v1.whatever
}

References

  1. Terraform 1.8 release notes
  2. Reference for MoveState in terraform plugin development docs: https://developer.hashicorp.com/terraform/plugin/framework/resources/state-move

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions