forked from signalfx/signalfx-agent
-
Notifications
You must be signed in to change notification settings - Fork 0
/
agent.yaml
78 lines (67 loc) · 2.83 KB
/
agent.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
# This agent config file is designed for use within an ECS cluster. The agent
# should be run as a Daemon service with the host EC2 instance's filesystem
# mounted in at /hostfs and the docker socket mounted in at
# /var/run/docker.sock.
signalFxAccessToken: {"#from": "env:ACCESS_TOKEN"}
ingestUrl: {"#from": "env:INGEST_URL", optional: true}
apiUrl: {"#from": "env:API_URL", optional: true}
traceEndpointUrl: {"#from": "env:TRACE_ENDPOINT_URL", optional: true}
intervalSeconds: {"#from": "env:INTERVAL_SECONDS", default: 10}
logging:
level: {"#from": "env:LOG_LEVEL", default: "info"}
etcPath: /hostfs/etc
procPath: /hostfs/proc
runPath: /hostfs/run
varPath: /hostfs/var
sysPath: /hostfs/sys
# observers are what discover running services in the environment
observers:
# Enable the docker observer to discover other ECS tasks running on the
# same EC2 instance.
- type: docker
# ECS tasks running the awsvpc network mode don't actually expose and IP
# address on the docker inspect API so we need to use the hostname instead.
useHostnameIfPresent: true
labelsToDimensions: &labelMap
# We map the cluster label to ClusterName to match what our AWS
# CloudWatch integration uses.
com.amazonaws.ecs.cluster: ClusterName
com.amazonaws.ecs.container-name: container_spec_name
com.amazonaws.ecs.task-arn: ecs_task_arn
com.amazonaws.ecs.task-definition-family: ecs_task_group
com.amazonaws.ecs.task-definition-version: ecs_task_version
monitors:
- type: cpu
- type: filesystems
hostFSPath: /hostfs
- type: disk-io
- type: net-io
- type: load
- type: memory
- type: host-metadata
- type: processlist
- type: vmem
- type: docker-container-stats
labelsToDimensions:
<<: *labelMap
# You can set this envvar in your task definition to provide extra monitor
# configuration to monitor applications running as ECS tasks. You should
# probably use discovery rules so that you don't have to have a specific
# config for each EC2 instance.
- {"#from": "env:EXTRA_MONITOR_CONFIG", default: [], flatten: true}
# Enables the Smart Agent to receive traces.
- type: signalfx-forwarder
# Specify the hostname:port where the Smart Agent receives traces.
listenAddress: "0.0.0.0:9080"
# Optionally, add span tags to each span in a trace the Smart Agent receives.
# defaultSpanTags:
# SPAN_TAG_KEY: "SPAN_TAG_VALUE"
# Exports traces in the specified format to a SignalFx ingest endpoint or
# OpenTelemetry Collector according to the traceEndpointUrl you set.
writer:
traceExportFormat: sapm
metricsToExclude:
- {"#from": "env:METRICS_TO_EXCLUDE", default: [], flatten: true}
# This allows any config above to be completely overridden. CONFIG_OVERRIDE
# must be given as a YAML/JSON object.
_: {"#from": "env:CONFIG_OVERRIDE", optional: true, flatten: true}