foreman_acd 0.6.0 → 0.9.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (197) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +5 -5
  3. data/app/controllers/foreman_acd/ansible_playbooks_controller.rb +90 -0
  4. data/app/controllers/foreman_acd/app_definitions_controller.rb +104 -7
  5. data/app/controllers/foreman_acd/app_instances_controller.rb +34 -32
  6. data/app/controllers/foreman_acd/concerns/ansible_playbook_parameters.rb +1 -1
  7. data/app/controllers/foreman_acd/concerns/app_instance_mixins.rb +36 -0
  8. data/app/controllers/foreman_acd/remote_execution_controller.rb +37 -21
  9. data/app/controllers/ui_acd_controller.rb +42 -3
  10. data/app/lib/actions/foreman_acd/deploy_all_hosts.rb +12 -7
  11. data/app/lib/actions/foreman_acd/run_configurator.rb +11 -7
  12. data/app/models/concerns/foreman_acd/host_managed_extensions.rb +41 -28
  13. data/app/models/foreman_acd/acd_provider.rb +7 -1
  14. data/app/models/foreman_acd/ansible_playbook.rb +2 -1
  15. data/app/models/foreman_acd/app_instance.rb +48 -3
  16. data/app/models/foreman_acd/foreman_host.rb +8 -0
  17. data/app/services/foreman_acd/acd_proxy_proxy_selector.rb +17 -0
  18. data/app/services/foreman_acd/app_configurator.rb +59 -15
  19. data/app/services/foreman_acd/app_deployer.rb +27 -4
  20. data/app/services/foreman_acd/inventory_creator.rb +25 -1
  21. data/app/views/foreman_acd/ansible_playbooks/_form.html.erb +41 -7
  22. data/app/views/foreman_acd/app_definitions/_form.html.erb +5 -1
  23. data/app/views/foreman_acd/app_definitions/import.html.erb +20 -1
  24. data/app/views/foreman_acd/app_definitions/index.html.erb +3 -6
  25. data/app/views/foreman_acd/app_instances/_form.html.erb +5 -1
  26. data/app/views/foreman_acd/app_instances/index.html.erb +18 -12
  27. data/app/views/foreman_acd/app_instances/report.html.erb +8 -3
  28. data/app/views/templates/job/run_acd_ansible_playbook.erb +1 -1
  29. data/app/views/ui_acd/host_report.json.rabl +4 -0
  30. data/app/views/ui_acd/report_data.json.rabl +10 -0
  31. data/app/views/ui_acd/validate_hostname.json.rabl +6 -0
  32. data/config/routes.rb +6 -0
  33. data/db/migrate/20210316151145_add_git_commit_to_ansible_playbooks.rb +8 -0
  34. data/db/migrate/20210503122809_add_git_url_to_ansible_playbooks.rb +8 -0
  35. data/db/migrate/20210818125913_add_is_existing_host_to_foreman_host.rb +8 -0
  36. data/db/migrate/20210902110645_add_initial_configure_task.rb +8 -0
  37. data/db/seeds.d/75-job_templates.rb +1 -1
  38. data/lib/foreman_acd/engine.rb +26 -4
  39. data/lib/foreman_acd/plugin.rb +9 -18
  40. data/lib/foreman_acd/version.rb +1 -1
  41. data/lib/foreman_acd.rb +30 -0
  42. data/lib/tasks/foreman_acd_tasks.rake +0 -12
  43. data/package.json +8 -22
  44. data/test/controllers/ansible_playbooks_controller_test.rb +1 -1
  45. data/test/controllers/app_instances_controller_test.rb +8 -3
  46. data/test/controllers/ui_acd_controller_test.rb +25 -6
  47. data/test/factories/foreman_acd_factories.rb +18 -4
  48. data/test/models/acd_provider_test.rb +37 -0
  49. data/test/models/ansible_playbook_test.rb +11 -0
  50. data/test/models/app_definition_test.rb +1 -1
  51. data/test/models/app_instance_test.rb +2 -0
  52. data/test/models/concerns/host_extensions_test.rb +26 -0
  53. data/test/models/foreman_host_test.rb +12 -0
  54. data/webpack/__mocks__/foremanReact/API.js +2 -0
  55. data/webpack/__mocks__/foremanReact/common/I18n.js +3 -0
  56. data/webpack/__mocks__/foremanReact/common/helpers.js +2 -0
  57. data/webpack/__mocks__/foremanReact/components/ForemanModal/ForemanModalActions.js +2 -0
  58. data/webpack/__mocks__/foremanReact/components/ForemanModal.js +7 -0
  59. data/webpack/__mocks__/foremanReact/components/common/forms/CommonForm.js +2 -0
  60. data/webpack/__mocks__/foremanReact/components/common/forms/TextInput.js +2 -0
  61. data/webpack/__mocks__/foremanReact/components/hosts/powerStatus.js +1 -0
  62. data/webpack/__snapshots__/helper.test.js.snap +14 -0
  63. data/webpack/components/ApplicationDefinition/ApplicationDefinition.js +35 -11
  64. data/webpack/components/ApplicationDefinition/ApplicationDefinitionActions.js +12 -0
  65. data/webpack/components/ApplicationDefinition/ApplicationDefinitionConstants.js +1 -0
  66. data/webpack/components/ApplicationDefinition/ApplicationDefinitionReducer.js +30 -9
  67. data/webpack/components/ApplicationDefinition/ApplicationDefinitionSelectors.js +4 -0
  68. data/webpack/components/ApplicationDefinition/__fixtures__/applicationDefinitionConfData_1.fixtures.js +288 -0
  69. data/webpack/components/ApplicationDefinition/__fixtures__/applicationDefinitionReducer.fixtures.js +79 -0
  70. data/webpack/components/ApplicationDefinition/__tests__/ApplicationDefinition.test.js +26 -0
  71. data/webpack/components/ApplicationDefinition/__tests__/ApplicationDefinitionReducer.test.js +119 -0
  72. data/webpack/components/ApplicationDefinition/__tests__/ApplicationDefinitionSelectors.test.js +53 -0
  73. data/webpack/components/ApplicationDefinition/__tests__/__snapshots__/ApplicationDefinition.test.js.snap +226 -0
  74. data/webpack/components/ApplicationDefinition/__tests__/__snapshots__/ApplicationDefinitionReducer.test.js.snap +3033 -0
  75. data/webpack/components/ApplicationDefinition/__tests__/__snapshots__/ApplicationDefinitionSelectors.test.js.snap +307 -0
  76. data/webpack/components/ApplicationDefinition/components/AnsiblePlaybookSelector.js +2 -1
  77. data/webpack/components/ApplicationDefinition/components/__tests__/AnsiblePlaybookSelector.test.js +41 -0
  78. data/webpack/components/ApplicationDefinition/components/__tests__/__snapshots__/AnsiblePlaybookSelector.test.js.snap +121 -0
  79. data/webpack/components/ApplicationDefinition/index.js +8 -0
  80. data/webpack/components/ApplicationDefinitionImport/ApplicationDefinitionImport.js +214 -0
  81. data/webpack/components/ApplicationDefinitionImport/ApplicationDefinitionImport.scss +1 -0
  82. data/webpack/components/ApplicationDefinitionImport/ApplicationDefinitionImportActions.js +161 -0
  83. data/webpack/components/ApplicationDefinitionImport/ApplicationDefinitionImportConstants.js +6 -0
  84. data/webpack/components/ApplicationDefinitionImport/ApplicationDefinitionImportReducer.js +79 -0
  85. data/webpack/components/ApplicationDefinitionImport/ApplicationDefinitionImportSelectors.js +8 -0
  86. data/webpack/components/ApplicationDefinitionImport/__fixtures__/applicationDefinitionImportConfData_1.fixtures.js +129 -0
  87. data/webpack/components/ApplicationDefinitionImport/__fixtures__/applicationDefinitionImportReducer.fixtures.js +29 -0
  88. data/webpack/components/ApplicationDefinitionImport/__tests__/ApplicationDefinitionImport.test.js +20 -0
  89. data/webpack/components/ApplicationDefinitionImport/__tests__/ApplicationDefinitionImportReducer.test.js +43 -0
  90. data/webpack/components/ApplicationDefinitionImport/__tests__/ApplicationDefinitionImportSelectors.test.js +29 -0
  91. data/webpack/components/ApplicationDefinitionImport/__tests__/__snapshots__/ApplicationDefinitionImport.test.js.snap +62 -0
  92. data/webpack/components/ApplicationDefinitionImport/__tests__/__snapshots__/ApplicationDefinitionImportReducer.test.js.snap +362 -0
  93. data/webpack/components/ApplicationDefinitionImport/__tests__/__snapshots__/ApplicationDefinitionImportSelectors.test.js.snap +130 -0
  94. data/webpack/components/ApplicationDefinitionImport/index.js +32 -0
  95. data/webpack/components/ApplicationInstance/ApplicationInstance.js +105 -31
  96. data/webpack/components/ApplicationInstance/ApplicationInstanceActions.js +118 -6
  97. data/webpack/components/ApplicationInstance/ApplicationInstanceConstants.js +4 -0
  98. data/webpack/components/ApplicationInstance/ApplicationInstanceHelper.js +15 -0
  99. data/webpack/components/ApplicationInstance/ApplicationInstanceReducer.js +71 -30
  100. data/webpack/components/ApplicationInstance/ApplicationInstanceSelectors.js +4 -0
  101. data/webpack/components/ApplicationInstance/__fixtures__/applicationInstanceConfData_1.fixtures.js +263 -0
  102. data/webpack/components/ApplicationInstance/__fixtures__/applicationInstanceReducer.fixtures.js +80 -0
  103. data/webpack/components/ApplicationInstance/__tests__/ApplicationInstance.test.js +24 -0
  104. data/webpack/components/ApplicationInstance/__tests__/ApplicationInstanceReducer.test.js +131 -0
  105. data/webpack/components/ApplicationInstance/__tests__/ApplicationInstanceSelectors.test.js +56 -0
  106. data/webpack/components/ApplicationInstance/__tests__/__snapshots__/ApplicationInstance.test.js.snap +300 -0
  107. data/webpack/components/ApplicationInstance/__tests__/__snapshots__/ApplicationInstanceReducer.test.js.snap +2990 -0
  108. data/webpack/components/ApplicationInstance/__tests__/__snapshots__/ApplicationInstanceSelectors.test.js.snap +284 -0
  109. data/webpack/components/ApplicationInstance/components/AppDefinitionSelector.js +1 -0
  110. data/webpack/components/ApplicationInstance/components/ServiceCounter.js +1 -1
  111. data/webpack/components/ApplicationInstance/helper.js +0 -0
  112. data/webpack/components/ApplicationInstance/index.js +8 -0
  113. data/webpack/components/ApplicationInstanceReport/ApplicationInstanceReport.js +81 -6
  114. data/webpack/components/ApplicationInstanceReport/ApplicationInstanceReportActions.js +35 -1
  115. data/webpack/components/ApplicationInstanceReport/ApplicationInstanceReportConstants.js +3 -0
  116. data/webpack/components/ApplicationInstanceReport/ApplicationInstanceReportReducer.js +19 -0
  117. data/webpack/components/ApplicationInstanceReport/ApplicationInstanceReportSelectors.js +4 -0
  118. data/webpack/components/ApplicationInstanceReport/__fixtures__/applicationInstanceReportData_1.fixtures.js +349 -0
  119. data/webpack/components/ApplicationInstanceReport/__fixtures__/applicationInstanceReportReducer.fixtures.js +20 -0
  120. data/webpack/components/ApplicationInstanceReport/__tests__/ApplicationInstanceReport.test.js +47 -0
  121. data/webpack/components/ApplicationInstanceReport/__tests__/ApplicationInstanceReportReducer.test.js +41 -0
  122. data/webpack/components/ApplicationInstanceReport/__tests__/ApplicationInstanceReportSelectors.test.js +26 -0
  123. data/webpack/components/ApplicationInstanceReport/__tests__/__snapshots__/ApplicationInstanceReport.test.js.snap +7 -0
  124. data/webpack/components/ApplicationInstanceReport/__tests__/__snapshots__/ApplicationInstanceReportReducer.test.js.snap +718 -0
  125. data/webpack/components/ApplicationInstanceReport/__tests__/__snapshots__/ApplicationInstanceReportSelectors.test.js.snap +347 -0
  126. data/webpack/components/ApplicationInstanceReport/components/__tests__/ReportViewer.test.js +24 -0
  127. data/webpack/components/ApplicationInstanceReport/components/__tests__/__snapshots__/ReportViewer.test.js.snap +24 -0
  128. data/webpack/components/ApplicationInstanceReport/index.js +8 -1
  129. data/webpack/components/ExistingHostSelection/ExistingHostSelection.js +104 -0
  130. data/webpack/components/ExistingHostSelection/ExistingHostSelection.scss +15 -0
  131. data/webpack/components/ExistingHostSelection/ExistingHostSelectionActions.js +71 -0
  132. data/webpack/components/ExistingHostSelection/ExistingHostSelectionConstants.js +4 -0
  133. data/webpack/components/ExistingHostSelection/ExistingHostSelectionHelper.js +0 -0
  134. data/webpack/components/ExistingHostSelection/ExistingHostSelectionReducer.js +90 -0
  135. data/webpack/components/ExistingHostSelection/ExistingHostSelectionSelectors.js +8 -0
  136. data/webpack/components/ExistingHostSelection/__fixtures__/existingHostSelectionConfData_1.fixtures.js +191 -0
  137. data/webpack/components/ExistingHostSelection/__fixtures__/existingHostSelectionReducer.fixtures.js +203 -0
  138. data/webpack/components/ExistingHostSelection/__tests__/ExistingHostSelection.test.js +19 -0
  139. data/webpack/components/ExistingHostSelection/__tests__/ExistingHostSelectionReducer.test.js +59 -0
  140. data/webpack/components/ExistingHostSelection/__tests__/ExistingHostSelectionSelectors.test.js +36 -0
  141. data/webpack/components/ExistingHostSelection/__tests__/__snapshots__/ExistingHostSelection.test.js.snap +35 -0
  142. data/webpack/components/ExistingHostSelection/__tests__/__snapshots__/ExistingHostSelectionReducer.test.js.snap +614 -0
  143. data/webpack/components/ExistingHostSelection/__tests__/__snapshots__/ExistingHostSelectionSelectors.test.js.snap +27 -0
  144. data/webpack/components/ExistingHostSelection/components/ServiceSelector.js +48 -0
  145. data/webpack/components/ExistingHostSelection/components/__tests__/ServiceSelector.test.js +35 -0
  146. data/webpack/components/ExistingHostSelection/components/__tests__/__snapshots__/ServiceSelector.test.js.snap +77 -0
  147. data/webpack/components/ExistingHostSelection/index.js +26 -0
  148. data/webpack/components/ParameterSelection/ParameterSelection.js +103 -1
  149. data/webpack/components/ParameterSelection/ParameterSelection.scss +7 -0
  150. data/webpack/components/ParameterSelection/ParameterSelectionActions.js +46 -4
  151. data/webpack/components/ParameterSelection/ParameterSelectionConstants.js +2 -0
  152. data/webpack/components/ParameterSelection/ParameterSelectionHelper.js +5 -1
  153. data/webpack/components/ParameterSelection/ParameterSelectionReducer.js +51 -29
  154. data/webpack/components/ParameterSelection/ParameterSelectionSelectors.js +2 -0
  155. data/webpack/components/ParameterSelection/__fixtures__/parameterSelectionData_1.fixtures.js +124 -84
  156. data/webpack/components/ParameterSelection/__fixtures__/parameterSelectionReducer.fixtures.js +10 -4
  157. data/webpack/components/ParameterSelection/__tests__/ParameterSelection.test.js +36 -46
  158. data/webpack/components/ParameterSelection/__tests__/ParameterSelectionReducer.test.js +33 -25
  159. data/webpack/components/ParameterSelection/__tests__/ParameterSelectionSelectors.test.js +12 -6
  160. data/webpack/components/ParameterSelection/__tests__/__snapshots__/ParameterSelection.test.js.snap +84 -112
  161. data/webpack/components/ParameterSelection/__tests__/__snapshots__/ParameterSelectionReducer.test.js.snap +1589 -878
  162. data/webpack/components/ParameterSelection/__tests__/__snapshots__/ParameterSelectionSelectors.test.js.snap +130 -79
  163. data/webpack/components/ParameterSelection/index.js +4 -1
  164. data/webpack/components/SyncGitRepo/SyncGitRepo.js +202 -0
  165. data/webpack/components/SyncGitRepo/SyncGitRepo.scss +1 -0
  166. data/webpack/components/SyncGitRepo/SyncGitRepoActions.js +123 -0
  167. data/webpack/components/SyncGitRepo/SyncGitRepoConstants.js +8 -0
  168. data/webpack/components/SyncGitRepo/SyncGitRepoReducer.js +80 -0
  169. data/webpack/components/SyncGitRepo/SyncGitRepoSelectors.js +6 -0
  170. data/webpack/components/SyncGitRepo/__fixtures__/syncGitRepoConfData_1.fixtures.js +7 -0
  171. data/webpack/components/SyncGitRepo/__fixtures__/syncGitRepoReducer.fixtures.js +44 -0
  172. data/webpack/components/SyncGitRepo/__tests__/SyncGitRepo.test.js +27 -0
  173. data/webpack/components/SyncGitRepo/__tests__/SyncGitRepoReducer.test.js +95 -0
  174. data/webpack/components/SyncGitRepo/__tests__/SyncGitRepoSelectors.test.js +32 -0
  175. data/webpack/components/SyncGitRepo/__tests__/__snapshots__/SyncGitRepo.test.js.snap +31 -0
  176. data/webpack/components/SyncGitRepo/__tests__/__snapshots__/SyncGitRepoReducer.test.js.snap +137 -0
  177. data/webpack/components/SyncGitRepo/__tests__/__snapshots__/SyncGitRepoSelectors.test.js.snap +13 -0
  178. data/webpack/components/SyncGitRepo/components/FormTextInput.js +42 -0
  179. data/webpack/components/SyncGitRepo/components/ScmTypeSelector.js +47 -0
  180. data/webpack/components/SyncGitRepo/index.js +28 -0
  181. data/webpack/components/common/DeleteTableEntry.js +16 -2
  182. data/webpack/components/common/ExtTextInput.js +43 -0
  183. data/webpack/components/common/__tests__/EditTableEntry.test.js +53 -0
  184. data/webpack/components/common/__tests__/LockTableEntry.test.js +35 -0
  185. data/webpack/components/common/__tests__/__snapshots__/DeleteTableEntry.test.js.snap +40 -2
  186. data/webpack/components/common/__tests__/__snapshots__/EditTableEntry.test.js.snap +81 -0
  187. data/webpack/components/common/__tests__/__snapshots__/LockTableEntry.test.js.snap +60 -0
  188. data/webpack/helper.js +35 -1
  189. data/webpack/helper.test.js +56 -0
  190. data/webpack/index.js +7 -0
  191. data/webpack/js-yaml.js +3874 -0
  192. data/webpack/reducer.js +16 -1
  193. data/webpack/test_setup.js +0 -2
  194. metadata +136 -11
  195. data/webpack/components/common/EasyHeaderFormatter.js +0 -18
  196. data/webpack/components/common/__tests__/__snapshots__/AddParameter.test.js.snap +0 -35
  197. data/webpack/components/common/__tests__/__snapshots__/DeleteParameter.test.js.snap +0 -41
