foreman_acd 0.0.3 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (118) hide show
  1. checksums.yaml +4 -4
  2. data/app/controllers/foreman_acd/ansible_playbooks_controller.rb +122 -0
  3. data/app/controllers/foreman_acd/api/v2/ansible_playbooks_controller.rb +54 -0
  4. data/app/controllers/foreman_acd/api/v2/app_definitions_controller.rb +1 -2
  5. data/app/controllers/foreman_acd/api/v2/app_instances_controller.rb +54 -0
  6. data/app/controllers/foreman_acd/api/v2/app_playbooks_controller.rb +0 -0
  7. data/app/controllers/foreman_acd/app_definitions_controller.rb +35 -4
  8. data/app/controllers/foreman_acd/app_instances_controller.rb +43 -87
  9. data/app/controllers/foreman_acd/concerns/ansible_playbook_parameters.rb +23 -0
  10. data/app/controllers/foreman_acd/concerns/app_definition_parameters.rb +1 -1
  11. data/app/controllers/foreman_acd/concerns/app_instance_parameters.rb +1 -1
  12. data/app/controllers/ui_acd_controller.rb +11 -4
  13. data/app/models/foreman_acd/ansible_playbook.rb +50 -0
  14. data/app/models/foreman_acd/app_definition.rb +2 -1
  15. data/app/models/foreman_acd/app_instance.rb +7 -0
  16. data/app/services/foreman_acd/app_configurator.rb +70 -0
  17. data/app/services/foreman_acd/app_deployer.rb +143 -0
  18. data/app/services/foreman_acd/inventory_creator.rb +67 -0
  19. data/app/views/foreman_acd/ansible_playbooks/_form.html.erb +21 -0
  20. data/app/views/foreman_acd/ansible_playbooks/edit.html.erb +3 -0
  21. data/app/views/foreman_acd/ansible_playbooks/index.html.erb +30 -0
  22. data/app/views/foreman_acd/ansible_playbooks/new.html.erb +3 -0
  23. data/app/views/foreman_acd/api/v2/ansible_playbooks/base.json.rabl +3 -0
  24. data/app/views/foreman_acd/api/v2/ansible_playbooks/index.json.rabl +3 -0
  25. data/app/views/foreman_acd/api/v2/ansible_playbooks/show.json.rabl +3 -0
  26. data/app/views/foreman_acd/api/v2/app_definitions/base.json.rabl +3 -0
  27. data/app/views/foreman_acd/api/v2/app_definitions/index.json.rabl +3 -0
  28. data/app/views/foreman_acd/api/v2/app_definitions/show.json.rabl +3 -0
  29. data/app/views/foreman_acd/api/v2/app_instances/base.json.rabl +3 -0
  30. data/app/views/foreman_acd/api/v2/app_instances/index.json.rabl +3 -0
  31. data/app/views/foreman_acd/api/v2/app_instances/show.json.rabl +3 -0
  32. data/app/views/foreman_acd/app_definitions/_form.html.erb +25 -19
  33. data/app/views/foreman_acd/app_definitions/edit.html.erb +5 -0
  34. data/app/views/foreman_acd/app_definitions/import.html.erb +18 -0
  35. data/app/views/foreman_acd/app_definitions/index.html.erb +9 -5
  36. data/app/views/foreman_acd/app_instances/_form.html.erb +10 -8
  37. data/app/views/foreman_acd/app_instances/deploy.html.erb +19 -0
  38. data/app/views/foreman_acd/app_instances/index.html.erb +10 -5
  39. data/app/views/foreman_acd/app_instances/report.html.erb +19 -0
  40. data/app/views/templates/job/run_acd_ansible_playbook.erb +49 -0
  41. data/app/views/ui_acd/ansible_data.json.rabl +6 -0
  42. data/app/views/ui_acd/app.json.rabl +6 -2
  43. data/app/views/ui_acd/app_definition.json.rabl +1 -1
  44. data/app/views/ui_acd/{fdata.json.rabl → foreman_data.json.rabl} +1 -1
  45. data/config/routes.rb +31 -1
  46. data/db/migrate/20190610202252_create_app_definitions.rb +1 -3
  47. data/db/migrate/20190625140305_create_app_instances.rb +1 -1
  48. data/db/migrate/20200916091018_create_ansible_playbooks.rb +20 -0
  49. data/db/migrate/20200917120220_add_ansible_playbook_id.rb +14 -0
  50. data/db/migrate/20201016002819_add_ansible_vars_all_to_app_definitions.rb +5 -0
  51. data/db/migrate/20201016104338_add_ansible_vars_all_to_app_instances.rb +5 -0
  52. data/db/seeds.d/75-job_templates.rb +8 -0
  53. data/lib/foreman_acd/engine.rb +3 -0
  54. data/lib/foreman_acd/plugin.rb +72 -4
  55. data/lib/foreman_acd/version.rb +1 -1
  56. data/package.json +2 -1
  57. data/webpack/components/ApplicationDefinition/ApplicationDefinition.js +376 -0
  58. data/webpack/components/ApplicationDefinition/ApplicationDefinition.scss +1 -0
  59. data/webpack/components/ApplicationDefinition/ApplicationDefinitionActions.js +295 -0
  60. data/webpack/components/ApplicationDefinition/ApplicationDefinitionConstants.js +14 -0
  61. data/webpack/components/ApplicationDefinition/ApplicationDefinitionHelper.js +26 -0
  62. data/webpack/components/ApplicationDefinition/ApplicationDefinitionReducer.js +243 -0
  63. data/webpack/components/ApplicationDefinition/ApplicationDefinitionSelectors.js +8 -0
  64. data/webpack/components/ApplicationDefinition/components/AnsiblePlaybookSelector.js +49 -0
  65. data/webpack/components/ApplicationDefinition/index.js +33 -0
  66. data/webpack/components/ApplicationInstance/ApplicationInstance.js +412 -0
  67. data/webpack/components/ApplicationInstance/ApplicationInstance.scss +11 -0
  68. data/webpack/components/ApplicationInstance/ApplicationInstanceActions.js +239 -0
  69. data/webpack/components/ApplicationInstance/ApplicationInstanceConstants.js +14 -0
  70. data/webpack/components/ApplicationInstance/ApplicationInstanceReducer.js +295 -0
  71. data/webpack/components/ApplicationInstance/ApplicationInstanceSelectors.js +9 -0
  72. data/webpack/components/ApplicationInstance/components/AppDefinitionSelector.js +49 -0
  73. data/webpack/components/ApplicationInstance/components/Service.js +30 -0
  74. data/webpack/components/ApplicationInstance/components/ServiceCounter.js +37 -0
  75. data/webpack/components/ApplicationInstance/index.js +35 -0
  76. data/webpack/components/ApplicationInstanceReport/ApplicationInstanceReport.js +155 -0
  77. data/webpack/components/ApplicationInstanceReport/ApplicationInstanceReport.scss +27 -0
  78. data/webpack/components/ApplicationInstanceReport/ApplicationInstanceReportActions.js +86 -0
  79. data/webpack/components/ApplicationInstanceReport/ApplicationInstanceReportConstants.js +4 -0
  80. data/webpack/components/ApplicationInstanceReport/ApplicationInstanceReportReducer.js +52 -0
  81. data/webpack/components/ApplicationInstanceReport/ApplicationInstanceReportSelectors.js +5 -0
  82. data/webpack/components/ApplicationInstanceReport/components/ReportViewer.js +26 -0
  83. data/webpack/components/ApplicationInstanceReport/index.js +27 -0
  84. data/webpack/components/ParameterSelection/ParameterSelection.js +96 -183
  85. data/webpack/components/ParameterSelection/ParameterSelection.scss +10 -3
  86. data/webpack/components/ParameterSelection/ParameterSelectionActions.js +72 -104
  87. data/webpack/components/ParameterSelection/ParameterSelectionConstants.js +14 -19
  88. data/webpack/components/ParameterSelection/ParameterSelectionHelper.js +3 -35
  89. data/webpack/components/ParameterSelection/ParameterSelectionReducer.js +100 -83
  90. data/webpack/components/ParameterSelection/ParameterSelectionSelectors.js +3 -7
  91. data/webpack/components/ParameterSelection/__fixtures__/parameterSelection.fixtures.js +12 -21
  92. data/webpack/components/ParameterSelection/__fixtures__/parameterSelectionData_1.fixtures.js +1 -1
  93. data/webpack/components/ParameterSelection/__fixtures__/parameterSelectionReducer.fixtures.js +3 -45
  94. data/webpack/components/ParameterSelection/__tests__/ParameterSelection.test.js +20 -0
  95. data/webpack/components/ParameterSelection/__tests__/ParameterSelectionReducer.test.js +22 -46
  96. data/webpack/components/ParameterSelection/__tests__/ParameterSelectionSelectors.test.js +6 -6
  97. data/webpack/components/ParameterSelection/__tests__/__snapshots__/ParameterSelection.test.js.snap +40 -265
  98. data/webpack/components/ParameterSelection/__tests__/__snapshots__/ParameterSelectionReducer.test.js.snap +11 -96
  99. data/webpack/components/ParameterSelection/__tests__/__snapshots__/ParameterSelectionSelectors.test.js.snap +3 -9
  100. data/webpack/components/ParameterSelection/index.js +6 -8
  101. data/webpack/components/common/AddTableEntry.js +30 -0
  102. data/webpack/components/common/DeleteTableEntry.js +39 -0
  103. data/webpack/components/common/ExtSelect.js +43 -0
  104. data/webpack/components/common/RailsData.js +27 -0
  105. data/webpack/components/common/__tests__/AddTableEntry.test.js +26 -0
  106. data/webpack/components/common/__tests__/DeleteTableEntry.test.js +29 -0
  107. data/webpack/components/common/__tests__/ExtSelect.test.js +38 -0
  108. data/webpack/components/common/__tests__/RailsData.test.js +16 -0
  109. data/webpack/components/common/__tests__/__snapshots__/AddParameter.test.js.snap +35 -0
  110. data/webpack/components/common/__tests__/__snapshots__/AddTableEntry.test.js.snap +35 -0
  111. data/webpack/components/common/__tests__/__snapshots__/DeleteParameter.test.js.snap +41 -0
  112. data/webpack/components/common/__tests__/__snapshots__/DeleteTableEntry.test.js.snap +41 -0
  113. data/webpack/components/common/__tests__/__snapshots__/ExtSelect.test.js.snap +18 -0
  114. data/webpack/components/common/__tests__/__snapshots__/RailsData.test.js.snap +10 -0
  115. data/webpack/helper.js +20 -0
  116. data/webpack/index.js +6 -0
  117. data/webpack/reducer.js +43 -3
  118. metadata +85 -39
