Help build the future of open source observability software Open positions

Check out the open source projects we support Downloads

Grot cannot remember your choice unless you click the consent notice at the bottom.

Grafana Agent v0.34 release: Extended Kubernetes monitoring, support for HashiCorp Vault, and more

Grafana Agent v0.34 release: Extended Kubernetes monitoring, support for HashiCorp Vault, and more

8 Jun, 2023 3 min

Grafana Agent v0.34 is now available!

The v0.34 release includes features for remote secrets, better Kubernetes integration, and above all, more community involvement. The Grafana Agent team is also excited to continue driving growth around Grafana Agent Flow, a configuration mode that makes Grafana Agent easier and more powerful to run.

Our big-tent and vendor-neutral approach allows Agent to solve your needs with the protocols and formats you already use, rather than demand your applications change to fit. 

New Grafana Agent Flow components

The v0.34 release continues to push feature parity between Grafana Agent Flow and Grafana Agent static mode via additional exporters. The release also includes an exciting new component, remote.vault, which allows Grafana Agent to avoid embedded secrets or other types of sensitive data. 

New components in v0.34 include:

Kubernetes monitoring: ServiceMonitors

Grafana Agent Flow continues to introduce functionality to monitor your Kubernetes clusters. The prometheus.operator.servicemonitors component builds upon prometheus.operator.podmonitors to continue the Flow Kubernetes path by allowing you to discover and scrape ServiceMonitors.

The below example will limit discovered ServiceMonitors to those with the label team=ops in a specific namespace: my-app.

prometheus.operator.servicemonitors "services" {
    forward_to = [prometheus.remote_write.staging.receiver]
    namespaces = ["my-app"]
    selector {
        match_expression {
            key = "team"
            operator = "In"
            values = ["ops"]
        }
    }
}

Hashicorp Vault support

Agent now includes Vault support with the new remote.vault component. This allows you to store your secrets in a secure central location and pass them, when needed, to any trusted Flow component.

The following example reads from Vault and uses Vault secrets for the username and password. 

local.file "vault_token" {
  filename  = "/var/data/vault_token"
  is_secret = true
}

remote.vault "remote_write" {
  server = "https://prod-vault.corporate.internal"
  path   = "secret/prometheus/remote_write"

  auth.token {
    token = local.file.vault_token.content
  }
}

metrics.remote_write "prod" {
  remote_write {
    url = "https://onprem-mimir:9009/api/v1/push"
    basic_auth {
      username = remote.vault.remote_write.data.username
      password = remote.vault.remote_write.data.password
    }
  }
}

Thank you to the community!

Grafana Agent v0.34 includes great contributions from outside Grafana Labs. Community members have contributed exporters, helped on issues, and been active in the Agent Slack channel. 

We want to especially thank Jan-Otto Kröpke. Jan is a constant voice in the Grafana Agent Slack channel, and a contributor to the code base. This includes the following contributions:

Learn more about Grafana Agent

For more information on the latest release, please refer to our Grafana Agent documentation or check out our Grafana Agent upgrade guide.

As always, we’d love to hear from you, so feel free to drop into our Grafana Labs Community Slack workspace or check out the Grafana Agent repo directly. We look forward to your comments and feedback!