Skip to content

Commit

Permalink
Merge pull request #855 from solarwinds/collect-provider-specific-inf…
Browse files Browse the repository at this point in the history
…ormation-helm

getting provider information using new processor
  • Loading branch information
mpecenka authored Jan 6, 2025
2 parents 55ba5ee + a5535b1 commit 0fbee81
Show file tree
Hide file tree
Showing 3 changed files with 185 additions and 2 deletions.
4 changes: 2 additions & 2 deletions deploy/helm/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
apiVersion: v2
name: swo-k8s-collector
version: 4.3.1
appVersion: 0.12.2
version: 4.4.0-alpha.1
appVersion: 0.12.3
description: SolarWinds Kubernetes Integration
keywords:
- monitoring
Expand Down
39 changes: 39 additions & 0 deletions deploy/helm/events-collector-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -234,6 +234,7 @@ processors:
- key: sw.k8s.log.type
value: event
action: insert

resource/manifest:
attributes:
# Collector and Manifest version
Expand All @@ -257,6 +258,43 @@ processors:
- key: sw.k8s.log.type
value: manifest
action: insert

resourcedetection/providers:
detectors: ["ec2","azure","openshift"]
timeout: 2s
override: false
azure:
# keep: cloud.account.id, cloud.platform, cloud.provider, cloud.region, azure.resourcegroup.name
resource_attributes:
azure.vm.name:
enabled: false
azure.vm.scaleset.name:
enabled: false
azure.vm.size:
enabled: false
host.id:
enabled: false
host.name:
enabled: false
openshift:
# keep: cloud.platform, cloud.provider, cloud.region
resource_attributes:
k8s.cluster.name:
enabled: false
ec2:
# keep: cloud.account.id, cloud.platform, cloud.provider, cloud.region
resource_attributes:
cloud.availability_zone:
enabled: false
host.id:
enabled: false
host.image.id:
enabled: false
host.name:
enabled: false
host.type:
enabled: false

batch:
{{ toYaml .Values.otel.events.batch | indent 4 }}
swk8sattributes:
Expand Down Expand Up @@ -327,6 +365,7 @@ service:
- transform/set_labels_and_annotations_for_entities
- transform/stringify_body
- resource/manifest
- resourcedetection/providers
- swk8sattributes
- transform/cleanup_attributes_for_nonexisting_entities
{{- if not (and .Values.otel.events.enabled .Values.otel.manifests.enabled) }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,41 @@ Custom events filter with new syntax:
- action: insert
key: sw.k8s.log.type
value: manifest
resourcedetection/providers:
azure:
resource_attributes:
azure.vm.name:
enabled: false
azure.vm.scaleset.name:
enabled: false
azure.vm.size:
enabled: false
host.id:
enabled: false
host.name:
enabled: false
detectors:
- ec2
- azure
- openshift
ec2:
resource_attributes:
cloud.availability_zone:
enabled: false
host.id:
enabled: false
host.image.id:
enabled: false
host.name:
enabled: false
host.type:
enabled: false
openshift:
resource_attributes:
k8s.cluster.name:
enabled: false
override: false
timeout: 2s
swk8sattributes:
auth_type: serviceAccount
cronjob:
Expand Down Expand Up @@ -528,6 +563,7 @@ Custom events filter with new syntax:
- transform/set_labels_and_annotations_for_entities
- transform/stringify_body
- resource/manifest
- resourcedetection/providers
- swk8sattributes
- transform/cleanup_attributes_for_nonexisting_entities
- transform/scope
Expand Down Expand Up @@ -635,6 +671,41 @@ Custom events filter with old syntax:
- action: insert
key: sw.k8s.log.type
value: manifest
resourcedetection/providers:
azure:
resource_attributes:
azure.vm.name:
enabled: false
azure.vm.scaleset.name:
enabled: false
azure.vm.size:
enabled: false
host.id:
enabled: false
host.name:
enabled: false
detectors:
- ec2
- azure
- openshift
ec2:
resource_attributes:
cloud.availability_zone:
enabled: false
host.id:
enabled: false
host.image.id:
enabled: false
host.name:
enabled: false
host.type:
enabled: false
openshift:
resource_attributes:
k8s.cluster.name:
enabled: false
override: false
timeout: 2s
swk8sattributes:
auth_type: serviceAccount
cronjob:
Expand Down Expand Up @@ -1072,6 +1143,7 @@ Custom events filter with old syntax:
- transform/set_labels_and_annotations_for_entities
- transform/stringify_body
- resource/manifest
- resourcedetection/providers
- swk8sattributes
- transform/cleanup_attributes_for_nonexisting_entities
- transform/scope
Expand Down Expand Up @@ -1172,6 +1244,41 @@ Events config should match snapshot when using default values:
- action: insert
key: sw.k8s.log.type
value: manifest
resourcedetection/providers:
azure:
resource_attributes:
azure.vm.name:
enabled: false
azure.vm.scaleset.name:
enabled: false
azure.vm.size:
enabled: false
host.id:
enabled: false
host.name:
enabled: false
detectors:
- ec2
- azure
- openshift
ec2:
resource_attributes:
cloud.availability_zone:
enabled: false
host.id:
enabled: false
host.image.id:
enabled: false
host.name:
enabled: false
host.type:
enabled: false
openshift:
resource_attributes:
k8s.cluster.name:
enabled: false
override: false
timeout: 2s
swk8sattributes:
auth_type: serviceAccount
cronjob:
Expand Down Expand Up @@ -1608,6 +1715,7 @@ Events config should match snapshot when using default values:
- transform/set_labels_and_annotations_for_entities
- transform/stringify_body
- resource/manifest
- resourcedetection/providers
- swk8sattributes
- transform/cleanup_attributes_for_nonexisting_entities
- transform/scope
Expand Down Expand Up @@ -1708,6 +1816,41 @@ Events config should not contain manifest collection pipeline when disabled:
- action: insert
key: sw.k8s.log.type
value: manifest
resourcedetection/providers:
azure:
resource_attributes:
azure.vm.name:
enabled: false
azure.vm.scaleset.name:
enabled: false
azure.vm.size:
enabled: false
host.id:
enabled: false
host.name:
enabled: false
detectors:
- ec2
- azure
- openshift
ec2:
resource_attributes:
cloud.availability_zone:
enabled: false
host.id:
enabled: false
host.image.id:
enabled: false
host.name:
enabled: false
host.type:
enabled: false
openshift:
resource_attributes:
k8s.cluster.name:
enabled: false
override: false
timeout: 2s
swk8sattributes:
auth_type: serviceAccount
cronjob:
Expand Down Expand Up @@ -2084,6 +2227,7 @@ Events config should not contain manifest collection pipeline when disabled:
- transform/set_labels_and_annotations_for_entities
- transform/stringify_body
- resource/manifest
- resourcedetection/providers
- swk8sattributes
- transform/cleanup_attributes_for_nonexisting_entities
- filter/k8s_collector_config_include
Expand Down

0 comments on commit 0fbee81

Please sign in to comment.