---
title: Gitea
description: Track all your Gitea metrics with Datadog
breadcrumbs: Docs > Integrations > Gitea
---

# Gitea
Supported OS Integration version1.0.3
## Overview{% #overview %}

[Gitea](https://docs.gitea.io/en-us/) is a community managed lightweight code hosting solution written in Go.

This integration monitors Gitea instances through the Datadog [Agent](https://docs.datadoghq.com/agent.md).

## Setup{% #setup %}

### Prerequisite{% #prerequisite %}

Gitea doesn't expose its internal metrics by default. You need to enable the built-in HTTP server that exposes the metrics endpoint in your `app.ini` configuration file.

```ini
[metrics]
ENABLED = true
```

See the official [documentation](https://docs.gitea.io/en-us/) for more information.

### Installation{% #installation %}

The Gitea integration is not included in the [Datadog Agent](https://app.datadoghq.com/account/settings/agent/latest) package by default, it must be installed.

For Agent v7.36+, follow the instructions below to install the Gitea check on your host. See [Use Community Integrations](https://docs.datadoghq.com/agent/guide/use-community-integrations.md) to install with the Docker Agent or earlier versions of the Agent.

1. Run the following command to install the Agent integration:

```shell
datadog-agent integration install -t datadog-gitea==<INTEGRATION_VERSION>
```
Configure your integration similar to Agent-based [integrations](https://docs.datadoghq.com/getting_started/integrations.md).
### Configuration{% #configuration %}

1. Edit the `gitea.d/conf.yaml` file, in the `conf.d/` folder at the root of your Agent's configuration directory to start collecting your Gitea data. See the [sample gitea.d/conf.yaml](https://github.com/DataDog/integrations-extras/blob/master/gitea/datadog_checks/gitea/data/conf.yaml.example) for all available configuration options.

1. [Restart the Agent](https://docs.datadoghq.com/agent/guide/agent-commands.md#start-stop-and-restart-the-agent).

### Validation{% #validation %}

[Run the Agent's status subcommand](https://docs.datadoghq.com/agent/guide/agent-commands.md#agent-status-and-information) and look for `gitea` under the Checks section.

## Data Collected{% #data-collected %}

### Metrics{% #metrics %}

|  |
|  |
| **gitea.accesses**(gauge)                             | Number of Accesses.                                                     |
| **gitea.actions**(gauge)                              | Number of Actions.                                                      |
| **gitea.attachments**(gauge)                          | Number of Attachments.                                                  |
| **gitea.comments**(gauge)                             | Number of Comments.                                                     |
| **gitea.follows**(gauge)                              | Number of Follows.                                                      |
| **gitea.hooktasks**(gauge)                            | Number of HookTasks.                                                    |
| **gitea.issues**(gauge)                               | Number of Issues.                                                       |
| **gitea.issues.closed**(gauge)                        | Number of closed Issues.                                                |
| **gitea.issues.open**(gauge)                          | Number of open Issues.                                                  |
| **gitea.labels**(gauge)                               | Number of Labels.                                                       |
| **gitea.loginsources**(gauge)                         | Number of LoginSources.                                                 |
| **gitea.milestones**(gauge)                           | Number of Milestones.                                                   |
| **gitea.mirrors**(gauge)                              | Number of Mirrors.                                                      |
| **gitea.oauths**(gauge)                               | Number of Oauths.                                                       |
| **gitea.organizations**(gauge)                        | Number of Organizations.                                                |
| **gitea.projects**(gauge)                             | Number of Projects.                                                     |
| **gitea.projects\_boards**(gauge)                     | Number of project Boards.                                               |
| **gitea.publickeys**(gauge)                           | Number of PublicKeys.                                                   |
| **gitea.releases**(gauge)                             | Number of Releases.                                                     |
| **gitea.repositories**(gauge)                         | Number of Repositories.                                                 |
| **gitea.stars**(gauge)                                | Number of Stars.                                                        |
| **gitea.teams**(gauge)                                | Number of Teams.                                                        |
| **gitea.updatetasks**(gauge)                          | Number of UpdateTasks.                                                  |
| **gitea.users**(gauge)                                | Number of Users.                                                        |
| **gitea.watches**(gauge)                              | Number of Watches.                                                      |
| **gitea.webhooks**(gauge)                             | Number of Webhooks.                                                     |
| **gitea.go.info**(gauge)                              | Information about the Go environment.                                   |
| **gitea.go.goroutines**(gauge)                        | Number of goroutines that currently exist.                              |
| **gitea.go.threads**(gauge)                           | Number of OS threads created.                                           |
| **gitea.metric\_handler.requests\_in\_flight**(gauge) | Current number of scrapes being served.                                 |
| **gitea.metric\_handler.requests.count**(count)       | Total number of scrapes by HTTP status code.                            |
| **gitea.process.cpu\_seconds.count**(count)           | Total user and system CPU time spent in seconds.*Shown as second*       |
| **gitea.process.max\_fds**(gauge)                     | Maximum number of open file descriptors.                                |
| **gitea.process.open\_fds**(gauge)                    | Number of open file descriptors.                                        |
| **gitea.process.resident\_memory.bytes**(gauge)       | Resident memory size in bytes.*Shown as byte*                           |
| **gitea.process.start\_time**(gauge)                  | Start time of the process since unix epoch in seconds.*Shown as second* |
| **gitea.process.virtual\_memory.bytes**(gauge)        | Virtual memory size in bytes.*Shown as byte*                            |
| **gitea.process.virtual\_memory.max\_bytes**(gauge)   | Maximum amount of virtual memory available in bytes.*Shown as byte*     |

### Events{% #events %}

The Gitea check does not include any events.

### Service Checks{% #service-checks %}

**gitea.openmetrics.health**

Returns `CRITICAL` if the check cannot access the Prometheus metrics endpoint of the Gitea instance.

*Statuses: ok, critical*

## Troubleshooting{% #troubleshooting %}

Need help? Contact [Datadog support](https://docs.datadoghq.com/help/).
