Skip to content

[Bug]: delete_protection doesnt work as documented #1206

@simonostendorf

Description

@simonostendorf

What happened?

The delete protection docs state that resources with delete protection can be deleted by terraform and only prevent other api consumers (e.g. the cloud console) to delete the resource.

This is especially useful when using the hcloud-cloud-controller-manager and an existing LoadBalancer that was created with Terraform.

Terraform logs load balancer deletion is protected when trying to delete the load balancer resource.

What did you expect to happen?

I expect the load balancer to be deleted as documented.

Please provide a minimal working example

resource "hcloud_load_balancer" "ingress" {
  name               = "${var.cluster_name}-ingress"
  load_balancer_type = var.ingress.load_balancer.type
  location           = var.ingress.load_balancer.region
  delete_protection  = true # will prevent the hcloud-cloud-controller-manager to delete the lb so that terraform can delete it
}

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