summaryrefslogtreecommitdiff
path: root/app/views
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-02-27 09:09:01 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2020-02-27 09:09:01 +0000
commitc72e5ebe9938d315ec598197873e71a80168d40a (patch)
tree439bf5c40aaf774e5a301825af517cb52726f450 /app/views
parentffc43b862df32a590eae874bcbb11109b46dc8be (diff)
downloadgitlab-ce-c72e5ebe9938d315ec598197873e71a80168d40a.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/views')
-rw-r--r--app/views/help/ui.html.haml8
-rw-r--r--app/views/projects/settings/operations/_configuration_banner.html.haml24
-rw-r--r--app/views/projects/settings/operations/_prometheus.html.haml19
-rw-r--r--app/views/projects/settings/operations/show.html.haml1
4 files changed, 48 insertions, 4 deletions
diff --git a/app/views/help/ui.html.haml b/app/views/help/ui.html.haml
index 7e0b444e5d7..038befac420 100644
--- a/app/views/help/ui.html.haml
+++ b/app/views/help/ui.html.haml
@@ -323,8 +323,8 @@
.dropdown-footer
%strong Tip:
If an author is not a member of this project, you can still filter by their name while using the search field.
- .dropdown-loading
- = icon('spinner spin')
+ .dropdown-loading.text-center
+ .spinner.spinner-md.mt-8
.example
%div
@@ -404,8 +404,8 @@
%input.dropdown-input-field{ type: "search", placeholder: "Filter results" }
= icon('search')
.dropdown-content
- .dropdown-loading
- = icon('spinner spin')
+ .dropdown-loading.text-center
+ .spinner.spinner-md.mt-8
.example
%div
diff --git a/app/views/projects/settings/operations/_configuration_banner.html.haml b/app/views/projects/settings/operations/_configuration_banner.html.haml
new file mode 100644
index 00000000000..bdbc9b7d69d
--- /dev/null
+++ b/app/views/projects/settings/operations/_configuration_banner.html.haml
@@ -0,0 +1,24 @@
+%b
+ = s_('PrometheusService|Auto configuration')
+
+- if service.manual_configuration?
+ .info-well.p-2.mt-2
+ = s_('PrometheusService|To enable the installation of Prometheus on your clusters, deactivate the manual configuration below')
+- else
+ .container-fluid
+ .row
+ - if service.prometheus_available?
+ .col-sm-2
+ .svg-container
+ = image_tag 'illustrations/monitoring/getting_started.svg'
+ .col-sm-10
+ %p.text-success.prepend-top-default
+ = s_('PrometheusService|Prometheus is being automatically managed on your clusters')
+ = link_to s_('PrometheusService|Manage clusters'), project_clusters_path(project), class: 'btn'
+ - else
+ .col-sm-2
+ = image_tag 'illustrations/monitoring/loading.svg'
+ .col-sm-10
+ %p.prepend-top-default
+ = s_('PrometheusService|Automatically deploy and configure Prometheus on your clusters to monitor your project’s environments')
+ = link_to s_('PrometheusService|Install Prometheus on clusters'), project_clusters_path(project), class: 'btn btn-success'
diff --git a/app/views/projects/settings/operations/_prometheus.html.haml b/app/views/projects/settings/operations/_prometheus.html.haml
new file mode 100644
index 00000000000..3d7a6b021a8
--- /dev/null
+++ b/app/views/projects/settings/operations/_prometheus.html.haml
@@ -0,0 +1,19 @@
+%section.settings.no-animate.js-prometheus-settings
+ .settings-header
+ %h4
+ = _('Prometheus')
+ %button.btn.js-settings-toggle{ type: 'button' }
+ = _('Expand')
+ %p
+ = _('Link Prometheus monitoring to GitLab.')
+ = link_to _('More information'), help_page_path('user/project/integrations/prometheus'), target: '_blank', rel: 'noopener noreferrer'
+ .settings-content
+ - if @project
+ = render 'projects/settings/operations/configuration_banner', project: @project, service: service
+
+ %b.append-bottom-default
+ = s_('PrometheusService|Manual configuration')
+
+ - unless service.editable?
+ .info-well
+ = s_('PrometheusService|To enable manual configuration, uninstall Prometheus from your clusters')
diff --git a/app/views/projects/settings/operations/show.html.haml b/app/views/projects/settings/operations/show.html.haml
index 30b914b5199..22477f315d6 100644
--- a/app/views/projects/settings/operations/show.html.haml
+++ b/app/views/projects/settings/operations/show.html.haml
@@ -4,6 +4,7 @@
= render 'projects/settings/operations/incidents'
= render 'projects/settings/operations/error_tracking'
+= render 'projects/settings/operations/prometheus', service: prometheus_service if Feature.enabled?(:settings_operations_prometheus_service)
= render 'projects/settings/operations/external_dashboard'
= render 'projects/settings/operations/grafana_integration'
= render_if_exists 'projects/settings/operations/tracing'