Welcome to mirror list, hosted at ThFree Co, Russian Federation.

_prometheus.html.haml « application_settings « admin « views « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 982531e9a2f8bf08b01594bb0fae7dac0c552589 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
= gitlab_ui_form_for @application_setting, url: metrics_and_profiling_admin_application_settings_path(anchor: 'js-prometheus-settings'), html: { class: 'fieldset-form' } do |f|
  = form_errors(@application_setting)

  %fieldset
    .form-group
      - prometheus_help_link_url = help_page_path('administration/monitoring/prometheus/gitlab_metrics')
      - prometheus_help_link_start = '<a href="%{url}" target="_blank" rel="noopener noreferrer">'.html_safe % { url: prometheus_help_link_url }
      = f.gitlab_ui_checkbox_component :prometheus_metrics_enabled,
        _('Enable GitLab Prometheus metrics endpoint'),
        help_text: s_('AdminSettings|Enable collection of application metrics. Restart required. %{link_start}Learn how to export metrics to Prometheus%{link_end}.').html_safe % { link_start: prometheus_help_link_start, link_end: '</a>'.html_safe }
      .form-text.gl-text-gray-500.gl-pl-6
        - unless Gitlab::Metrics.metrics_folder_present?
          - icon_link = link_to sprite_icon('question-o'), help_page_path('administration/monitoring/prometheus/gitlab_metrics', anchor: 'metrics-shared-directory'), target: '_blank', rel: 'noopener noreferrer'
          = s_('AdminSettings|%{strongStart}WARNING:%{strongEnd} Environment variable %{environment_variable} does not exist or is not pointing to a valid directory. %{icon_link}').html_safe % { strongStart: '<strong class="gl-text-red-500">'.html_safe, strongEnd: '</strong>'.html_safe, environment_variable: '<code>prometheus_multiproc_dir</code>'.html_safe, icon_link: icon_link }
    .form-group
      = f.label :metrics_method_call_threshold, _('Method call threshold (ms)'), class: 'label-bold'
      = f.number_field :metrics_method_call_threshold, class: 'form-control gl-form-input'
      .form-text.text-muted
        Only track method calls that take longer to complete than the given duration.

  = f.submit _('Save changes'), class: "gl-button btn btn-confirm"