-
Notifications
You must be signed in to change notification settings - Fork 123
Description
Situation 1: Mandatory Definition of All Integration Inputs
Customer is encountering an "issue" where they must explicitly define all integration inputs within their Fleet Terraform configurations, even for those that are not enabled. This is necessary to prevent Terraform from showing diffs between plans. For example, in the AWS integration, which offers 50 different inputs, they only enable 4. Despite this, they need to define every input, importing their default values, to avoid plan discrepancies.
Here's an example of the issue with a disabled input still needing to be defined:
resource "elasticstack_fleet_integration_policy" "server-system" {
name = "system"
namespace = "default"
description = "example"
agent_policy_id = elasticstack_fleet_agent_policy.server_policy.id
integration_name = elasticstack_fleet_integration.this["system"].name
integration_version = elasticstack_fleet_integration.this["system"].version
input {
enabled = true
input_id = "system-logfile"
streams_json = jsonencode(jsondecode(file("integration_configs/server/system/system-logfile.json")))
}
...
input {
enabled = false
input_id = "system-httpjson"
streams_json = jsonencode(jsondecode(file("integration_configs/server/system/system-httpjson.json")))
}
}If customer remove the last input and its associated streams, the plan continuously shows a diff suggesting the removal of the undefined input. This requires customer to "backport" the default streams for all inputs, even disabled ones, and to update them with each integration version change.