debian-mirror-gitlab/app/views/projects/runners/_group_runners.html.haml

45 lines
1.7 KiB
Text
Raw Normal View History

2021-03-08 18:12:59 +05:30
- link = link_to _('Runner API'), help_page_path('api/runners.md')
2018-10-15 14:42:47 +05:30
2021-03-08 18:12:59 +05:30
%h4
= _('Group runners')
2018-10-15 14:42:47 +05:30
.bs-callout.bs-callout-warning
2021-03-08 18:12:59 +05:30
= _('These runners are shared across projects in this group.')
%br
%br
= _('Group runners can be managed with the %{link}.').html_safe % { link: link }
2018-10-15 14:42:47 +05:30
- if @project.group
2021-03-08 18:12:59 +05:30
%br
%br
2018-10-15 14:42:47 +05:30
- if @project.group_runners_enabled?
2021-06-08 01:23:25 +05:30
= link_to toggle_group_runners_project_runners_path(@project), class: 'btn gl-button btn-default', method: :post do
2021-03-08 18:12:59 +05:30
= _('Disable group runners')
2018-10-15 14:42:47 +05:30
- else
2021-04-29 21:17:54 +05:30
= link_to toggle_group_runners_project_runners_path(@project), class: 'btn gl-button btn-confirm-secondary', method: :post do
2021-03-08 18:12:59 +05:30
= _('Enable group runners')
2018-10-15 14:42:47 +05:30
 
= _('for this project')
- if !@project.group
2021-03-08 18:12:59 +05:30
= _('This project does not belong to a group and cannot make use of group runners.')
2018-10-15 14:42:47 +05:30
- elsif @group_runners.empty?
2021-03-08 18:12:59 +05:30
= _('This group does not have any group runners yet.')
2018-10-15 14:42:47 +05:30
2022-01-26 12:08:38 +05:30
- if can?(current_user, :admin_group_runners, @project.group)
2022-05-07 20:08:51 +05:30
- if Feature.enabled?(:runner_list_group_view_vue_ui, @group, default_enabled: :yaml)
- register_runners_path = group_runners_path(@project.group)
- else
- register_runners_path = group_settings_ci_cd_path(@project.group)
- group_link = link_to _("group's CI/CD settings."), register_runners_path
2022-03-02 08:16:31 +05:30
= _('Group owners can register group runners in the %{link}').html_safe % { link: group_link }
2018-10-15 14:42:47 +05:30
- else
2022-03-02 08:16:31 +05:30
= _('Ask your group owner to set up a group runner.')
2018-10-15 14:42:47 +05:30
- else
%h4.underlined-title
2021-03-08 18:12:59 +05:30
= _('Available group runners: %{runners}').html_safe % { runners: @group_runners.count }
2018-10-15 14:42:47 +05:30
%ul.bordered-list
= render partial: 'projects/runners/runner', collection: @group_runners, as: :runner