Managing Application Metrics

Metrics supports basic monitoring capabilities for Pod, providing various monitoring indicators such as CPU, memory, disk, network, etc., to meet the basic monitoring requirements for Pod resources.

Create an authentication token

Create an authentication token using the drycc client.

# drycc tokens:add prometheus --password admin --username admin
 !    WARNING: Make sure to copy your token now.
 !    You won't be able to see it again, please confirm whether to continue.
 !    To proceed, type "yes" !

> yes
USERNAME    TOKEN                                                                                              
admin       1F2c7A802aF640fd9F31dD846AdDf56BcMsay

Add scrape configurations for prometheus

A valid example file can be found here.

The global configuration specifies parameters that are valid in all other configuration contexts. They also serve as defaults for other configuration sections.

  scrape_interval:   60s
  evaluation_interval: 60s
- job_name: 'drycc'
  scheme: https
  metrics_path: /v2/apps/<appname>/metrics
    type: Token
    credentials: 1F2c7A802aF640fd9F31dD846AdDf56BcMsay
  - targets: ['']