@@ -0,0 +1,38 @@
1
+ import { testComponentSnapshotsWithFixtures } from 'react-redux-test-utils';
2
+
3
+ import ExtSelect from '../ExtSelect';
4
+
5
+ const noop = () => {};
6
+
7
+ const fixtures = {
8
+ 'should render selection field': {
9
+ hidden: false,
10
+ editable: false,
11
+ viewText: '',
12
+ selectValue: '1',
13
+ onChange: noop,
14
+ options: { first: 'first', second: 'second'},
15
+ additionalData: { moreData: 'moooore' },
16
+ },
17
+ 'should render hidden selection field': {
18
+ hidden: true,
19
+ editable: false,
20
+ viewText: '',
21
+ selectValue: null,
22
+ onChange: noop,
23
+ options: {},
24
+ additionalData: {},
25
+ },
26
+ 'should render disabled button': {
27
+ hidden: false,
28
+ editable: true,
29
+ viewText: 'Awesome Text',
30
+ selectValue: '0',
31
+ onChange: noop,
32
+ options: { first: 'first', second: 'second'},
33
+ additionalData: {},
34
+ },
35
+ };
36
+
37
+ describe('ExtSelect', () =>
38
+ testComponentSnapshotsWithFixtures(ExtSelect, fixtures));
@@ -0,0 +1,16 @@
1
+ import { testComponentSnapshotsWithFixtures } from 'react-redux-test-utils';
2
+
3
+ import RailsData from '../RailsData';
4
+
5
+ const noop = () => {};
6
+
7
+ const fixtures = {
8
+ 'should render rails data input field': {
9
+ view: 'nice_view',
10
+ parameter: 'nice_param',
11
+ value: 'nice_value',
12
+ },
13
+ };
14
+
15
+ describe('RailsData', () =>
16
+ testComponentSnapshotsWithFixtures(RailsData, fixtures));
@@ -0,0 +1,35 @@
1
+ // Jest Snapshot v1, https://goo.gl/fbAQLP
2
+
3
+ exports[`AddParameter should render add parameter 1`] = `
4
+ <Button
5
+ active={false}
6
+ block={false}
7
+ bsClass="btn"
8
+ bsStyle="default"
9
+ disabled={false}
10
+ onClick={[Function]}
11
+ >
12
+ <Icon
13
+ name="plus"
14
+ type="fa"
15
+ />
16
+ </Button>
17
+ `;
18
+
19
+ exports[`AddParameter should render disabled button 1`] = `
20
+ <Button
21
+ active={false}
22
+ block={false}
23
+ bsClass="btn"
24
+ bsStyle="default"
25
+ disabled={true}
26
+ onClick={[Function]}
27
+ >
28
+ <Icon
29
+ name="plus"
30
+ type="fa"
31
+ />
32
+ </Button>
33
+ `;
34
+
35
+ exports[`AddParameter should render hidden button 1`] = `""`;
@@ -0,0 +1,35 @@
1
+ // Jest Snapshot v1, https://goo.gl/fbAQLP
2
+
3
+ exports[`AddTableEntry should render add parameter 1`] = `
4
+ <Button
5
+ active={false}
6
+ block={false}
7
+ bsClass="btn"
8
+ bsStyle="default"
9
+ disabled={false}
10
+ onClick={[Function]}
11
+ >
12
+ <Icon
13
+ name="plus"
14
+ type="fa"
15
+ />
16
+ </Button>
17
+ `;
18
+
19
+ exports[`AddTableEntry should render disabled button 1`] = `
20
+ <Button
21
+ active={false}
22
+ block={false}
23
+ bsClass="btn"
24
+ bsStyle="default"
25
+ disabled={true}
26
+ onClick={[Function]}
27
+ >
28
+ <Icon
29
+ name="plus"
30
+ type="fa"
31
+ />
32
+ </Button>
33
+ `;
34
+
35
+ exports[`AddTableEntry should render hidden button 1`] = `""`;
@@ -0,0 +1,41 @@
1
+ // Jest Snapshot v1, https://goo.gl/fbAQLP
2
+
3
+ exports[`DeleteParameter should render delete parameter 1`] = `
4
+ <span>
5
+  
6
+ <Button
7
+ active={false}
8
+ block={false}
9
+ bsClass="btn"
10
+ bsStyle="default"
11
+ disabled={false}
12
+ onClick={[Function]}
13
+ >
14
+ <Icon
15
+ name="delete"
16
+ type="pf"
17
+ />
18
+ </Button>
19
+ </span>
20
+ `;
21
+
22
+ exports[`DeleteParameter should render disabled button 1`] = `
23
+ <span>
24
+  
25
+ <Button
26
+ active={false}
27
+ block={false}
28
+ bsClass="btn"
29
+ bsStyle="default"
30
+ disabled={true}
31
+ onClick={[Function]}
32
+ >
33
+ <Icon
34
+ name="delete"
35
+ type="pf"
36
+ />
37
+ </Button>
38
+ </span>
39
+ `;
40
+
41
+ exports[`DeleteParameter should render hidden button 1`] = `""`;
@@ -0,0 +1,41 @@
1
+ // Jest Snapshot v1, https://goo.gl/fbAQLP
2
+
3
+ exports[`DeleteTableEntry should render delete parameter 1`] = `
4
+ <span>
5
+  
6
+ <Button
7
+ active={false}
8
+ block={false}
9
+ bsClass="btn"
10
+ bsStyle="default"
11
+ disabled={false}
12
+ onClick={[Function]}
13
+ >
14
+ <Icon
15
+ name="delete"
16
+ type="pf"
17
+ />
18
+ </Button>
19
+ </span>
20
+ `;
21
+
22
+ exports[`DeleteTableEntry should render disabled button 1`] = `
23
+ <span>
24
+  
25
+ <Button
26
+ active={false}
27
+ block={false}
28
+ bsClass="btn"
29
+ bsStyle="default"
30
+ disabled={true}
31
+ onClick={[Function]}
32
+ >
33
+ <Icon
34
+ name="delete"
35
+ type="pf"
36
+ />
37
+ </Button>
38
+ </span>
39
+ `;
40
+
41
+ exports[`DeleteTableEntry should render hidden button 1`] = `""`;
@@ -0,0 +1,18 @@
1
+ // Jest Snapshot v1, https://goo.gl/fbAQLP
2
+
3
+ exports[`ExtSelect should render disabled button 1`] = `
4
+ <Select
5
+ onChange={[Function]}
6
+ options={
7
+ Object {
8
+ "first": "first",
9
+ "second": "second",
10
+ }
11
+ }
12
+ value="0"
13
+ />
14
+ `;
15
+
16
+ exports[`ExtSelect should render hidden selection field 1`] = `""`;
17
+
18
+ exports[`ExtSelect should render selection field 1`] = `<div />`;
@@ -0,0 +1,10 @@
1
+ // Jest Snapshot v1, https://goo.gl/fbAQLP
2
+
3
+ exports[`RailsData should render rails data input field 1`] = `
4
+ <input
5
+ id="foreman_acd_nice_view_nice_param"
6
+ name="foreman_acd_nice_view[nice_param]"
7
+ type="hidden"
8
+ value="nice_value"
9
+ />
10
+ `;
@@ -0,0 +1,20 @@
1
+ // Some small helper methods
2
+
3
+ function arrayToObject(arr, id, value) {
4
+ var rv = {};
5
+ for (var i = 0; i < arr.length; ++i)
6
+ rv[arr[i][id]] = arr[i][value];
7
+ return rv;
8
+ }
9
+
10
+ function arrayToObjectObj(arr, id) {
11
+ var rv = {};
12
+ for (var i = 0; i < arr.length; ++i)
13
+ rv[arr[i][id]] = arr[i];
14
+ return rv;
15
+ }
16
+
17
+ export {
18
+ arrayToObject,
19
+ arrayToObjectObj
20
+ };
@@ -1,8 +1,14 @@
1
1
  import componentRegistry from 'foremanReact/components/componentRegistry';
