Class: Kube::Cluster::Standard::VictoriaMetrics::VLAgent
- Inherits:
-
Object
- Object
- Kube::Cluster::Standard::VictoriaMetrics::VLAgent
- Defined in:
- lib/kube/cluster/standard/victoria_metrics/vl_agent.rb
Overview
Collects Kubernetes pod logs and remote-writes them to a VLSingle.
Instance Method Summary collapse
-
#initialize(name:, remote_write_url:, &block) ⇒ VLAgent
constructor
A new instance of VLAgent.
Constructor Details
#initialize(name:, remote_write_url:, &block) ⇒ VLAgent
Returns a new instance of VLAgent.
12 13 14 15 16 17 18 19 20 21 22 23 24 |
# File 'lib/kube/cluster/standard/victoria_metrics/vl_agent.rb', line 12 def initialize(name:, remote_write_url:, &block) super() { .name = name spec.useStrictSecurity = true spec.k8sCollector = { enabled: true, msgFields: %w[msg message log.msg], timeFields: %w[time ts timestamp], } spec.remoteWrite = [{ url: remote_write_url }] instance_exec(&block) if block } end |