terraform-provider-bigip
terraform-provider-bigip copied to clipboard
Log Profile - Arguments report infrastructure doesn't match the terraform configuration
Environment
- TMOS/Bigip Version: 16.1.4.1
- Terraform Version: v1.7.5
- Terraform bigip provider Version: v1.21.0
Summary
When setting the arguments requestlog_template and responselog_template on bigip_ltm_request_log_profile reports every time with a terraform plan or apply that the real F5 infrastructure is different to the currently stored F5 terraform state.
Steps To Reproduce
- Set a bigip_ltm_request_log_profile with a requestlog_template and a responselog_template.
- It will then be set by
terraform applyon the F5 but then report on the nextterraform applythat the real infrastructure is different from the terraform state and wants to push a change.
Example config
resource "bigip_ltm_request_log_profile" "production-log-profile" {
name = "/Common/production-request-log-profile"
defaults_from = "/Common/request-log"
request_logging = "enabled"
requestlog_template = "test1"
requestlog_pool = bigip_ltm_pool.production-syslog-pool.name
response_logging = "enabled"
responselog_template = "test2"
responselog_error_template = "test3"
responselog_pool = bigip_ltm_pool.production-syslog-pool.name
depends_on = [ bigip_ltm_pool.production-syslog-pool ]
}
Initial update
# module.production.bigip_ltm_request_log_profile.production-log-profile will be updated in-place
~ resource "bigip_ltm_request_log_profile" "production-log-profile" {
id = "/Common/production-request-log-profile"
name = "/Common/production-request-log-profile"
~ requestlog_template = "test" -> "test1"
~ responselog_error_template = "test" -> "test3"
~ responselog_template = "test" -> "test2"
# (5 unchanged attributes hidden)
}
Plan: 0 to add, 1 to change, 0 to destroy.
Do you want to perform these actions?
Terraform will perform the actions described above.
Only 'yes' will be accepted to approve.
Enter a value: yes
module.production.bigip_ltm_request_log_profile.production-log-profile: Modifying... [id=/Common/production-request-log-profile]
module.production.bigip_ltm_request_log_profile.production-log-profile: Modifications complete after 0s [id=/Common/production-request-log-profile]
Running terraform apply immediately after
# module.production.bigip_ltm_request_log_profile.production-log-profile will be updated in-place
~ resource "bigip_ltm_request_log_profile" "production-log-profile" {
id = "/Common/production-request-log-profile"
name = "/Common/production-request-log-profile"
~ responselog_error_template = "test1" -> "test3"
~ responselog_template = "test1" -> "test2"
# (6 unchanged attributes hidden)
}
Expected Behavior
- Set the requestlog_template and responselog_template argument
- Arguments are set and report that the real infrastructure matches the terraform state.
Actual Behavior
- Set the requestlog_template and responselog_template variables
- Arguments are set on the F5 and report a change with the original value being the
requestlog_templatearguments value even though F5 has the correct values.