2
2
  import injectReducer from 'foremanReact/redux/reducers/registerReducer';
3
3
  import ParameterSelection from './components/ParameterSelection';
4
+ import ApplicationDefinition from './components/ApplicationDefinition';
5
+ import ApplicationInstance from './components/ApplicationInstance';
6
+ import ApplicationInstanceReport from './components/ApplicationInstanceReport';
4
7
  import reducer from './reducer';
5
8
 
6
9
  injectReducer('foremanAcd', reducer);
7
10
 
8
11
  componentRegistry.register({ name: 'ParameterSelection', type: ParameterSelection, });
12
+ componentRegistry.register({ name: 'ApplicationDefinition', type: ApplicationDefinition, });
13
+ componentRegistry.register({ name: 'ApplicationInstance', type: ApplicationInstance, });
14
+ componentRegistry.register({ name: 'ApplicationInstanceReport', type: ApplicationInstanceReport, });
@@ -1,7 +1,47 @@
1
1
  import { combineReducers } from 'redux';
2
2
 
3
3
  import parameterSelectionParameters from './components/ParameterSelection/ParameterSelectionReducer';
4
+ import applicationDefinitionConf from './components/ApplicationDefinition/ApplicationDefinitionReducer';
5
+ import applicationInstanceConf from './components/ApplicationInstance/ApplicationInstanceReducer';
6
+ import applicationInstanceReport from './components/ApplicationInstanceReport/ApplicationInstanceReportReducer';
4
7
 
