foreman_ansible 13.0.5 → 14.0.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 5c4af68ee17d90327c926378e19f7c6fc1cc7141c1379074ba6dca91cb6cc0ff
4
- data.tar.gz: 0b1fbfd87e48bcbd01fcef781388992bcf03ca274e3187011b02adf2cf379715
3
+ metadata.gz: 173634631b4f95f6e86f02775e026c17ba5a9a9f57d99e3f5491b57c89d8c9ca
4
+ data.tar.gz: 7dc19084e2cae6883903ef8cbb17fa221e9aea972efa851da351022989e603c8
5
5
  SHA512:
6
- metadata.gz: 645645d8d3a3be25011a1cf87ce63d3ee58b3016710c9dec5a5635fd4abf827f8da1a85118430feb4e59ac0fffd975be62c651a0c1657d256d27a57da7931887
7
- data.tar.gz: 98c523e75f9e5c5bfbee9de973d8dad7281a1d0af614e86ffefb1f9f77bc7305e27778ada8476dbfa55d7d040b7829a1941811bbf84db5db8cca26b7d5fbe917
6
+ metadata.gz: e16ac25e290b715368ea2d5a315aca31bd8c6723f9f19a974efedd926710c145c3f8532e33259599117d36497d7d0899783c324fa7db6ab3c2f035b2dfa4ecff
7
+ data.tar.gz: b492b84c46d9633770d1f75a7c151f7e4d55c52c1da465d834184248e66b0b1e6fe5a709376916142b29669f4bdb704ed9d5f2271be534387a3bdb86a7249adb
@@ -8,7 +8,7 @@ class UiAnsibleRolesController < ::Api::V2::BaseController
8
8
  end
9
9
 
10
10
  # restore original method from find_common to ignore resource nesting
11
- def resource_scope(options = {})
12
- @resource_scope ||= scope_for(resource_class, options)
11
+ def resource_scope(**kwargs)
12
+ @resource_scope ||= scope_for(resource_class, **kwargs)
13
13
  end
14
14
  end
@@ -19,6 +19,7 @@ template_inputs:
19
19
  options: "yes\r\nno"
20
20
  advanced: false
21
21
  value_type: plain
22
+ resource_type: Katello::ActivationKey
22
23
  hidden_value: false
23
24
  - name: Data telemetry
24
25
  required: true
@@ -51,27 +52,12 @@ kind: job_template
51
52
  ansible.builtin.package:
52
53
  name: convert2rhel
53
54
  state: present
54
-
55
- - name: Gather package facts
56
- package_facts:
57
- manager: auto
58
-
59
- - name: Set fact for package version
60
- set_fact:
61
- convert2rhel_version: "{{ ansible_facts.packages['convert2rhel'][0].version }}"
62
- when: "'convert2rhel' in ansible_facts.packages"
63
- no_log: true
64
-
65
55
  - name: Prepopulate katello-ca-consumer
66
56
  get_url:
67
57
  url: <%= subscription_manager_configuration_url(@host) %>
68
58
  dest: /usr/share/convert2rhel/subscription-manager/katello-ca-consumer-latest.noarch.rpm
69
- when:
70
- - "convert2rhel_version is version('2.0.0', '<')"
71
-
72
59
  - name: Start convert2rhel
73
- command: convert2rhel -y --activationkey "<%= input_resource('Activation Key').name %>" --org "<%= @host.organization.label %>"
74
-
60
+ command: convert2rhel -y --activationkey "<%= input_resource('Activation Key').name %>" --org "<%= @host.organization.label %>" --keep-rhsm
75
61
  <%- if input('Restart') == "yes" -%>
76
62
  - name: Reboot the machine
77
63
  reboot:
@@ -30,8 +30,7 @@ template_inputs:
30
30
  provider_type: Ansible
31
31
  kind: job_template
32
32
  model: JobTemplate
33
- %>
34
-
33
+ -%>
35
34
  # For Windows targets use the win_package module instead.
36
35
  ---
37
36
  - hosts: all
@@ -41,7 +40,7 @@ model: JobTemplate
41
40
  <%- end -%>
42
41
  tasks:
43
42
  - package:
44
- name: <%= input('name') %>
43
+ <%= indent(8) { to_yaml({"name" => input('name')}).gsub(/---\n/, '') } -%>
45
44
  state: <%= input('state') %>
46
45
  <%- if input('post_script').present? -%>
47
46
  post_tasks:
@@ -1,7 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  Foreman::Plugin.register :foreman_ansible do
4
- requires_foreman '>= 3.8.1'
4
+ requires_foreman '>= 3.10.0'
5
5
  register_gettext
6
6
 
7
7
  settings do
@@ -4,5 +4,5 @@
4
4
  # This way other parts of Foreman can just call ForemanAnsible::VERSION
5
5
  # and detect what version the plugin is running.
6
6
  module ForemanAnsible
7
- VERSION = '13.0.5'
7
+ VERSION = '14.0.0'
8
8
  end
@@ -1,4 +1,4 @@
1
- import React from 'react';
1
+ import React, { useState } from 'react';
2
2
  import { Provider } from 'react-redux';
3
3
  import thunk from 'redux-thunk';
4
4
  import { applyMiddleware, createStore, compose, combineReducers } from 'redux';
@@ -42,20 +42,21 @@ export const withReactRouter = Component => props => {
42
42
  };
43
43
 
44
44
  export const withMockedProvider = Component => props => {
45
- const ForemanContext = getForemanContext(ctx);
46
- // eslint-disable-next-line react/prop-types
47
- const { mocks, ...rest } = props;
48
-
49
- const ctx = {
45
+ const [context, setContext] = useState({
50
46
  metadata: {
51
47
  UISettings: {
52
48
  perPage: 20,
53
49
  },
54
50
  },
55
- };
51
+ });
52
+ const contextData = { context, setContext };
53
+ const ForemanContext = getForemanContext(contextData);
54
+
55
+ // eslint-disable-next-line react/prop-types
56
+ const { mocks, ...rest } = props;
56
57
 
57
58
  return (
58
- <ForemanContext.Provider value={ctx}>
59
+ <ForemanContext.Provider value={contextData}>
59
60
  <MockedProvider mocks={mocks}>
60
61
  <Component {...rest} />
61
62
  </MockedProvider>
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: foreman_ansible
3
3
  version: !ruby/object:Gem::Version
4
- version: 13.0.5
4
+ version: 14.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Daniel Lobato Garcia
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-05-06 00:00:00.000000000 Z
11
+ date: 2024-03-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: acts_as_list
@@ -485,7 +485,7 @@ homepage: https://github.com/theforeman/foreman_ansible
485
485
  licenses:
486
486
  - GPL-3.0
487
487
  metadata: {}
488
- post_install_message:
488
+ post_install_message:
489
489
  rdoc_options: []
490
490
  require_paths:
491
491
  - lib
@@ -500,8 +500,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
500
500
  - !ruby/object:Gem::Version
501
501
  version: '0'
502
502
  requirements: []
503
- rubygems_version: 3.3.27
504
- signing_key:
503
+ rubygems_version: 3.2.3
504
+ signing_key:
505
505
  specification_version: 4
506
506
  summary: Ansible integration with Foreman (theforeman.org)
507
507
  test_files: