Prometheus - add target specific label in static_configs

后端 未结 5 540
迷失自我
迷失自我 2021-02-04 00:35

I have job definition as follows:

  - job_name: \'test-name\'
    static_configs:
      - targets: [ \'192.168.1.1:9100\', \'192.168.1.1:9101\', \'192.168.1.1:91         


        
5条回答
  •  粉色の甜心
    2021-02-04 00:56

    Can be link this

      - job_name: 'node'
        static_configs:
        - targets: ['192.168.1.117:9100']
          labels:
            instance: 'linux-ina'
        - targets: ['192.168.1.138:9100']
          labels:
            instance: 'linux-inb'
    

    Tag name can be replaced with instance

提交回复
热议问题