You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It seems firewall_group_id state is not correctly managed in vultr_instance resource.
I can successfully add a firewall_group_id to an instance (at creation, or after) but I can never unlink it.
To Reproduce
variable "disable_firewall_group_link" {
description = "Does not link the instance to any firewall group"
type = bool
default = false
}
variable "firewall_group_to_link" {
description = "Name of the firewall group the instance should be linked"
type = string
default = "instance-rules"
}
data "vultr_firewall_group" "instance_firewall_group" {
count = var.disable_firewall_group_link ? 0 : 1
filter {
name = "description"
values = [var.firewall_group_to_link]
}
}
# in vultr_instance resource
firewall_group_id = var.disable_firewall_group_link ? null : data.vultr_firewall_group.instance_firewall_group[0].id
Expected behavior
I expect the instance to be unlinked from the firewall group when my boolean variable is set to true.
I also modified my module to have just
firewall_group_id = null
or even removing the attribute from the resource definition but the instance is never unlinked from the firewall_group.
plan Just show no changes.
The text was updated successfully, but these errors were encountered:
Hello there :)
Describe the bug
It seems
firewall_group_id
state is not correctly managed in vultr_instance resource.I can successfully add a firewall_group_id to an instance (at creation, or after) but I can never unlink it.
To Reproduce
Expected behavior
I expect the instance to be unlinked from the firewall group when my boolean variable is set to true.
I also modified my module to have just
or even removing the attribute from the resource definition but the instance is never unlinked from the firewall_group.
plan Just show no changes.
The text was updated successfully, but these errors were encountered: