diff options
author | Clement Ho <ClemMakesApps@gmail.com> | 2018-05-08 10:49:30 -0500 |
---|---|---|
committer | Clement Ho <ClemMakesApps@gmail.com> | 2018-05-08 10:49:30 -0500 |
commit | 5955caed321e242bfebe52a4b47346a01a50e4f6 (patch) | |
tree | d9710c0732ce21801b4a79a281bec0bd39582a95 /app/views/shared/runners | |
parent | f9e2b4730f58ba630344c9554eb907ab003abbd5 (diff) | |
parent | 533593e95cd3a922a2ec2ea43b345862361dfd67 (diff) | |
download | gitlab-ce-5955caed321e242bfebe52a4b47346a01a50e4f6.tar.gz |
Merge branch 'master' into bootstrap4
Diffstat (limited to 'app/views/shared/runners')
-rw-r--r-- | app/views/shared/runners/_form.html.haml | 56 | ||||
-rw-r--r-- | app/views/shared/runners/_runner_description.html.haml | 16 | ||||
-rw-r--r-- | app/views/shared/runners/show.html.haml | 71 |
3 files changed, 143 insertions, 0 deletions
diff --git a/app/views/shared/runners/_form.html.haml b/app/views/shared/runners/_form.html.haml new file mode 100644 index 00000000000..e958f760cf3 --- /dev/null +++ b/app/views/shared/runners/_form.html.haml @@ -0,0 +1,56 @@ += form_for runner, url: runner_form_url do |f| + = form_errors(runner) + .form-group.row + = label :active, "Active", class: 'col-form-label col-sm-2' + .col-sm-10 + .form-check + = f.check_box :active + %span.light Paused Runners don't accept new jobs + .form-group.row + = label :protected, "Protected", class: 'col-form-label col-sm-2' + .col-sm-10 + .form-check + = f.check_box :access_level, {}, 'ref_protected', 'not_protected' + %span.light This runner will only run on pipelines triggered on protected branches + .form-group.row + = label :run_untagged, 'Run untagged jobs', class: 'col-form-label col-sm-2' + .col-sm-10 + .form-check + = f.check_box :run_untagged + %span.light Indicates whether this runner can pick jobs without tags + - unless runner.group_type? + .form-group.row + = label :locked, 'Lock to current projects', class: 'col-form-label col-sm-2' + .col-sm-10 + .form-check + = f.check_box :locked + %span.light When a runner is locked, it cannot be assigned to other projects + .form-group.row + = label_tag :token, class: 'col-form-label col-sm-2' do + Token + .col-sm-10 + = f.text_field :token, class: 'form-control', readonly: true + .form-group.row + = label_tag :ip_address, class: 'col-form-label col-sm-2' do + IP Address + .col-sm-10 + = f.text_field :ip_address, class: 'form-control', readonly: true + .form-group.row + = label_tag :description, class: 'col-form-label col-sm-2' do + Description + .col-sm-10 + = f.text_field :description, class: 'form-control' + .form-group.row + = label_tag :maximum_timeout_human_readable, class: 'col-form-label col-sm-2' do + Maximum job timeout + .col-sm-10 + = f.text_field :maximum_timeout_human_readable, class: 'form-control' + .form-text.text-muted This timeout will take precedence when lower than Project-defined timeout + .form-group.row + = label_tag :tag_list, class: 'col-form-label col-sm-2' do + Tags + .col-sm-10 + = f.text_field :tag_list, value: runner.tag_list.sort.join(', '), class: 'form-control' + .form-text.text-muted You can setup jobs to only use Runners with specific tags. Separate tags with commas. + .form-actions + = f.submit 'Save changes', class: 'btn btn-save' diff --git a/app/views/shared/runners/_runner_description.html.haml b/app/views/shared/runners/_runner_description.html.haml new file mode 100644 index 00000000000..da5c032add5 --- /dev/null +++ b/app/views/shared/runners/_runner_description.html.haml @@ -0,0 +1,16 @@ +.light.prepend-top-default + %p + = _("A 'Runner' is a process which runs a job. You can setup as many Runners as you need.") + %br + = _('Runners can be placed on separate users, servers, and even on your local machine.') + + %p + = _('Each Runner can be in one of the following states:') + %div + %ul + %li + %span.badge.badge-success active + = _('- Runner is active and can process any new jobs') + %li + %span.badge.badge-danger paused + = _('- Runner is paused and will not receive any new jobs') diff --git a/app/views/shared/runners/show.html.haml b/app/views/shared/runners/show.html.haml new file mode 100644 index 00000000000..3f6c5c9adc6 --- /dev/null +++ b/app/views/shared/runners/show.html.haml @@ -0,0 +1,71 @@ +- page_title "#{@runner.description} ##{@runner.id}", "Runners" + +%h3.page-title + Runner ##{@runner.id} + .float-right + - if @runner.shared? + %span.runner-state.runner-state-shared + Shared + - elsif @runner.group_type? + %span.runner-state.runner-state-shared + Group + - else + %span.runner-state.runner-state-specific + Specific + +.table-holder + %table.table + %thead + %tr + %th Property Name + %th Value + %tr + %td Active + %td= @runner.active? ? 'Yes' : 'No' + %tr + %td Protected + %td= @runner.ref_protected? ? 'Yes' : 'No' + %tr + %td Can run untagged jobs + %td= @runner.run_untagged? ? 'Yes' : 'No' + - unless @runner.group_type? + %tr + %td Locked to this project + %td= @runner.locked? ? 'Yes' : 'No' + %tr + %td Tags + %td + - @runner.tag_list.sort.each do |tag| + %span.badge.badge-primary + = tag + %tr + %td Name + %td= @runner.name + %tr + %td Version + %td= @runner.version + %tr + %td IP Address + %td= @runner.ip_address + %tr + %td Revision + %td= @runner.revision + %tr + %td Platform + %td= @runner.platform + %tr + %td Architecture + %td= @runner.architecture + %tr + %td Description + %td= @runner.description + %tr + %td Maximum job timeout + %td= @runner.maximum_timeout_human_readable + %tr + %td Last contact + %td + - if @runner.contacted_at + #{time_ago_in_words(@runner.contacted_at)} ago + - else + Never |