CustomAlertmanager

Scope: Cluster
Version: v1alpha1

The resource for connecting additional Alertmanagers to Prometheus.

  • specobject

    Required value

    • externalobject
      • addressstring

        URL of an external Alertmanager.

        Pattern: ^https?://[^\s/$.?#].[^\s]*$

        Examples:

        address: http://alerts.mycompany.com
        
        address: https://alerts.company.com
        
        address: http://192.168.1.1
        
      • authobject

        Authorization properties.

        • basicobject

          Basic authorization properties.

          • passwordstring
          • usernamestring
      • serviceobject

        Kubernetes cluster service which leads to deployed Alertmanager.

        • namestring

          Required value

          Name of an Alertmanager service.

        • namespacestring

          Required value

          Namespace of an Alertmanager service.

        • pathstring

          URL prefix in a service to send alerts for.

          Default: "/"

      • tlsobject
        • castring
        • certstring
        • insecureSkipVerifyboolean

          Default: false

        • keystring
    • typestring

      Allowed values: External

CustomPrometheusRules

Scope: Cluster

Resource to store PrometheusRule. Details….

  • specobject

    Required value

    • groupsarray of objects

      Required value

      Alert group description.

      The structure of the groups is similar to that of prometheus-operator.

      • intervalstring
      • namestring

        Required value

      • rulesarray of objects

        Required value

        • alertstring
        • annotationsobject
        • exprinteger or string

          Required value

        • forstring
        • labelsobject
        • recordstring

Resource to store PrometheusRule. Details….

  • specobject

    Required value

    • groupsarray of objects

      Required value

      Alert group description.

      The structure of the groups is similar to that of prometheus-operator.

      • intervalstring
      • namestring

        Required value

      • rulesarray of objects

        Required value

        • alertstring
        • annotationsobject
        • exprinteger or string

          Required value

        • forstring
        • labelsobject
        • recordstring

GrafanaAdditionalDatasource

Scope: Cluster

The resource for connecting additional datasources to Grafana.

The resource parameters are described in details in the Grafana documentation.

  • specobject

    Required value

    • accessstring

      Required value

      Access mode.

      Allowed values: Proxy, Direct

    • basicAuthboolean

      Enable/disable basic auth.

    • basicAuthUserstring

      Basic auth username.

    • databasestring

      Database name (if used).

    • jsonDataobject

      Fields to be converted to JSON and stored in jsonData.

    • secureJsonDataobject

      JSON-data object to be saved encrypted.

    • typestring

      Required value

      Datasource type.

    • urlstring

      Datasource URL.

      Example:

      url: http://localhost:8080
      
    • userstring

      Database username.

    • withCredentialsboolean

      Enable/disable with credentials headers

The resource for connecting additional datasources to Grafana.

The resource parameters are described in details in the Grafana documentation.

  • specobject

    Required value

    • accessstring

      Required value

      Access mode.

      Allowed values: proxy, direct

    • basicAuthboolean

      Enable/disable basic auth.

    • basicAuthUserstring

      Basic auth username.

    • databasestring

      Database name (if used).

    • jsonDataobject

      Fields to be converted to JSON and stored in jsonData.

    • secureJsonDataobject

      JSON-data object to be saved encrypted.

    • typestring

      Required value

      Datasource type.

    • urlstring

      Datasource URL.

      Example:

      url: http://localhost:8080
      
    • userstring

      Database username.

    • withCredentialsboolean

      Enable/disable with credentials headers

GrafanaAlertsChannel

Scope: Cluster
Version: v1alpha1

The resource for adding alert notification channels to Grafana.

  • specobject

    Required value

    • alertManagerobject

      Required value

      Alert manager settings.

      • addressstring

        Required value

        URL of an external Alertmanager.

        Pattern: ^https?://[^\s/$.?#].[^\s]*$

        Examples:

        address: http://alerts.mycompany.com
        
        address: https://alerts.company.com
        
        address: http://192.168.1.1
        
      • authobject

        Authorization properties.

        • basicobject

          Required value

          Basic authorization properties.

          • passwordstring

            Required value

            Password.

          • usernamestring

            Required value

            User name.

    • descriptionstring

      Small and optional description about this alerts channel.

      Default: ""

    • disableResolveMessageboolean

      When true, this option disables the resolve message [OK] that is sent when the alerting state returns to false.

      Default: false

    • isDefaultboolean

      Use this notification channel for all alerts.

      Default: false

    • typestring

      Required value

      Allowed values: PrometheusAlertManager

GrafanaDashboardDefinition

Scope: Cluster

The resource for storing and managing Grafana Dashboards

  • specobject

    Required value

    • definitionstring

      Required value

      The dashboard’s JSON manifest.

      Caution! Make sure that there is no “local” id (at the .id address) in the manifest in addition to the uid.

    • folderstring

      Required value

      What folder to use for a dashboard. If the folder does not exist, it will be created.

      Example:

      folder: My Folder
      

The resource for storing and managing Grafana Dashboards

  • specobject

    Required value

    • definitionstring

      Required value

      The dashboard’s JSON manifest.

      Caution! Make sure that there is no “local” id (at the .id address) in the manifest in addition to the uid.

    • folderstring

      Required value

      What folder to use for a dashboard. If the folder does not exist, it will be created.

      Example:

      folder: My Folder
      

PrometheusRemoteWrite

Scope: Cluster

Resource for including ‘remote_write’ data from the local Prometheus into a separate longterm storage (E.g: VictoriaMetrics).

A cluster can have any number of such resources.

  • specobject

    Required value

    • basicAuthobject

      BasicAuth for the URL.

      • passwordstring

        Required value

        Password for the authentication.

      • usernamestring

        Required value

        Username for the authentication.

    • tlsConfigobject

      TLS Config to use for remote write.

      • insecureSkipVerifyboolean

        Disable target certificate validation.

        Default: false

    • urlstring

      Required value

      The URL of the endpoint to send samples to.

      Example:

      url: https://victoriametrics-test.domain.com/api/v1/write
      
    • writeRelabelConfigsarray of objects

      The list of remote write relabel configurations.

      For example, if you need to remove unnecessary metrics or perform data relabeling.

      • actionstring

        Action to perform based on regex matching.

        Default: "replace"

      • modulusinteger

        Modulus to take of the hash of the source label values.

      • regexstring

        Regular expression against which the extracted value is matched. Default is ‘(.*)’

        Default: "(.*)"

      • replacementstring

        Replacement value against which a regex replace is performed if the regular expression matches.

        Regex capture groups are available.

        Default: "$1"

      • separatorstring

        Separator placed between concatenated source label values.

        Default: ";"

      • sourceLabelsarray of strings

        The source labels select values from existing labels.

        Their content is concatenated using the configured separator and matched against the configured regular expression for the replace, keep, and drop actions.

      • targetLabelstring

        Label to which the resulting value is written in a replace action. It is mandatory for replace actions.

        Regex capture groups are available.

Resource for including ‘remote_write’ data from the local Prometheus into a separate longterm storage (E.g: VictoriaMetrics).

A cluster can have any number of such resources.

  • specobject

    Required value

    • basicAuthobject

      BasicAuth for the URL.

      • passwordstring

        Required value

        Password for the authentication.

      • usernamestring

        Required value

        Username for the authentication.

    • tlsConfigobject

      TLS Config to use for remote write.

      • insecureSkipVerifyboolean

        Disable target certificate validation.

        Default: false

    • urlstring

      Required value

      The URL of the endpoint to send samples to.

      Example:

      url: https://victoriametrics-test.domain.com/api/v1/write
      
    • writeRelabelConfigsarray of objects

      The list of remote write relabel configurations.

      For example, if you need to remove unnecessary metrics or perform data relabeling.

      • actionstring

        Action to perform based on regex matching.

        Default: "replace"

      • modulusinteger

        Modulus to take of the hash of the source label values.

      • regexstring

        Regular expression against which the extracted value is matched. Default is ‘(.*)’

        Default: "(.*)"

      • replacementstring

        Replacement value against which a regex replace is performed if the regular expression matches.

        Regex capture groups are available.

        Default: "$1"

      • separatorstring

        Separator placed between concatenated source label values.

        Default: ";"

      • sourceLabelsarray of strings

        The source labels select values from existing labels.

        Their content is concatenated using the configured separator and matched against the configured regular expression for the replace, keep, and drop actions.

      • targetLabelstring

        Label to which the resulting value is written in a replace action. It is mandatory for replace actions.

        Regex capture groups are available.