Skip to content

Commit 7daef52

Browse files
authored
[Tanzu Tile] Add host.name resource attribute (#5810)
1 parent 4558006 commit 7daef52

File tree

4 files changed

+12
-3
lines changed

4 files changed

+12
-3
lines changed

deployments/cloudfoundry/bosh/DEVELOPMENT.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,7 @@ If no configuration file is provided, a template file will be populated using th
8181

8282
Required Properties:
8383

84+
- `cloudfoundry.deployment.hostname`
8485
- `cloudfoundry.rlp_gateway.endpoint`
8586
- `cloudfoundry.uaa.endpoint`
8687
- `cloudfoundry.uaa.password`

deployments/cloudfoundry/bosh/jobs/splunk-otel-collector/spec

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,9 @@ properties:
8282
description: "The Splunk realm in which your organization resides -- used to derive splunk.ingest_url and splunk.api_url if those are not provided"
8383
required: false
8484

85+
cloudfoundry.director.hostname:
86+
description: "The hostname of the Cloud Foundry BOSH director"
87+
8588
cloudfoundry.rlp_gateway.endpoint:
8689
description: "The URL of the RLP Gateway that acts as a proxy for the firehose"
8790

deployments/cloudfoundry/bosh/jobs/splunk-otel-collector/templates/otel-collector-config.yaml.erb

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,11 @@ receivers:
2323
<% end %>
2424

2525
processors:
26-
resourcedetection:
27-
detectors: [system]
26+
resource:
27+
attributes:
28+
- key: host.name
29+
value: <%= p('cloudfoundry.director.hostname') %>
30+
action: upsert
2831

2932
exporters:
3033
signalfx:
@@ -43,6 +46,6 @@ service:
4346
pipelines:
4447
metrics:
4548
receivers: [cloudfoundry]
46-
processors: [resourcedetection]
49+
processors: [resource]
4750
exporters: [signalfx]
4851
<% end %>

deployments/cloudfoundry/tile/tile.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@ packages:
3333
release: splunk-otel-collector
3434
properties:
3535
cloudfoundry:
36+
director:
37+
hostname: (( $director.hostname ))
3638
rlp_gateway:
3739
endpoint: https://log-stream.(( ..cf.cloud_controller.system_domain.value ))
3840
shard_id: (( .properties.cloudfoundry_rlp_gateway_shard_id.value ))

0 commit comments

Comments
 (0)