data/webpack/reducer.js CHANGED
@@ -2,8 +2,11 @@ import { combineReducers } from 'redux';
2
2
 
3
3
  import parameterSelectionParameters from './components/ParameterSelection/ParameterSelectionReducer';
4
4
  import applicationDefinitionConf from './components/ApplicationDefinition/ApplicationDefinitionReducer';
5
+ import applicationDefinitionImportConf from './components/ApplicationDefinitionImport/ApplicationDefinitionImportReducer';
5
6
  import applicationInstanceConf from './components/ApplicationInstance/ApplicationInstanceReducer';
6
7
  import applicationInstanceReport from './components/ApplicationInstanceReport/ApplicationInstanceReportReducer';
8
+ import existingHostSelectionConf from './components/ExistingHostSelection/ExistingHostSelectionReducer';
9
+ import syncGitRepoConf from './components/SyncGitRepo/SyncGitRepoReducer';
7
10
 
8
11
  import {
9
12
  APPLICATION_DEFINITION_FOREMAN_PARAMETER_SELECTION_MODAL_CLOSE,
@@ -13,6 +16,7 @@ import {
13
16
  import {
14
17
  APPLICATION_INSTANCE_FOREMAN_PARAMETER_SELECTION_MODAL_CLOSE,
15
18
  APPLICATION_INSTANCE_ANSIBLE_PARAMETER_SELECTION_MODAL_CLOSE,
19
+ APPLICATION_INSTANCE_ADD_EXISTING_HOSTS_MODAL_CLOSE,
16
20
  } from './components/ApplicationInstance/ApplicationInstanceConstants';
17
21
 
18
22
  const rootReducer = (state = {}, action) => {
@@ -27,6 +31,7 @@ const rootReducer = (state = {}, action) => {
27
31
  action.payload.parameterSelection = param_state.parameters;
28
32
  }
29
33
  const app_def_state = applicationDefinitionConf(state.applicationDefinitionConf, action);
34
+ const app_def_import_state = applicationDefinitionImportConf(state.applicationDefinitionImportConf, action);
30
35
 
31
36
  if (action.type == APPLICATION_INSTANCE_FOREMAN_PARAMETER_SELECTION_MODAL_CLOSE) {
32
37
  action.payload.parameterSelection = param_state.parameters;
@@ -34,13 +39,23 @@ const rootReducer = (state = {}, action) => {
34
39
  if (action.type == APPLICATION_INSTANCE_ANSIBLE_PARAMETER_SELECTION_MODAL_CLOSE) {
35
40
  action.payload.parameterSelection = param_state.parameters;
36
41
  }
42
+
43
+ const ex_host_state = existingHostSelectionConf(state.existingHostSelectionConf, action);
44
+ if (action.type == APPLICATION_INSTANCE_ADD_EXISTING_HOSTS_MODAL_CLOSE) {
45
+ action.payload.selectedHosts = ex_host_state.selectedHosts;
46
+ }
47
+
37
48
  const app_ins_state = applicationInstanceConf(state.applicationInstanceConf, action);
49
+ const sync_git_repo_state = syncGitRepoConf(state.syncGitRepoConf, action);
38
50
 
39
51
  return {
40
52
  applicationDefinitionConf: app_def_state,
53
+ applicationDefinitionImportConf: app_def_import_state,
41
54
  applicationInstanceConf: app_ins_state,
42
- parameterSelectionParameters: param_state,
43
55
  applicationInstanceReport: app_ins_report_state,
56
+ existingHostSelectionConf: ex_host_state,
57
+ parameterSelectionParameters: param_state,
58
+ syncGitRepoConf: sync_git_repo_state,
44
59
  };
45
60
  };
46
61
 
@@ -1,5 +1,3 @@
1
- import 'babel-polyfill';
2
-
3
1
  import { configure } from 'enzyme';
4
2
  import Adapter from 'enzyme-adapter-react-16';
5
3
 
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.6.0
4
+ version: 0.9.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - ATIX AG
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-03-09 00:00:00.000000000 Z
11
+ date: 2022-04-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rubocop
@@ -16,28 +16,28 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: 0.87.0
19
+ version: 0.89.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.87.0
26
+ version: 0.89.0
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rubocop-rails
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: 2.7.1
33
+ version: 2.8.1
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: 2.7.1
40
+ version: 2.8.1
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: foreman_remote_execution
43
43
  requirement: !ruby/object:Gem::Requirement
@@ -66,6 +66,20 @@ dependencies:
66
66
  - - ">="
67
67
  - !ruby/object:Gem::Version
68
68
  version: '0.10'
69
+ - !ruby/object:Gem::Dependency
70
+ name: git
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - ">="
74
+ - !ruby/object:Gem::Version
75
+ version: '0'
76
+ type: :runtime
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - ">="
81
+ - !ruby/object:Gem::Version
82
+ version: '0'
69
83
  description: Foreman plugin to provide application centric deployment and self service
70
84
  portal
71
85
  email:
@@ -88,6 +102,7 @@ files:
88
102
  - app/controllers/foreman_acd/application_controller.rb
89
103
  - app/controllers/foreman_acd/concerns/ansible_playbook_parameters.rb
90
104
  - app/controllers/foreman_acd/concerns/app_definition_parameters.rb
105
+ - app/controllers/foreman_acd/concerns/app_instance_mixins.rb
91
106
  - app/controllers/foreman_acd/concerns/app_instance_parameters.rb
92
107
  - app/controllers/foreman_acd/remote_execution_controller.rb
93
108
  - app/controllers/ui_acd_controller.rb
@@ -100,6 +115,7 @@ files:
100
115
  - app/models/foreman_acd/app_instance.rb
101
116
  - app/models/foreman_acd/foreman_host.rb
102
117
  - app/models/foreman_acd/taxonomy_extensions.rb
118
+ - app/services/foreman_acd/acd_proxy_proxy_selector.rb
103
119
  - app/services/foreman_acd/app_configurator.rb
104
120
  - app/services/foreman_acd/app_deployer.rb
105
121
  - app/services/foreman_acd/inventory_creator.rb
@@ -134,8 +150,11 @@ files:
134
150
  - app/views/ui_acd/domain.json.rabl
135
151
  - app/views/ui_acd/environment.json.rabl
136
152
  - app/views/ui_acd/foreman_data.json.rabl
153
+ - app/views/ui_acd/host_report.json.rabl
137
154
  - app/views/ui_acd/lifecycle_environment.json.rabl
138
155
  - app/views/ui_acd/ptable.json.rabl
156
+ - app/views/ui_acd/report_data.json.rabl
157
+ - app/views/ui_acd/validate_hostname.json.rabl
139
158
  - config/routes.rb
140
159
  - db/migrate/20190610202252_create_app_definitions.rb
141
160
  - db/migrate/20190625140305_create_app_instances.rb
@@ -150,6 +169,10 @@ files:
150
169
  - db/migrate/20210209091014_rename_acd_tables.rb
151
170
  - db/migrate/20210216083522_add_last_progress_report.rb
152
171
  - db/migrate/20210216091529_add_last_deploy_task.rb
172
+ - db/migrate/20210316151145_add_git_commit_to_ansible_playbooks.rb
173
+ - db/migrate/20210503122809_add_git_url_to_ansible_playbooks.rb
174
+ - db/migrate/20210818125913_add_is_existing_host_to_foreman_host.rb
175
+ - db/migrate/20210902110645_add_initial_configure_task.rb
153
176
  - db/seeds.d/62_acd_proxy_feature.rb
154
177
  - db/seeds.d/75-job_templates.rb
155
178
  - lib/foreman_acd.rb
@@ -169,10 +192,23 @@ files:
169
192
  - test/controllers/app_instances_controller_test.rb
170
193
  - test/controllers/ui_acd_controller_test.rb
171
194
  - test/factories/foreman_acd_factories.rb
195
+ - test/models/acd_provider_test.rb
196
+ - test/models/ansible_playbook_test.rb
172
197
  - test/models/app_definition_test.rb
173
198
  - test/models/app_instance_test.rb
199
+ - test/models/concerns/host_extensions_test.rb
200
+ - test/models/foreman_host_test.rb
174
201
  - test/test_plugin_helper.rb
202
+ - webpack/__mocks__/foremanReact/API.js
203
+ - webpack/__mocks__/foremanReact/common/I18n.js
204
+ - webpack/__mocks__/foremanReact/common/helpers.js
205
+ - webpack/__mocks__/foremanReact/components/ForemanModal.js
206
+ - webpack/__mocks__/foremanReact/components/ForemanModal/ForemanModalActions.js
207
+ - webpack/__mocks__/foremanReact/components/common/forms/CommonForm.js
175
208
  - webpack/__mocks__/foremanReact/components/common/forms/Select.js
209
+ - webpack/__mocks__/foremanReact/components/common/forms/TextInput.js
210
+ - webpack/__mocks__/foremanReact/components/hosts/powerStatus.js
211
+ - webpack/__snapshots__/helper.test.js.snap
176
212
  - webpack/components/ApplicationDefinition/ApplicationDefinition.js
177
213
  - webpack/components/ApplicationDefinition/ApplicationDefinition.scss
178
214
  - webpack/components/ApplicationDefinition/ApplicationDefinitionActions.js
@@ -180,17 +216,52 @@ files:
180
216
  - webpack/components/ApplicationDefinition/ApplicationDefinitionHelper.js
181
217
  - webpack/components/ApplicationDefinition/ApplicationDefinitionReducer.js
182
218
  - webpack/components/ApplicationDefinition/ApplicationDefinitionSelectors.js
219
+ - webpack/components/ApplicationDefinition/__fixtures__/applicationDefinitionConfData_1.fixtures.js
220
+ - webpack/components/ApplicationDefinition/__fixtures__/applicationDefinitionReducer.fixtures.js
221
+ - webpack/components/ApplicationDefinition/__tests__/ApplicationDefinition.test.js
222
+ - webpack/components/ApplicationDefinition/__tests__/ApplicationDefinitionReducer.test.js
223
+ - webpack/components/ApplicationDefinition/__tests__/ApplicationDefinitionSelectors.test.js
224
+ - webpack/components/ApplicationDefinition/__tests__/__snapshots__/ApplicationDefinition.test.js.snap
225
+ - webpack/components/ApplicationDefinition/__tests__/__snapshots__/ApplicationDefinitionReducer.test.js.snap
226
+ - webpack/components/ApplicationDefinition/__tests__/__snapshots__/ApplicationDefinitionSelectors.test.js.snap
183
227
  - webpack/components/ApplicationDefinition/components/AnsiblePlaybookSelector.js
228
+ - webpack/components/ApplicationDefinition/components/__tests__/AnsiblePlaybookSelector.test.js
229
+ - webpack/components/ApplicationDefinition/components/__tests__/__snapshots__/AnsiblePlaybookSelector.test.js.snap
184
230
  - webpack/components/ApplicationDefinition/index.js
231
+ - webpack/components/ApplicationDefinitionImport/ApplicationDefinitionImport.js
232
+ - webpack/components/ApplicationDefinitionImport/ApplicationDefinitionImport.scss
233
+ - webpack/components/ApplicationDefinitionImport/ApplicationDefinitionImportActions.js
234
+ - webpack/components/ApplicationDefinitionImport/ApplicationDefinitionImportConstants.js
235
+ - webpack/components/ApplicationDefinitionImport/ApplicationDefinitionImportReducer.js
236
+ - webpack/components/ApplicationDefinitionImport/ApplicationDefinitionImportSelectors.js
237
+ - webpack/components/ApplicationDefinitionImport/__fixtures__/applicationDefinitionImportConfData_1.fixtures.js
238
+ - webpack/components/ApplicationDefinitionImport/__fixtures__/applicationDefinitionImportReducer.fixtures.js
239
+ - webpack/components/ApplicationDefinitionImport/__tests__/ApplicationDefinitionImport.test.js
240
+ - webpack/components/ApplicationDefinitionImport/__tests__/ApplicationDefinitionImportReducer.test.js
241
+ - webpack/components/ApplicationDefinitionImport/__tests__/ApplicationDefinitionImportSelectors.test.js
242
+ - webpack/components/ApplicationDefinitionImport/__tests__/__snapshots__/ApplicationDefinitionImport.test.js.snap
243
+ - webpack/components/ApplicationDefinitionImport/__tests__/__snapshots__/ApplicationDefinitionImportReducer.test.js.snap
244
+ - webpack/components/ApplicationDefinitionImport/__tests__/__snapshots__/ApplicationDefinitionImportSelectors.test.js.snap
245
+ - webpack/components/ApplicationDefinitionImport/index.js
185
246
  - webpack/components/ApplicationInstance/ApplicationInstance.js
186
247
  - webpack/components/ApplicationInstance/ApplicationInstance.scss
187
248
  - webpack/components/ApplicationInstance/ApplicationInstanceActions.js
188
249
  - webpack/components/ApplicationInstance/ApplicationInstanceConstants.js
250
+ - webpack/components/ApplicationInstance/ApplicationInstanceHelper.js
189
251
  - webpack/components/ApplicationInstance/ApplicationInstanceReducer.js
190
252
  - webpack/components/ApplicationInstance/ApplicationInstanceSelectors.js
253
+ - webpack/components/ApplicationInstance/__fixtures__/applicationInstanceConfData_1.fixtures.js
254
+ - webpack/components/ApplicationInstance/__fixtures__/applicationInstanceReducer.fixtures.js
255
+ - webpack/components/ApplicationInstance/__tests__/ApplicationInstance.test.js
256
+ - webpack/components/ApplicationInstance/__tests__/ApplicationInstanceReducer.test.js
257
+ - webpack/components/ApplicationInstance/__tests__/ApplicationInstanceSelectors.test.js
258
+ - webpack/components/ApplicationInstance/__tests__/__snapshots__/ApplicationInstance.test.js.snap
259
+ - webpack/components/ApplicationInstance/__tests__/__snapshots__/ApplicationInstanceReducer.test.js.snap
260
+ - webpack/components/ApplicationInstance/__tests__/__snapshots__/ApplicationInstanceSelectors.test.js.snap
191
261
  - webpack/components/ApplicationInstance/components/AppDefinitionSelector.js
192
262
  - webpack/components/ApplicationInstance/components/Service.js
193
263
  - webpack/components/ApplicationInstance/components/ServiceCounter.js
264
+ - webpack/components/ApplicationInstance/helper.js
194
265
  - webpack/components/ApplicationInstance/index.js
195
266
  - webpack/components/ApplicationInstanceReport/ApplicationInstanceReport.js
196
267
  - webpack/components/ApplicationInstanceReport/ApplicationInstanceReport.scss
@@ -198,8 +269,37 @@ files:
198
269
  - webpack/components/ApplicationInstanceReport/ApplicationInstanceReportConstants.js
199
270
  - webpack/components/ApplicationInstanceReport/ApplicationInstanceReportReducer.js
200
271
  - webpack/components/ApplicationInstanceReport/ApplicationInstanceReportSelectors.js
272
+ - webpack/components/ApplicationInstanceReport/__fixtures__/applicationInstanceReportData_1.fixtures.js
273
+ - webpack/components/ApplicationInstanceReport/__fixtures__/applicationInstanceReportReducer.fixtures.js
274
+ - webpack/components/ApplicationInstanceReport/__tests__/ApplicationInstanceReport.test.js
275
+ - webpack/components/ApplicationInstanceReport/__tests__/ApplicationInstanceReportReducer.test.js
276
+ - webpack/components/ApplicationInstanceReport/__tests__/ApplicationInstanceReportSelectors.test.js
277
+ - webpack/components/ApplicationInstanceReport/__tests__/__snapshots__/ApplicationInstanceReport.test.js.snap
278
+ - webpack/components/ApplicationInstanceReport/__tests__/__snapshots__/ApplicationInstanceReportReducer.test.js.snap
279
+ - webpack/components/ApplicationInstanceReport/__tests__/__snapshots__/ApplicationInstanceReportSelectors.test.js.snap
201
280
  - webpack/components/ApplicationInstanceReport/components/ReportViewer.js
281
+ - webpack/components/ApplicationInstanceReport/components/__tests__/ReportViewer.test.js
282
+ - webpack/components/ApplicationInstanceReport/components/__tests__/__snapshots__/ReportViewer.test.js.snap
202
283
  - webpack/components/ApplicationInstanceReport/index.js
284
+ - webpack/components/ExistingHostSelection/ExistingHostSelection.js
285
+ - webpack/components/ExistingHostSelection/ExistingHostSelection.scss
286
+ - webpack/components/ExistingHostSelection/ExistingHostSelectionActions.js
287
+ - webpack/components/ExistingHostSelection/ExistingHostSelectionConstants.js
288
+ - webpack/components/ExistingHostSelection/ExistingHostSelectionHelper.js
289
+ - webpack/components/ExistingHostSelection/ExistingHostSelectionReducer.js
290
+ - webpack/components/ExistingHostSelection/ExistingHostSelectionSelectors.js
291
+ - webpack/components/ExistingHostSelection/__fixtures__/existingHostSelectionConfData_1.fixtures.js
292
+ - webpack/components/ExistingHostSelection/__fixtures__/existingHostSelectionReducer.fixtures.js
293
+ - webpack/components/ExistingHostSelection/__tests__/ExistingHostSelection.test.js
294
+ - webpack/components/ExistingHostSelection/__tests__/ExistingHostSelectionReducer.test.js
295
+ - webpack/components/ExistingHostSelection/__tests__/ExistingHostSelectionSelectors.test.js
296
+ - webpack/components/ExistingHostSelection/__tests__/__snapshots__/ExistingHostSelection.test.js.snap
297
+ - webpack/components/ExistingHostSelection/__tests__/__snapshots__/ExistingHostSelectionReducer.test.js.snap
298
+ - webpack/components/ExistingHostSelection/__tests__/__snapshots__/ExistingHostSelectionSelectors.test.js.snap
299
+ - webpack/components/ExistingHostSelection/components/ServiceSelector.js
300
+ - webpack/components/ExistingHostSelection/components/__tests__/ServiceSelector.test.js
301
+ - webpack/components/ExistingHostSelection/components/__tests__/__snapshots__/ServiceSelector.test.js.snap
302
+ - webpack/components/ExistingHostSelection/index.js
203
303
  - webpack/components/ParameterSelection/ParameterSelection.js
204
304
  - webpack/components/ParameterSelection/ParameterSelection.scss
205
305
  - webpack/components/ParameterSelection/ParameterSelectionActions.js
@@ -217,25 +317,46 @@ files:
217
317
  - webpack/components/ParameterSelection/__tests__/__snapshots__/ParameterSelectionReducer.test.js.snap
218
318
  - webpack/components/ParameterSelection/__tests__/__snapshots__/ParameterSelectionSelectors.test.js.snap
219
319
  - webpack/components/ParameterSelection/index.js
320
+ - webpack/components/SyncGitRepo/SyncGitRepo.js
321
+ - webpack/components/SyncGitRepo/SyncGitRepo.scss
322
+ - webpack/components/SyncGitRepo/SyncGitRepoActions.js
323
+ - webpack/components/SyncGitRepo/SyncGitRepoConstants.js
324
+ - webpack/components/SyncGitRepo/SyncGitRepoReducer.js
325
+ - webpack/components/SyncGitRepo/SyncGitRepoSelectors.js
326
+ - webpack/components/SyncGitRepo/__fixtures__/syncGitRepoConfData_1.fixtures.js
327
+ - webpack/components/SyncGitRepo/__fixtures__/syncGitRepoReducer.fixtures.js
328
+ - webpack/components/SyncGitRepo/__tests__/SyncGitRepo.test.js
329
+ - webpack/components/SyncGitRepo/__tests__/SyncGitRepoReducer.test.js
330
+ - webpack/components/SyncGitRepo/__tests__/SyncGitRepoSelectors.test.js
331
+ - webpack/components/SyncGitRepo/__tests__/__snapshots__/SyncGitRepo.test.js.snap
332
+ - webpack/components/SyncGitRepo/__tests__/__snapshots__/SyncGitRepoReducer.test.js.snap
333
+ - webpack/components/SyncGitRepo/__tests__/__snapshots__/SyncGitRepoSelectors.test.js.snap
334
+ - webpack/components/SyncGitRepo/components/FormTextInput.js
335
+ - webpack/components/SyncGitRepo/components/ScmTypeSelector.js
336
+ - webpack/components/SyncGitRepo/index.js
220
337
  - webpack/components/common/AddTableEntry.js
221
338
  - webpack/components/common/DeleteTableEntry.js
222
- - webpack/components/common/EasyHeaderFormatter.js
223
339
  - webpack/components/common/EditTableEntry.js
224
340
  - webpack/components/common/ExtSelect.js
341
+ - webpack/components/common/ExtTextInput.js
225
342
  - webpack/components/common/LockTableEntry.js
226
343
  - webpack/components/common/RailsData.js
227
344
  - webpack/components/common/__tests__/AddTableEntry.test.js
228
345
  - webpack/components/common/__tests__/DeleteTableEntry.test.js
346
+ - webpack/components/common/__tests__/EditTableEntry.test.js
229
347
  - webpack/components/common/__tests__/ExtSelect.test.js
348
+ - webpack/components/common/__tests__/LockTableEntry.test.js
230
349
  - webpack/components/common/__tests__/RailsData.test.js
231
- - webpack/components/common/__tests__/__snapshots__/AddParameter.test.js.snap
232
350
  - webpack/components/common/__tests__/__snapshots__/AddTableEntry.test.js.snap
233
- - webpack/components/common/__tests__/__snapshots__/DeleteParameter.test.js.snap
234
351
  - webpack/components/common/__tests__/__snapshots__/DeleteTableEntry.test.js.snap
352
+ - webpack/components/common/__tests__/__snapshots__/EditTableEntry.test.js.snap
235
353
  - webpack/components/common/__tests__/__snapshots__/ExtSelect.test.js.snap
354
+ - webpack/components/common/__tests__/__snapshots__/LockTableEntry.test.js.snap
236
355
  - webpack/components/common/__tests__/__snapshots__/RailsData.test.js.snap
237
356
  - webpack/helper.js
357
+ - webpack/helper.test.js
238
358
  - webpack/index.js
359
+ - webpack/js-yaml.js
239
360
  - webpack/reducer.js
240
361
  - webpack/test_setup.js
241
362
  homepage: https://www.orcharhino.com
@@ -248,9 +369,9 @@ require_paths:
248
369
  - lib
249
370
  required_ruby_version: !ruby/object:Gem::Requirement
250
371
  requirements:
251
- - - ">="
372
+ - - "~>"
252
373
  - !ruby/object:Gem::Version
253
- version: '0'
374
+ version: '2.5'
254
375
  required_rubygems_version: !ruby/object:Gem::Requirement
255
376
  requirements:
256
377
  - - ">="
@@ -266,8 +387,12 @@ summary: Foreman plugin to provide application centric deployment and self servi
266
387
  test_files:
267
388
  - test/factories/foreman_acd_factories.rb
268
389
  - test/test_plugin_helper.rb
390
+ - test/models/ansible_playbook_test.rb
269
391
  - test/models/app_instance_test.rb
392
+ - test/models/concerns/host_extensions_test.rb
270
393
  - test/models/app_definition_test.rb
394
+ - test/models/acd_provider_test.rb
395
+ - test/models/foreman_host_test.rb
271
396
  - test/controllers/ui_acd_controller_test.rb
272
397
  - test/controllers/app_definitions_controller_test.rb
273
398
  - test/controllers/app_instances_controller_test.rb
@@ -1,18 +0,0 @@
1
- import React from 'react';
2
- import PropTypes from 'prop-types';
3
- import {
4
- Table,
5
- } from 'patternfly-react';
6
-
7
- const EasyHeaderFormatter = (value, { column }) => (
8
- <Table.Heading aria-label={column.header.label} {...column.header.props}>
9
- {value}
10
- </Table.Heading>
11
- );
12
-
13
- EasyHeaderFormatter.propTypes = {
14
- value: PropTypes.string.isRequired,
15
- column: PropTypes.object.isRequired,
16
- };
17
-
18
- export default EasyHeaderFormatter;
@@ -1,35 +0,0 @@
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`] = `""`;
@@ -1,41 +0,0 @@
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`] = `""`;