5
- export default combineReducers({
6
- parameterSelectionParameters,
7
- });
8
+ import {
9
+ APPLICATION_DEFINITION_FOREMAN_PARAMETER_SELECTION_MODAL_CLOSE,
10
+ APPLICATION_DEFINITION_ANSIBLE_PARAMETER_SELECTION_MODAL_CLOSE,
11
+ } from './components/ApplicationDefinition/ApplicationDefinitionConstants';
12
+
13
+ import {
14
+ APPLICATION_INSTANCE_FOREMAN_PARAMETER_SELECTION_MODAL_CLOSE,
15
+ APPLICATION_INSTANCE_ANSIBLE_PARAMETER_SELECTION_MODAL_CLOSE,
16
+ } from './components/ApplicationInstance/ApplicationInstanceConstants';
17
+
18
+ const rootReducer = (state = {}, action) => {
19
+
20
+ const param_state = parameterSelectionParameters(state.parameterSelectionParameters, action);
21
+ const app_ins_report_state = applicationInstanceReport(state.applicationInstanceReport, action);
22
+
23
+ if (action.type == APPLICATION_DEFINITION_FOREMAN_PARAMETER_SELECTION_MODAL_CLOSE) {
24
+ action.payload.parameterSelection = param_state.parameters;
25
+ }
26
+ if (action.type == APPLICATION_DEFINITION_ANSIBLE_PARAMETER_SELECTION_MODAL_CLOSE) {
27
+ action.payload.parameterSelection = param_state.parameters;
28
+ }
29
+ const app_def_state = applicationDefinitionConf(state.applicationDefinitionConf, action);
30
+
31
+ if (action.type == APPLICATION_INSTANCE_FOREMAN_PARAMETER_SELECTION_MODAL_CLOSE) {
32
+ action.payload.parameterSelection = param_state.parameters;
33
+ }
34
+ if (action.type == APPLICATION_INSTANCE_ANSIBLE_PARAMETER_SELECTION_MODAL_CLOSE) {
35
+ action.payload.parameterSelection = param_state.parameters;
36
+ }
37
+ const app_ins_state = applicationInstanceConf(state.applicationInstanceConf, action);
38
+
39
+ return {
40
+ applicationDefinitionConf: app_def_state,
41
+ applicationInstanceConf: app_ins_state,
42
+ parameterSelectionParameters: param_state,
43
+ applicationInstanceReport: app_ins_report_state,
44
+ };
45
+ };
46
+
47
+ export default rootReducer;
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: foreman_acd
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - ATIX AG
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-11-25 00:00:00.000000000 Z
11
+ date: 2020-11-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rubocop
@@ -16,56 +16,28 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: 0.71.0
19
+ version: 0.80.0
20
20
  type: :development
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: 0.71.0
26
+ version: 0.80.0
27
27
  - !ruby/object:Gem::Dependency
