Aller au contenu

How to deploy a new federation with Trackbone#

You can add a configuration in prometheus-federation.cue.

It uses the chart caascad-servicemonitor which includes the possibility of deploying :

  • a secret usable in servicemonitor
  • a service
  • a servicemonitor

In the case of the federation, the secret is a token rancher.

Add an endpoint#

Add a _prometheusFederationEndpoint<Name> which uses the definition _prometheusFederationEndpoint.

These are the parameters of the servicemonitor :

  • relabelings
  • secret
  • port
  • match param ...

Add a serviceMonitor#

Add a serviceMonitor in servicemonitorMap.

You have to specify :

  • endpoints with _prometheusFederationEndpoint<Name>
  • jobLabel -> allows you to change the value of the job label
  • selector: matchLabels: jobName

Add configuration in FlavorMap (optional)#

This step is to be done only if:

  • the federations are not the same for all the zones
  • federations should not be deployed in all zones

The parameter to be defined can be : match param (the same as the endpoint).

Example : cfg.matchMonitoringVM

Deploy configuration#

Usual workflow.