summaryrefslogtreecommitdiff
path: root/app/views/admin
diff options
context:
space:
mode:
authorJames Fargher <proglottis@gmail.com>2019-06-18 00:01:56 +0000
committerThong Kuah <tkuah@gitlab.com>2019-06-18 00:01:56 +0000
commit6b9157d5dc9b45cc6d70f10d075bbf149af5f266 (patch)
tree29161152edd2c8cfbf1e4097beced805cdd47a72 /app/views/admin
parent04307096bcc776259d8080bebd688ff6073d07c4 (diff)
downloadgitlab-ce-6b9157d5dc9b45cc6d70f10d075bbf149af5f266.tar.gz
Make KubernetesService readonly
We are deprecating this service in favor of instance wide clusters. Therefore we removed some code that is not anymore needed for a readonly cluster and also we added some flags to allow for this deprecation. These flags are to be removed in the next release when we finally completelly remove KubernetesService.
Diffstat (limited to 'app/views/admin')
-rw-r--r--app/views/admin/services/_deprecated_message.html.haml3
-rw-r--r--app/views/admin/services/_form.html.haml5
-rw-r--r--app/views/admin/services/edit.html.haml3
3 files changed, 9 insertions, 2 deletions
diff --git a/app/views/admin/services/_deprecated_message.html.haml b/app/views/admin/services/_deprecated_message.html.haml
new file mode 100644
index 00000000000..fea9506a4bb
--- /dev/null
+++ b/app/views/admin/services/_deprecated_message.html.haml
@@ -0,0 +1,3 @@
+.flash-container.flash-container-page
+ .flash-alert.deprecated-service
+ %span= @service.deprecation_message
diff --git a/app/views/admin/services/_form.html.haml b/app/views/admin/services/_form.html.haml
index 1798b44bbb7..97373a3c350 100644
--- a/app/views/admin/services/_form.html.haml
+++ b/app/views/admin/services/_form.html.haml
@@ -6,5 +6,6 @@
= form_for :service, url: admin_application_settings_service_path, method: :put, html: { class: 'fieldset-form' } do |form|
= render 'shared/service_settings', form: form, subject: @service
- .footer-block.row-content-block
- = form.submit 'Save', class: 'btn btn-success'
+ - unless @service.is_a?(KubernetesService)
+ .footer-block.row-content-block
+ = form.submit 'Save', class: 'btn btn-success'
diff --git a/app/views/admin/services/edit.html.haml b/app/views/admin/services/edit.html.haml
index 512176649e6..79f5ab0d77d 100644
--- a/app/views/admin/services/edit.html.haml
+++ b/app/views/admin/services/edit.html.haml
@@ -1,4 +1,7 @@
- add_to_breadcrumbs "Service Templates", admin_application_settings_services_path
- breadcrumb_title @service.title
- page_title @service.title, "Service Templates"
+
+= render 'deprecated_message' if @service.deprecation_message
+
= render 'form'