28
- name: rubocop-checkstyle_formatter
28
+ name: foreman_remote_execution
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - "~>"
32
- - !ruby/object:Gem::Version
33
- version: '0.2'
34
- type: :development
35
- prerelease: false
36
- version_requirements: !ruby/object:Gem::Requirement
37
- requirements:
38
- - - "~>"
31
+ - - ">="
39
32
  - !ruby/object:Gem::Version
40
- version: '0.2'
41
- - !ruby/object:Gem::Dependency
42
- name: rubocop-performance
43
- requirement: !ruby/object:Gem::Requirement
44
- requirements:
45
- - - "~>"
46
- - !ruby/object:Gem::Version
47
- version: 1.4.0
48
- type: :development
33
+ version: 3.3.0
34
+ type: :runtime
49
35
  prerelease: false
50
36
  version_requirements: !ruby/object:Gem::Requirement
51
37
  requirements:
52
- - - "~>"
53
- - !ruby/object:Gem::Version
54
- version: 1.4.0
55
- - !ruby/object:Gem::Dependency
56
- name: rubocop-rails
57
- requirement: !ruby/object:Gem::Requirement
58
- requirements:
59
- - - "~>"
60
- - !ruby/object:Gem::Version
61
- version: 2.0.1
62
- type: :development
63
- prerelease: false
64
- version_requirements: !ruby/object:Gem::Requirement
65
- requirements:
66
- - - "~>"
38
+ - - ">="
67
39
  - !ruby/object:Gem::Version
68
- version: 2.0.1
40
+ version: 3.3.0
69
41
  description: Foreman plugin to provide application centric deployment and self service
70
42
  portal
71
43
  email:
@@ -78,35 +50,67 @@ files:
78
50
  - README.md
79
51
  - Rakefile
80
52
  - app/assets/javascripts/foreman_acd/acd_dummy.js
53
+ - app/controllers/foreman_acd/ansible_playbooks_controller.rb
54
+ - app/controllers/foreman_acd/api/v2/ansible_playbooks_controller.rb
81
55
  - app/controllers/foreman_acd/api/v2/app_definitions_controller.rb
56
+ - app/controllers/foreman_acd/api/v2/app_instances_controller.rb
57
+ - app/controllers/foreman_acd/api/v2/app_playbooks_controller.rb
82
58
  - app/controllers/foreman_acd/api/v2/base_controller.rb
83
59
  - app/controllers/foreman_acd/app_definitions_controller.rb
84
60
  - app/controllers/foreman_acd/app_instances_controller.rb
85
61
  - app/controllers/foreman_acd/application_controller.rb
62
+ - app/controllers/foreman_acd/concerns/ansible_playbook_parameters.rb
86
63
  - app/controllers/foreman_acd/concerns/app_definition_parameters.rb
87
64
  - app/controllers/foreman_acd/concerns/app_instance_parameters.rb
88
65
  - app/controllers/ui_acd_controller.rb
66
+ - app/models/foreman_acd/ansible_playbook.rb
89
67
  - app/models/foreman_acd/app_definition.rb
90
68
  - app/models/foreman_acd/app_instance.rb
69
+ - app/services/foreman_acd/app_configurator.rb
70
+ - app/services/foreman_acd/app_deployer.rb
71
+ - app/services/foreman_acd/inventory_creator.rb
72
+ - app/views/foreman_acd/ansible_playbooks/_form.html.erb
73
+ - app/views/foreman_acd/ansible_playbooks/edit.html.erb
74
+ - app/views/foreman_acd/ansible_playbooks/index.html.erb
75
+ - app/views/foreman_acd/ansible_playbooks/new.html.erb
76
+ - app/views/foreman_acd/api/v2/ansible_playbooks/base.json.rabl
77
+ - app/views/foreman_acd/api/v2/ansible_playbooks/index.json.rabl
78
+ - app/views/foreman_acd/api/v2/ansible_playbooks/show.json.rabl
79
+ - app/views/foreman_acd/api/v2/app_definitions/base.json.rabl
80
+ - app/views/foreman_acd/api/v2/app_definitions/index.json.rabl
81
+ - app/views/foreman_acd/api/v2/app_definitions/show.json.rabl
82
+ - app/views/foreman_acd/api/v2/app_instances/base.json.rabl
83
+ - app/views/foreman_acd/api/v2/app_instances/index.json.rabl
84
+ - app/views/foreman_acd/api/v2/app_instances/show.json.rabl
91
85
  - app/views/foreman_acd/app_definitions/_form.html.erb
92
86
  - app/views/foreman_acd/app_definitions/edit.html.erb
87
+ - app/views/foreman_acd/app_definitions/import.html.erb
93
88
  - app/views/foreman_acd/app_definitions/index.html.erb
94
89
  - app/views/foreman_acd/app_definitions/new.html.erb
95
90
  - app/views/foreman_acd/app_instances/_form.html.erb
91
+ - app/views/foreman_acd/app_instances/deploy.html.erb
96
92
  - app/views/foreman_acd/app_instances/edit.html.erb
97
93
  - app/views/foreman_acd/app_instances/index.html.erb
98
94
  - app/views/foreman_acd/app_instances/new.html.erb
95
+ - app/views/foreman_acd/app_instances/report.html.erb
96
+ - app/views/templates/job/run_acd_ansible_playbook.erb
97
+ - app/views/ui_acd/ansible_data.json.rabl
99
98
  - app/views/ui_acd/app.json.rabl
100
99
  - app/views/ui_acd/app_definition.json.rabl
101
100
  - app/views/ui_acd/computeprofile.json.rabl
102
101
  - app/views/ui_acd/domain.json.rabl
103
102
  - app/views/ui_acd/environment.json.rabl
104
- - app/views/ui_acd/fdata.json.rabl
103
+ - app/views/ui_acd/foreman_data.json.rabl
105
104
  - app/views/ui_acd/lifecycle_environment.json.rabl
106
105
  - app/views/ui_acd/ptable.json.rabl
107
106
  - config/routes.rb
108
107
  - db/migrate/20190610202252_create_app_definitions.rb
109
108
  - db/migrate/20190625140305_create_app_instances.rb
109
+ - db/migrate/20200916091018_create_ansible_playbooks.rb
110
+ - db/migrate/20200917120220_add_ansible_playbook_id.rb
111
+ - db/migrate/20201016002819_add_ansible_vars_all_to_app_definitions.rb
112
+ - db/migrate/20201016104338_add_ansible_vars_all_to_app_instances.rb
113
+ - db/seeds.d/75-job_templates.rb
110
114
  - lib/foreman_acd.rb
111
115
  - lib/foreman_acd/engine.rb
112
116
  - lib/foreman_acd/plugin.rb
@@ -125,6 +129,33 @@ files:
125
129
  - test/models/app_instance_test.rb
126
130
  - test/test_plugin_helper.rb
