You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Sep 2, 2025. It is now read-only.
Copy file name to clipboardExpand all lines: gdi/opentelemetry/deployments/deployments-ecs-ec2.rst
+44-31Lines changed: 44 additions & 31 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -44,8 +44,6 @@ Notes:
44
44
45
45
* You can set the memory limit for the ``memory_limiter`` processor using environment variable ``SPLUNK_MEMORY_LIMIT_MIB``. The default memory limit is 512 MiB.
46
46
47
-
* To run Docker containers in Amazon ECS you need a task definition and to launch the Collector.
48
-
49
47
.. _ecs-ec2-custom-config:
50
48
51
49
Deploy the Collector using a custom configuration
@@ -57,19 +55,56 @@ Alternatively, you can specify the custom configuration YAML directly using the
57
55
58
56
.. _ecs-observer-config:
59
57
60
-
Configure ``ecs_observer``
61
-
--------------------------------
58
+
Configure the Amazon Elastic Container Service Observer extension
Use the Amazon Elastic Container Service Observer (``ecs_observer``) extension in your custom configuration to discover metric targets in running tasks, filtered by service names, task definitions, and container labels.
Use extension Amazon Elastic Container Service Observer (``ecs_observer``) in your custom configuration to discover metric targets in running tasks, filtered by service names, task definitions, and container labels. ``ecs_observer`` is currently limited to Prometheus targets and requires the read-only permissions below. The Collector should be configured to run as an ECS Daemon. You can add the permissions to the task role by adding them to a customer-managed policy that is attached to the task role.
66
+
The following applies:
67
+
68
+
* The Collector must run as an ECS Daemon. See :ref:`ecs-observer-launch`.
69
+
* The ECS Observer is currently limited to Prometheus targets.
70
+
* The ECS Observer requires the read-only permissions below. Add them to the customer-managed policy that is attached to the task role.
64
71
65
72
.. code-block:: yaml
66
73
67
-
ecs:List*
68
-
ecs:Describe*
74
+
ecs:List*
75
+
ecs:Describe*
76
+
77
+
.. _ecs-observer-launch:
78
+
79
+
Launch the Collector as a Daemon from the ECS console
To launch the Collector from the Amazon ECS console:
83
+
84
+
1. Go to your cluster in the console and select :guilabel:`Services`.
85
+
86
+
2. Select :guilabel:`Create` and define the following options:
87
+
88
+
* Launch Type: EC2
89
+
90
+
* Task Definition (Family): splunk-otel-collector
91
+
92
+
* Task Definition (Revision): 1 (or whatever the latest is in your case)
93
+
94
+
* Service Name: splunk-otel-collector
95
+
96
+
* Service type: DAEMON
97
+
98
+
3. Leave everything else as default and proceed to :guilabel:`Next step` until you're required to create the service.
99
+
100
+
4. Select :guilabel:`Create Service` to deploy the Collector onto each node in the ECS cluster. You should see infrastructure and docker metrics flowing soon.
The following custom configuration examples show the ``ecs_observer`` configured to find Prometheus targets in the ``lorem-ipsum-cluster`` cluster and ``us-west-2`` region, where the task ARN pattern is ``^arn:aws:ecs:us-west-2:906383545488:task-definition/lorem-ipsum-task:[0-9]+$``.
105
+
The following example configures the ``ecs_observer`` to find Prometheus targets in the ``lorem-ipsum-cluster`` cluster and ``us-west-2`` region, where the task ARN pattern is ``^arn:aws:ecs:us-west-2:906383545488:task-definition/lorem-ipsum-task:[0-9]+$``. The results are written to ``/etc/ecs_sd_targets.yaml``.
71
106
72
-
The results are written to ``/etc/ecs_sd_targets.yaml``. The ``prometheus`` receiver is configured to read targets from the results file. The values for ``access_token`` and ``realm`` are read from the ``SPLUNK_ACCESS_TOKEN`` and ``SPLUNK_REALM`` environment variables, which must be specified in your container definition.
107
+
The ``prometheus`` receiver is configured to read targets from the results file. The values for ``access_token`` and ``realm`` are read from the ``SPLUNK_ACCESS_TOKEN`` and ``SPLUNK_REALM`` environment variables, which you must specify in your container definition.
73
108
74
109
.. code-block:: yaml
75
110
@@ -132,25 +167,3 @@ Follow these steps:
132
167
133
168
.. caution:: The AWS Parameter Store limits the size of the config file to 4096 bytes.
134
169
135
-
Launch the Collector as a Daemon from the ECS console
To launch the Collector from the Amazon ECS console:
139
-
140
-
1. Go to your cluster in the console and select :guilabel:`Services`.
141
-
142
-
2. Select :guilabel:`Create` and define the following options:
143
-
144
-
* Launch Type: EC2
145
-
146
-
* Task Definition (Family): splunk-otel-collector
147
-
148
-
* Task Definition (Revision): 1 (or whatever the latest is in your case)
149
-
150
-
* Service Name: splunk-otel-collector
151
-
152
-
* Service type: DAEMON
153
-
154
-
3. Leave everything else as default and proceed to :guilabel:`Next step` until you're required to create the service.
155
-
156
-
4. Select :guilabel:`Create Service` to deploy the Collector onto each node in the ECS cluster. You should see infrastructure and docker metrics flowing soon.
0 commit comments