Integration that allows to:
- Visualize and monitor metrics collected with GitLab Runners through Prometheus
- Validate that the GitLab Runner can connect to GitLab
For more information about the GitLab Runner and its integration with Prometheus, see the GitLab Runner documentation.
Follow the instructions below to install and configure this check for an Agent running on a host. For containerized environments, see the Autodiscovery Integration Templates for guidance on applying these instructions.
The GitLab Runner check is included in the Datadog Agent package, so you don't need to install anything else on your GitLab servers.
Edit the gitlab_runner.d/conf.yaml
file, in the conf.d/
folder at the root of your Agent's configuration directory, to point to the Runner's Prometheus metrics endpoint and to the GitLab master to have a service check. See the sample gitlab_runner.d/conf.yaml for all available configuration options.
The allowed_metrics
item in the init_config
section allows you to specify the metrics that should be extracted. Some metrics should be reported as rate
, for example: ci_runner_errors
.
Run the Agent's status
subcommand and look for gitlab_runner
under the Checks section.
See metadata.csv for a list of metrics provided by this integration.
-
In your
gitlab_runner
configuration file, change the log format tojson
(Available for GitLab Runner versions >=11.4.0 ):log_format = "json"
-
Collecting logs is disabled by default in the Datadog Agent, you need to enable it in
datadog.yaml
:logs_enabled: true
-
Add the
dd-agent
user to thesystemd-journal
group by running:usermod -a -G systemd-journal dd-agent
-
Add this configuration block to your
gitlab_runner.d/conf.yaml
file to start collecting your GitLab Runner Logs:logs: - type: journald source: gitlab-runner
See the sample gitlab_runner.d/conf.yaml for all available configuration options.
The GitLab Runner check does not include any events.
The GitLab Runner check provides a service check to confirm that the Runner can talk to the GitLab master and another one to ensure that the local Prometheus endpoint is available.
Need help? Contact Datadog support.