127
131
  - webpack/__mocks__/foremanReact/components/common/forms/Select.js
132
+ - webpack/components/ApplicationDefinition/ApplicationDefinition.js
133
+ - webpack/components/ApplicationDefinition/ApplicationDefinition.scss
134
+ - webpack/components/ApplicationDefinition/ApplicationDefinitionActions.js
135
+ - webpack/components/ApplicationDefinition/ApplicationDefinitionConstants.js
136
+ - webpack/components/ApplicationDefinition/ApplicationDefinitionHelper.js
137
+ - webpack/components/ApplicationDefinition/ApplicationDefinitionReducer.js
138
+ - webpack/components/ApplicationDefinition/ApplicationDefinitionSelectors.js
139
+ - webpack/components/ApplicationDefinition/components/AnsiblePlaybookSelector.js
140
+ - webpack/components/ApplicationDefinition/index.js
141
+ - webpack/components/ApplicationInstance/ApplicationInstance.js
142
+ - webpack/components/ApplicationInstance/ApplicationInstance.scss
143
+ - webpack/components/ApplicationInstance/ApplicationInstanceActions.js
144
+ - webpack/components/ApplicationInstance/ApplicationInstanceConstants.js
145
+ - webpack/components/ApplicationInstance/ApplicationInstanceReducer.js
146
+ - webpack/components/ApplicationInstance/ApplicationInstanceSelectors.js
147
+ - webpack/components/ApplicationInstance/components/AppDefinitionSelector.js
148
+ - webpack/components/ApplicationInstance/components/Service.js
149
+ - webpack/components/ApplicationInstance/components/ServiceCounter.js
150
+ - webpack/components/ApplicationInstance/index.js
151
+ - webpack/components/ApplicationInstanceReport/ApplicationInstanceReport.js
152
+ - webpack/components/ApplicationInstanceReport/ApplicationInstanceReport.scss
153
+ - webpack/components/ApplicationInstanceReport/ApplicationInstanceReportActions.js
154
+ - webpack/components/ApplicationInstanceReport/ApplicationInstanceReportConstants.js
155
+ - webpack/components/ApplicationInstanceReport/ApplicationInstanceReportReducer.js
156
+ - webpack/components/ApplicationInstanceReport/ApplicationInstanceReportSelectors.js
157
+ - webpack/components/ApplicationInstanceReport/components/ReportViewer.js
158
+ - webpack/components/ApplicationInstanceReport/index.js
128
159
  - webpack/components/ParameterSelection/ParameterSelection.js
129
160
  - webpack/components/ParameterSelection/ParameterSelection.scss
130
161
  - webpack/components/ParameterSelection/ParameterSelectionActions.js
@@ -142,6 +173,21 @@ files:
142
173
  - webpack/components/ParameterSelection/__tests__/__snapshots__/ParameterSelectionReducer.test.js.snap
143
174
  - webpack/components/ParameterSelection/__tests__/__snapshots__/ParameterSelectionSelectors.test.js.snap
144
175
  - webpack/components/ParameterSelection/index.js
176
+ - webpack/components/common/AddTableEntry.js
177
+ - webpack/components/common/DeleteTableEntry.js
178
+ - webpack/components/common/ExtSelect.js
179
+ - webpack/components/common/RailsData.js
180
+ - webpack/components/common/__tests__/AddTableEntry.test.js
181
+ - webpack/components/common/__tests__/DeleteTableEntry.test.js
182
+ - webpack/components/common/__tests__/ExtSelect.test.js
183
+ - webpack/components/common/__tests__/RailsData.test.js
184
+ - webpack/components/common/__tests__/__snapshots__/AddParameter.test.js.snap
185
+ - webpack/components/common/__tests__/__snapshots__/AddTableEntry.test.js.snap
186
+ - webpack/components/common/__tests__/__snapshots__/DeleteParameter.test.js.snap
187
+ - webpack/components/common/__tests__/__snapshots__/DeleteTableEntry.test.js.snap
188
+ - webpack/components/common/__tests__/__snapshots__/ExtSelect.test.js.snap
189
+ - webpack/components/common/__tests__/__snapshots__/RailsData.test.js.snap
190
+ - webpack/helper.js
145
191
  - webpack/index.js
146
192
  - webpack/reducer.js
147
193
  - webpack/test_setup.js