Skip to content

Terraform Problems #9

@salvis2

Description

@salvis2

When terraform destroying, I often get:

Error: timeout while waiting for resource to be gone (last state: 'Terminating', timeout: 5m0s)

I think this is waiting for the kubernetes namespaces to be destroyed and it doesn't find them. I can see

kubernetes_namespace.support: Still destroying... [id=support, 5m0s elapsed]

above, but I never see a message that it got destroyed.

There have been two common cases where this occurs:

  1. Something within the namespace is not managed by Terraform (ex. deploying a JupyterHub with hubploy but not removing the hub before running terraform destroy) and actually prevents the namespace from being deleted. This isn't an issue that we can solve here.
  2. The connection between the cluster and the local machine is just bad, so when I go back and run kubectl get ns, I see the namespace is actually gone and I can re-run terraform destroy successfully. This seems like something we should look up solutions for or bring up with Terraform.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions