input {
  elastic_agent {
    port => 5055
    tags => [ "elastic-agent", "input-{{ GLOBALS.hostname }}" ]
    ssl_enabled => true
    ssl_certificate_authorities => ["/usr/share/filebeat/ca.crt"]
    ssl_certificate => "/usr/share/logstash/elasticfleet-logstash.crt"
    ssl_key => "/usr/share/logstash/elasticfleet-logstash.key"
    ssl_client_authentication => "required"
    ecs_compatibility => v8
  }
}
filter {
if ![metadata] {
  mutate {
    rename => {"@metadata" => "metadata"}
  }
}
}

