foreman_remote_execution 3.2.2 → 3.3.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.eslintrc +5 -30
- data/.github/workflows/ci.yml +101 -0
- data/.gitignore +1 -0
- data/.rubocop_todo.yml +3 -0
- data/Gemfile +1 -0
- data/app/assets/stylesheets/foreman_remote_execution/job_invocations.scss +6 -5
- data/app/controllers/api/v2/job_invocations_controller.rb +17 -0
- data/app/helpers/remote_execution_helper.rb +38 -33
- data/app/lib/actions/remote_execution/run_host_job.rb +3 -2
- data/app/models/remote_execution_provider.rb +5 -0
- data/app/services/default_proxy_proxy_selector.rb +20 -0
- data/app/views/api/v2/job_invocations/main.json.rabl +6 -0
- data/app/views/job_invocations/_card_target_hosts.html.erb +1 -1
- data/app/views/job_invocations/_tab_hosts.html.erb +3 -23
- data/app/views/job_invocations/index.html.erb +2 -1
- data/app/views/job_invocations/show.html.erb +0 -6
- data/app/views/job_invocations/show.json.erb +4 -0
- data/app/views/templates/ssh/package_action.erb +1 -0
- data/app/views/templates/ssh/puppet_agent_disable.erb +3 -0
- data/app/views/templates/ssh/puppet_agent_enable.erb +3 -0
- data/app/views/templates/ssh/puppet_install_modules_from_forge.erb +3 -0
- data/app/views/templates/ssh/puppet_run_once.erb +3 -0
- data/db/seeds.d/70-job_templates.rb +1 -1
- data/foreman_remote_execution.gemspec +4 -5
- data/lib/foreman_remote_execution/version.rb +1 -1
- data/locale/action_names.rb +0 -1
- data/package.json +16 -33
- data/webpack/__mocks__/foremanReact/common/I18n.js +1 -0
- data/webpack/__mocks__/foremanReact/components/common/ActionButtons/ActionButtons.js +3 -0
- data/webpack/__mocks__/foremanReact/constants.js +3 -0
- data/webpack/index.js +9 -7
- data/webpack/react_app/components/TargetingHosts/TargetingHosts.js +52 -0
- data/webpack/react_app/components/TargetingHosts/TargetingHostsActions.js +8 -0
- data/webpack/react_app/components/TargetingHosts/TargetingHostsConsts.js +1 -0
- data/webpack/react_app/components/TargetingHosts/TargetingHostsSelectors.js +12 -0
- data/webpack/react_app/components/TargetingHosts/__tests__/HostItem.test.js +6 -0
- data/webpack/react_app/components/TargetingHosts/__tests__/HostStatus.test.js +6 -0
- data/webpack/react_app/components/TargetingHosts/__tests__/TargetingHosts.test.js +6 -0
- data/webpack/react_app/components/TargetingHosts/__tests__/__snapshots__/HostItem.test.js.snap +31 -0
- data/webpack/react_app/components/TargetingHosts/__tests__/__snapshots__/HostStatus.test.js.snap +12 -0
- data/webpack/react_app/components/TargetingHosts/__tests__/__snapshots__/TargetingHosts.test.js.snap +81 -0
- data/webpack/react_app/components/TargetingHosts/__tests__/fixtures.js +43 -0
- data/webpack/react_app/components/TargetingHosts/components/HostItem.js +39 -0
- data/webpack/react_app/components/TargetingHosts/components/HostStatus.js +54 -0
- data/webpack/react_app/components/TargetingHosts/index.js +37 -0
- data/webpack/react_app/components/jobInvocations/AggregateStatus/index.js +10 -0
- data/webpack/react_app/components/jobInvocations/AggregateStatus/index.test.js +6 -3
- data/webpack/react_app/components/jobInvocations/index.js +19 -7
- data/webpack/react_app/redux/actions/jobInvocations/index.js +12 -8
- data/webpack/react_app/redux/consts.js +1 -2
- data/webpack/react_app/redux/reducers/jobInvocations/index.fixtures.js +8 -40
- data/webpack/react_app/redux/reducers/jobInvocations/index.test.js +17 -11
- data/webpack/test_setup.js +2 -1
- metadata +26 -12
- data/.hound.yml +0 -19
- data/.travis.yml +0 -6
- data/app/views/job_invocations/_host_actions_td.html.erb +0 -3
- data/app/views/job_invocations/_host_name_td.html.erb +0 -8
- data/app/views/job_invocations/_host_status_td.html.erb +0 -1
- data/app/views/job_invocations/show.js.erb +0 -23
data/.hound.yml
DELETED
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
scss:
|
|
2
|
-
enabled: false
|
|
3
|
-
|
|
4
|
-
stylelint:
|
|
5
|
-
enabled: true
|
|
6
|
-
|
|
7
|
-
rubocop:
|
|
8
|
-
config_file: .rubocop.yml
|
|
9
|
-
version: 0.80.0
|
|
10
|
-
|
|
11
|
-
jshint:
|
|
12
|
-
enabled: false
|
|
13
|
-
|
|
14
|
-
eslint:
|
|
15
|
-
enabled: true
|
|
16
|
-
config_file: .eslintrc
|
|
17
|
-
ignore_file: .eslintignore
|
|
18
|
-
|
|
19
|
-
fail_on_violations: true
|
data/.travis.yml
DELETED
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
<td class="host_name" id="<%= dom_id(host) %>-name" data-refresh_required="<%= task.nil? ? 'true' : '' %>" data-id="<%= host.id %>">
|
|
2
|
-
<% if task %>
|
|
3
|
-
<%= link_to_if_authorized host.name, hash_for_template_invocation_path(:id => template_invocation).merge(:auth_object => host, :permission => :view_hosts, :authorizer => job_hosts_authorizer) %>
|
|
4
|
-
|
|
5
|
-
<% else %>
|
|
6
|
-
<%= host.name %>
|
|
7
|
-
<% end %>
|
|
8
|
-
</td>
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
<td class="host_status" id="<%= dom_id(host) %>-status" data-refresh_required="<%= task.nil? || task.pending? ? 'true' : '' %>" data-id="<%= host.id %>"><%= template_invocation_status(task, job_invocation.task) %></td>
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
$('div#title_action div.btn-group').html('<%= button_group(job_invocation_task_buttons(@job_invocation.task)).html_safe %>');
|
|
2
|
-
<% if params[:hosts_needs_refresh] == 'true' && @job_invocation.resolved? %>
|
|
3
|
-
var hosts_table = $('div#hosts');
|
|
4
|
-
hosts_table.html('<%=j render('tab_hosts', :job_invocation => @job_invocation, :hosts => @hosts) %>');
|
|
5
|
-
hosts_table.data('refresh_required', '');
|
|
6
|
-
<% end %>
|
|
7
|
-
|
|
8
|
-
<% ['name', 'status', 'actions', 'provider'].each do |attribute| %>
|
|
9
|
-
<% if params["host_ids_needing_#{attribute}_update"].present? %>
|
|
10
|
-
var td_element;
|
|
11
|
-
<% Host.authorized(:view_hosts, Host).where(:id => params["host_ids_needing_#{attribute}_update"]).each do |host| %>
|
|
12
|
-
<% template_invocation = @job_invocation.template_invocations.find { |template_invocation| template_invocation.host_id == host.id } %>
|
|
13
|
-
<% task = template_invocation.try(:run_host_job_task) %>
|
|
14
|
-
<% options = { :host => host, :task => task, :job_invocation => @job_invocation, :template_invocation => template_invocation } %>
|
|
15
|
-
td_element= $('#<%= dom_id(host) %>-<%= attribute %>');
|
|
16
|
-
td_element.replaceWith('<%=j render("host_#{attribute}_td", options) %>');
|
|
17
|
-
<% end %>
|
|
18
|
-
<% end %>
|
|
19
|
-
<% end %>
|
|
20
|
-
|
|
21
|
-
<% if @auto_refresh %>
|
|
22
|
-
delayed_refresh($('script#job_invocation_refresh').data('refresh-url'), job_invocation_refresh_data());
|
|
23
|
-
<% end %>
|