katello 4.11.1 → 4.12.0.rc2

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of katello might be problematic. Click here for more details.

Files changed (311) hide show
  1. checksums.yaml +4 -4
  2. data/app/assets/javascripts/katello/common/katello.global.js +1 -1
  3. data/app/assets/javascripts/katello/locale/bn/katello.js +76 -85
  4. data/app/assets/javascripts/katello/locale/bn_IN/katello.js +76 -85
  5. data/app/assets/javascripts/katello/locale/ca/katello.js +80 -86
  6. data/app/assets/javascripts/katello/locale/cs/katello.js +79 -85
  7. data/app/assets/javascripts/katello/locale/cs_CZ/katello.js +91 -88
  8. data/app/assets/javascripts/katello/locale/de/katello.js +97 -94
  9. data/app/assets/javascripts/katello/locale/de_AT/katello.js +76 -85
  10. data/app/assets/javascripts/katello/locale/de_DE/katello.js +76 -85
  11. data/app/assets/javascripts/katello/locale/el/katello.js +86 -86
  12. data/app/assets/javascripts/katello/locale/en/katello.js +76 -85
  13. data/app/assets/javascripts/katello/locale/en_GB/katello.js +88 -85
  14. data/app/assets/javascripts/katello/locale/en_US/katello.js +76 -85
  15. data/app/assets/javascripts/katello/locale/es/katello.js +94 -94
  16. data/app/assets/javascripts/katello/locale/et_EE/katello.js +76 -85
  17. data/app/assets/javascripts/katello/locale/fr/katello.js +97 -94
  18. data/app/assets/javascripts/katello/locale/gl/katello.js +80 -86
  19. data/app/assets/javascripts/katello/locale/gu/katello.js +76 -85
  20. data/app/assets/javascripts/katello/locale/he_IL/katello.js +76 -85
  21. data/app/assets/javascripts/katello/locale/hi/katello.js +76 -85
  22. data/app/assets/javascripts/katello/locale/id/katello.js +76 -85
  23. data/app/assets/javascripts/katello/locale/it/katello.js +89 -86
  24. data/app/assets/javascripts/katello/locale/ja/katello.js +97 -94
  25. data/app/assets/javascripts/katello/locale/ka/katello.js +92 -92
  26. data/app/assets/javascripts/katello/locale/kn/katello.js +76 -85
  27. data/app/assets/javascripts/katello/locale/ko/katello.js +91 -94
  28. data/app/assets/javascripts/katello/locale/locale/katello.js +1051 -1048
  29. data/app/assets/javascripts/katello/locale/ml_IN/katello.js +76 -85
  30. data/app/assets/javascripts/katello/locale/mr/katello.js +76 -85
  31. data/app/assets/javascripts/katello/locale/nl_NL/katello.js +76 -85
  32. data/app/assets/javascripts/katello/locale/or/katello.js +76 -85
  33. data/app/assets/javascripts/katello/locale/pa/katello.js +76 -85
  34. data/app/assets/javascripts/katello/locale/pl/katello.js +76 -85
  35. data/app/assets/javascripts/katello/locale/pl_PL/katello.js +76 -85
  36. data/app/assets/javascripts/katello/locale/pt/katello.js +76 -85
  37. data/app/assets/javascripts/katello/locale/pt_BR/katello.js +94 -94
  38. data/app/assets/javascripts/katello/locale/ro/katello.js +76 -85
  39. data/app/assets/javascripts/katello/locale/ro_RO/katello.js +76 -85
  40. data/app/assets/javascripts/katello/locale/ru/katello.js +91 -94
  41. data/app/assets/javascripts/katello/locale/sl/katello.js +76 -85
  42. data/app/assets/javascripts/katello/locale/sv_SE/katello.js +80 -86
  43. data/app/assets/javascripts/katello/locale/ta/katello.js +76 -85
  44. data/app/assets/javascripts/katello/locale/ta_IN/katello.js +76 -85
  45. data/app/assets/javascripts/katello/locale/te/katello.js +76 -85
  46. data/app/assets/javascripts/katello/locale/tr/katello.js +76 -85
  47. data/app/assets/javascripts/katello/locale/vi/katello.js +76 -85
  48. data/app/assets/javascripts/katello/locale/vi_VN/katello.js +76 -85
  49. data/app/assets/javascripts/katello/locale/zh/katello.js +76 -85
  50. data/app/assets/javascripts/katello/locale/zh_CN/katello.js +97 -94
  51. data/app/assets/javascripts/katello/locale/zh_TW/katello.js +91 -94
  52. data/app/assets/javascripts/katello/sync_management/index.js +0 -1
  53. data/app/assets/javascripts/katello/sync_management/sync_management.js +365 -308
  54. data/app/controllers/katello/api/rhsm/candlepin_proxies_controller.rb +1 -0
  55. data/app/controllers/katello/api/v2/content_views_controller.rb +1 -1
  56. data/app/controllers/katello/api/v2/debs_controller.rb +4 -0
  57. data/app/controllers/katello/api/v2/host_debs_controller.rb +13 -1
  58. data/app/controllers/katello/api/v2/host_subscriptions_controller.rb +13 -0
  59. data/app/controllers/katello/api/v2/organizations_controller.rb +1 -3
  60. data/app/controllers/katello/api/v2/repositories_controller.rb +2 -8
  61. data/app/controllers/katello/concerns/api/v2/registration_commands_controller_extensions.rb +0 -1
  62. data/app/controllers/katello/concerns/hosts_controller_extensions.rb +7 -3
  63. data/app/controllers/katello/concerns/organizations_controller_extensions.rb +1 -17
  64. data/app/helpers/katello/concerns/dashboard_helper_extensions.rb +0 -20
  65. data/app/lib/actions/katello/capsule_content/sync.rb +1 -1
  66. data/app/lib/actions/katello/content_view/promote.rb +1 -1
  67. data/app/lib/actions/katello/content_view/publish.rb +4 -4
  68. data/app/lib/actions/katello/content_view_version/auto_create_products.rb +4 -4
  69. data/app/lib/actions/katello/content_view_version/auto_create_redhat_repositories.rb +5 -5
  70. data/app/lib/actions/katello/content_view_version/auto_create_repositories.rb +5 -5
  71. data/app/lib/actions/katello/content_view_version/import.rb +14 -13
  72. data/app/lib/actions/katello/content_view_version/import_library.rb +4 -4
  73. data/app/lib/actions/katello/content_view_version/import_repository.rb +3 -3
  74. data/app/lib/actions/katello/content_view_version/reset_content_view_repositories_from_metadata.rb +2 -2
  75. data/app/lib/actions/katello/host/hypervisors_update.rb +0 -1
  76. data/app/lib/actions/katello/organization/manifest_delete.rb +1 -1
  77. data/app/lib/actions/katello/organization/manifest_refresh.rb +16 -16
  78. data/app/lib/actions/katello/repository/sync.rb +3 -5
  79. data/app/lib/actions/pulp3/orchestration/content_view_version/export.rb +20 -15
  80. data/app/lib/actions/pulp3/orchestration/content_view_version/export_library.rb +17 -14
  81. data/app/lib/actions/pulp3/orchestration/content_view_version/import.rb +11 -11
  82. data/app/lib/actions/pulp3/orchestration/repository/upload_content.rb +18 -13
  83. data/app/lib/actions/pulp3/repository/import_upload.rb +13 -5
  84. data/app/lib/actions/pulp3/repository/save_artifact.rb +23 -12
  85. data/app/lib/katello/api/v2/error_handling.rb +1 -1
  86. data/app/lib/katello/lazy_accessor.rb +6 -6
  87. data/app/lib/katello/resources/candlepin/owner.rb +2 -2
  88. data/app/mailers/katello/errata_mailer.rb +3 -3
  89. data/app/models/katello/concerns/host_managed_extensions.rb +74 -94
  90. data/app/models/katello/concerns/hostgroup_extensions.rb +9 -2
  91. data/app/models/katello/concerns/organization_extensions.rb +1 -1
  92. data/app/models/katello/concerns/pulp_database_unit.rb +1 -1
  93. data/app/models/katello/concerns/subscription_facet_host_extensions.rb +0 -27
  94. data/app/models/katello/content_view.rb +34 -47
  95. data/app/models/katello/content_view_version.rb +2 -0
  96. data/app/models/katello/deb.rb +8 -0
  97. data/app/models/katello/host/content_facet.rb +19 -14
  98. data/app/models/katello/host/subscription_facet.rb +0 -19
  99. data/app/models/katello/host_tracer.rb +9 -5
  100. data/app/models/katello/installed_deb.rb +13 -0
  101. data/app/models/katello/repository.rb +7 -2
  102. data/app/models/katello/trace_status.rb +6 -2
  103. data/app/overrides/add_organization_attributes.rb +0 -18
  104. data/app/presenters/katello/host_deb_presenter.rb +23 -0
  105. data/app/services/katello/candlepin/consumer.rb +0 -4
  106. data/app/services/katello/candlepin/event_handler.rb +6 -25
  107. data/app/services/katello/candlepin/message_handler.rb +1 -21
  108. data/app/services/katello/host/profiles_uploader.rb +17 -6
  109. data/app/services/katello/host_status_manager.rb +0 -22
  110. data/app/services/katello/organization_creator.rb +2 -2
  111. data/app/services/katello/pulp3/api/apt.rb +1 -1
  112. data/app/services/katello/pulp3/content_view_version/export.rb +2 -2
  113. data/app/services/katello/pulp3/content_view_version/metadata_generator.rb +1 -0
  114. data/app/services/katello/pulp3/content_view_version/metadata_map.rb +3 -0
  115. data/app/services/katello/pulp3/repository/apt.rb +16 -6
  116. data/app/services/katello/registration_manager.rb +1 -13
  117. data/app/views/katello/api/v2/content_views/base.json.rabl +0 -1
  118. data/app/views/katello/api/v2/content_views/show.json.rabl +1 -0
  119. data/app/views/katello/api/v2/host_debs/base.json.rabl +2 -0
  120. data/app/views/katello/api/v2/hosts/base.json.rabl +9 -0
  121. data/app/views/katello/api/v2/subscription_facet/base_with_root.json.rabl +0 -3
  122. data/app/views/katello/api/v2/subscription_facet/show.json.rabl +3 -0
  123. data/app/views/katello/sync_management/index.html.erb +14 -13
  124. data/app/views/overrides/activation_keys/_host_environment_select.html.erb +20 -16
  125. data/app/views/overrides/activation_keys/_host_synced_content_select.html.erb +7 -5
  126. data/app/views/overrides/organizations/_edit_override.html.erb +0 -12
  127. data/db/migrate/20131014225132_add_users_fields.rb +0 -1
  128. data/db/migrate/20150603045418_remove_user_fields.rb +0 -2
  129. data/db/migrate/20160404132250_remove_katello_from_notification_name.rb +4 -22
  130. data/db/migrate/20160505181337_rename_katello_settings.rb +2 -2
  131. data/db/migrate/20200818192230_update_system_purpose_status.rb +9 -3
  132. data/db/migrate/20240111032511_add_index_to_host_installed_packages.rb +16 -0
  133. data/db/migrate/20240123120109_remove_pulp_export_destination_setting.rb +9 -0
  134. data/db/migrate/20240207191223_remove_entitlement_mode_host_statuses.rb +30 -0
  135. data/db/seeds.d/111-upgrade_tasks.rb +2 -1
  136. data/engines/bastion/app/assets/javascripts/bastion/bastion.js +0 -2
  137. data/engines/bastion/app/views/bastion/layouts/assets.html.erb +6 -2
  138. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/activation-keys/details/activation-key-repository-sets.controller.js +3 -1
  139. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/activation-keys/details/views/activation-key-associations-content-hosts.html +2 -6
  140. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/activation-keys/details/views/activation-key-details.html +0 -1
  141. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/bastion-katello-bootstrap.js +45 -29
  142. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/content-hosts-helper.service.js +0 -10
  143. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/details/content-host-details.controller.js +0 -1
  144. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/details/views/content-host-info.html +2 -21
  145. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/details/views/content-host-subscriptions.html +0 -5
  146. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/views/content-hosts.html +0 -7
  147. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/errata/details/views/erratum-content-hosts.html +2 -2
  148. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/host-collections/details/views/host-collection-add-hosts.html +2 -2
  149. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/host-collections/details/views/host-collection-hosts-list.html +2 -2
  150. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/bastion_katello.pot +5 -5
  151. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/details/repositories/details/views/repository-info.html +9 -1
  152. data/engines/bastion_katello/lib/bastion_katello/engine.rb +0 -6
  153. data/lib/katello/engine.rb +0 -3
  154. data/lib/katello/plugin.rb +3 -12
  155. data/lib/katello/tasks/rubocop.rake +0 -9
  156. data/lib/katello/tasks/unify_hosts.rake +0 -1
  157. data/lib/katello/tasks/upgrades/4.12/update_content_access_modes.rake +35 -0
  158. data/lib/katello/version.rb +1 -1
  159. data/locale/action_names.rb +12 -6
  160. data/locale/bn/katello.po +19 -28
  161. data/locale/bn_IN/katello.po +19 -28
  162. data/locale/ca/LC_MESSAGES/katello.mo +0 -0
  163. data/locale/ca/katello.po +20 -29
  164. data/locale/cs/katello.po +19 -29
  165. data/locale/cs_CZ/LC_MESSAGES/katello.mo +0 -0
  166. data/locale/cs_CZ/katello.po +20 -29
  167. data/locale/de/LC_MESSAGES/katello.mo +0 -0
  168. data/locale/de/katello.po +20 -29
  169. data/locale/de_AT/katello.po +19 -28
  170. data/locale/de_DE/katello.po +19 -28
  171. data/locale/el/LC_MESSAGES/katello.mo +0 -0
  172. data/locale/el/katello.po +20 -29
  173. data/locale/en/katello.po +19 -28
  174. data/locale/en_GB/LC_MESSAGES/katello.mo +0 -0
  175. data/locale/en_GB/katello.po +19 -28
  176. data/locale/en_US/katello.po +19 -28
  177. data/locale/es/LC_MESSAGES/katello.mo +0 -0
  178. data/locale/es/katello.po +20 -29
  179. data/locale/et_EE/katello.po +19 -28
  180. data/locale/fr/LC_MESSAGES/katello.mo +0 -0
  181. data/locale/fr/katello.po +20 -29
  182. data/locale/gl/LC_MESSAGES/katello.mo +0 -0
  183. data/locale/gl/katello.po +20 -29
  184. data/locale/gu/katello.po +19 -28
  185. data/locale/he_IL/katello.po +19 -28
  186. data/locale/hi/katello.po +19 -28
  187. data/locale/id/katello.po +19 -28
  188. data/locale/it/LC_MESSAGES/katello.mo +0 -0
  189. data/locale/it/katello.po +20 -29
  190. data/locale/ja/LC_MESSAGES/katello.mo +0 -0
  191. data/locale/ja/katello.po +20 -29
  192. data/locale/ka/LC_MESSAGES/katello.mo +0 -0
  193. data/locale/ka/katello.po +20 -29
  194. data/locale/katello.pot +363 -348
  195. data/locale/kn/katello.po +19 -28
  196. data/locale/ko/LC_MESSAGES/katello.mo +0 -0
  197. data/locale/ko/katello.po +20 -29
  198. data/locale/ml_IN/katello.po +19 -28
  199. data/locale/mr/katello.po +19 -28
  200. data/locale/nl_NL/katello.po +19 -28
  201. data/locale/or/katello.po +19 -28
  202. data/locale/pa/katello.po +19 -28
  203. data/locale/pl/katello.po +19 -28
  204. data/locale/pl_PL/katello.po +19 -28
  205. data/locale/pt/katello.po +19 -28
  206. data/locale/pt_BR/LC_MESSAGES/katello.mo +0 -0
  207. data/locale/pt_BR/katello.po +20 -29
  208. data/locale/ro/katello.po +19 -28
  209. data/locale/ro_RO/katello.po +19 -28
  210. data/locale/ru/LC_MESSAGES/katello.mo +0 -0
  211. data/locale/ru/katello.po +20 -29
  212. data/locale/sl/katello.po +19 -28
  213. data/locale/sv_SE/LC_MESSAGES/katello.mo +0 -0
  214. data/locale/sv_SE/katello.po +20 -29
  215. data/locale/ta/katello.po +19 -28
  216. data/locale/ta_IN/katello.po +19 -28
  217. data/locale/te/katello.po +19 -28
  218. data/locale/tr/katello.po +19 -28
  219. data/locale/vi/katello.po +19 -28
  220. data/locale/vi_VN/katello.po +19 -28
  221. data/locale/zh/katello.po +19 -28
  222. data/locale/zh_CN/LC_MESSAGES/katello.mo +0 -0
  223. data/locale/zh_CN/katello.po +20 -29
  224. data/locale/zh_TW/LC_MESSAGES/katello.mo +0 -0
  225. data/locale/zh_TW/katello.po +20 -29
  226. data/package.json +0 -1
  227. data/webpack/components/extensions/HostDetails/Tabs/ContentTab/SecondaryTabsRoutes.js +4 -0
  228. data/webpack/components/extensions/HostDetails/Tabs/ContentTab/constants.js +4 -1
  229. data/webpack/components/extensions/HostDetails/Tabs/DebsTab/DebInstallModal.js +250 -0
  230. data/webpack/components/extensions/HostDetails/Tabs/DebsTab/DebInstallModal.scss +3 -0
  231. data/webpack/components/extensions/HostDetails/Tabs/DebsTab/DebsTab.js +585 -0
  232. data/webpack/components/extensions/HostDetails/Tabs/DebsTab/DebsTab.scss +12 -0
  233. data/webpack/components/extensions/HostDetails/Tabs/DebsTab/HostDebsActions.js +13 -0
  234. data/webpack/components/extensions/HostDetails/Tabs/DebsTab/HostDebsConstants.js +13 -0
  235. data/webpack/components/extensions/HostDetails/Tabs/DebsTab/HostDebsSelectors.js +16 -0
  236. data/webpack/components/extensions/HostDetails/Tabs/DebsTab/InstallableDebsActions.js +17 -0
  237. data/webpack/components/extensions/HostDetails/Tabs/DebsTab/InstallableDebsConstants.js +3 -0
  238. data/webpack/components/extensions/HostDetails/Tabs/DebsTab/InstallableDebsSelectors.js +16 -0
  239. data/webpack/components/extensions/HostDetails/Tabs/ModuleStreamsTab/ModuleStreamsTab.js +1 -8
  240. data/webpack/components/extensions/HostDetails/Tabs/PackagesTab/PackagesTab.js +2 -0
  241. data/webpack/components/extensions/HostDetails/Tabs/RepositorySetsTab/RepositorySetsActions.js +2 -0
  242. data/webpack/components/extensions/HostDetails/Tabs/RepositorySetsTab/RepositorySetsTab.js +6 -19
  243. data/webpack/components/extensions/HostDetails/Tabs/TracesTab/TracesTab.js +13 -5
  244. data/webpack/components/extensions/HostDetails/Tabs/__tests__/debs.fixtures.json +31 -0
  245. data/webpack/components/extensions/HostDetails/Tabs/__tests__/debsInstallModal.test.js +226 -0
  246. data/webpack/components/extensions/HostDetails/Tabs/__tests__/debsTab.test.js +420 -0
  247. data/webpack/components/extensions/HostDetails/Tabs/__tests__/installableDebs.fixtures.json +63 -0
  248. data/webpack/components/extensions/HostDetails/Tabs/__tests__/repositorySetsTab.test.js +34 -5
  249. data/webpack/components/extensions/HostDetails/Tabs/__tests__/traces.fixtures.json +11 -1
  250. data/webpack/components/extensions/HostDetails/Tabs/__tests__/tracesTab.test.js +63 -3
  251. data/webpack/scenes/ContentViews/ContentViewsConstants.js +3 -0
  252. data/webpack/scenes/ContentViews/Delete/__tests__/affectedHosts.fixtures.json +0 -13
  253. data/webpack/scenes/ContentViews/Details/ContentViewDetailActions.js +23 -1
  254. data/webpack/scenes/ContentViews/Details/ContentViewDetailSelectors.js +19 -1
  255. data/webpack/scenes/ContentViews/Details/Versions/BulkDelete/__tests__/hosts.fixtures.json +0 -13
  256. data/webpack/scenes/ContentViews/Details/Versions/Compare/CVVersionCompareConfig.js +37 -3
  257. data/webpack/scenes/ContentViews/Details/Versions/ContentViewVersionContent.js +10 -2
  258. data/webpack/scenes/ContentViews/Details/Versions/Delete/__tests__/cvAffectedHosts.fixture.json +0 -13
  259. data/webpack/scenes/ContentViews/Details/Versions/VersionDetails/ContentViewVersionDetailConfig.js +31 -5
  260. data/webpack/scenes/Organizations/OrganizationSelectors.js +0 -3
  261. data/webpack/scenes/Subscriptions/Manifest/index.js +1 -4
  262. data/webpack/scenes/Subscriptions/SubscriptionsPage.js +3 -25
  263. data/webpack/scenes/Subscriptions/SubscriptionsSelectors.js +0 -3
  264. data/webpack/scenes/Subscriptions/__tests__/SubscriptionsSelectors.test.js +0 -3
  265. data/webpack/scenes/Subscriptions/__tests__/__snapshots__/SubscriptionsPage.test.js.snap +0 -22
  266. data/webpack/scenes/Subscriptions/__tests__/__snapshots__/SubscriptionsSelectors.test.js.snap +0 -3
  267. data/webpack/scenes/Subscriptions/index.js +1 -2
  268. metadata +48 -195
  269. data/app/controllers/katello/concerns/content_facet_hosts_controller_extensions.rb +0 -22
  270. data/app/models/katello/concerns/widget_extensions.rb +0 -23
  271. data/app/models/katello/purpose_addons_status.rb +0 -28
  272. data/app/models/katello/purpose_role_status.rb +0 -28
  273. data/app/models/katello/purpose_sla_status.rb +0 -28
  274. data/app/models/katello/purpose_status.rb +0 -71
  275. data/app/models/katello/purpose_usage_status.rb +0 -28
  276. data/app/models/katello/subscription_status.rb +0 -71
  277. data/app/services/katello/candlepin/system_purpose.rb +0 -49
  278. data/app/views/dashboard/_subscription_status_widget.html.erb +0 -37
  279. data/app/views/dashboard/_subscription_widget.html.erb +0 -85
  280. data/app/views/overrides/organizations/_index_header_override.html.erb +0 -3
  281. data/app/views/overrides/organizations/_index_row_override.html.erb +0 -3
  282. data/app/views/overrides/organizations/_step_1_override.html.erb +0 -10
  283. data/config/locales/README +0 -10
  284. data/config/locales/bn.yml +0 -182
  285. data/config/locales/compare_upstream.sh +0 -21
  286. data/config/locales/cs.yml +0 -211
  287. data/config/locales/de.yml +0 -203
  288. data/config/locales/en.yml +0 -205
  289. data/config/locales/es.yml +0 -199
  290. data/config/locales/fr.yml +0 -222
  291. data/config/locales/gu.yml +0 -181
  292. data/config/locales/hi.yml +0 -199
  293. data/config/locales/it.yml +0 -205
  294. data/config/locales/ja.yml +0 -197
  295. data/config/locales/kn.yml +0 -199
  296. data/config/locales/ko.yml +0 -197
  297. data/config/locales/mr.yml +0 -178
  298. data/config/locales/or.yml +0 -181
  299. data/config/locales/pa.yml +0 -181
  300. data/config/locales/pt-BR.yml +0 -207
  301. data/config/locales/pt.yml +0 -207
  302. data/config/locales/ru.yml +0 -257
  303. data/config/locales/ta.yml +0 -181
  304. data/config/locales/te.yml +0 -181
  305. data/config/locales/update.sh +0 -14
  306. data/config/locales/zh-CN.yml +0 -199
  307. data/config/locales/zh-TW.yml +0 -199
  308. data/engines/bastion/app/assets/javascripts/bastion/bastion-bootstrap.js +0 -17
  309. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/subscriptions/content-access-mode-banner.directive.js +0 -22
  310. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/subscriptions/views/content-access-mode-banner.html +0 -10
  311. data/webpack/scenes/Subscriptions/Manifest/SimpleContentAccess.js +0 -96
@@ -73,18 +73,27 @@ module Katello
73
73
  "/pulp/deb/#{repo.relative_path}/".sub('//', '/')
74
74
  end
75
75
 
76
- def multi_copy_units(repo_id_map, dependency_solving)
76
+ def multi_copy_units(repo_id_map, _dependency_solving)
77
77
  tasks = []
78
78
 
79
79
  if repo_id_map.values.pluck(:content_unit_hrefs).flatten.any?
80
80
  data = PulpDebClient::Copy.new
81
- data.dependency_solving = dependency_solving
81
+ data.dependency_solving = false
82
82
  data.config = []
83
83
  repo_id_map.each do |source_repo_ids, dest_repo_id_map|
84
84
  dest_repo = ::Katello::Repository.find(dest_repo_id_map[:dest_repo])
85
85
  dest_repo_href = ::Katello::Pulp3::Repository::Apt.new(dest_repo, SmartProxy.pulp_primary).repository_reference.repository_href
86
86
  content_unit_hrefs = dest_repo_id_map[:content_unit_hrefs]
87
87
  # Not needed during incremental update due to dest_base_version
88
+ # -> Unless incrementally updating a CV repo that is a soft copy of its library instance.
89
+ # -> I.e. no filters and not an incremental version.
90
+ unless dest_repo_id_map[:base_version]
91
+ # Don't perform extra content actions if the repo is a soft copy of its library instance.
92
+ # Taken care of by the IncrementalUpdate action.
93
+ unless dest_repo.soft_copy_of_library?
94
+ tasks << remove_all_content_from_repo(dest_repo_href)
95
+ end
96
+ end
88
97
  source_repo_ids.each do |source_repo_id|
89
98
  source_repo_version = ::Katello::Repository.find(source_repo_id).version_href
90
99
  config = { source_repo_version: source_repo_version, dest_repo: dest_repo_href, content: content_unit_hrefs }
@@ -203,9 +212,9 @@ module Katello
203
212
  filter_list_map
204
213
  end
205
214
 
206
- def copy_content_from_mapping(repo_id_map, options = {})
215
+ def copy_content_from_mapping(repo_id_map, _options = {})
207
216
  repo_id_map.each do |source_repo_ids, dest_repo_map|
208
- filters = ContentViewDebFilter.where(:id => options[:filter_ids])
217
+ filters = ContentViewDebFilter.where(:id => dest_repo_map[:filter_ids])
209
218
 
210
219
  filter_list_map = { whitelist_ids: [], blacklist_ids: [] }
211
220
  filter_list_map = add_filter_content(source_repo_ids, filters, filter_list_map)
@@ -218,7 +227,7 @@ module Katello
218
227
  dest_repo_map[:content_unit_hrefs] = content_unit_hrefs.uniq.sort
219
228
  end
220
229
 
221
- dependency_solving = options[:solve_dependencies] || false
230
+ dependency_solving = false
222
231
 
223
232
  multi_copy_units(repo_id_map, dependency_solving)
224
233
  end
@@ -233,7 +242,8 @@ module Katello
233
242
  tasks << add_content(slice, first_slice)
234
243
  first_slice = false
235
244
  end
236
- else
245
+ # If we're merging composite cv repositories, don't clear out the Pulp repository.
246
+ elsif remove_all
237
247
  tasks << remove_all_content
238
248
  end
239
249
  tasks
@@ -148,7 +148,7 @@ module Katello
148
148
  end
149
149
  end
150
150
 
151
- def register_host(host, consumer_params, content_view_environments, activation_keys = []) # rubocop:disable Metrics/MethodLength
151
+ def register_host(host, consumer_params, content_view_environments, activation_keys = [])
152
152
  new_host = host.new_record?
153
153
  unless new_host
154
154
  host.save!
@@ -172,7 +172,6 @@ module Katello
172
172
  host.content_facet.cves_changed = false # prevent backend_update_needed from triggering an update on a nonexistent consumer
173
173
  host.subscription_facet = populate_subscription_facet(host, activation_keys, consumer_params, host_uuid)
174
174
  host.save! # the host has content and subscription facets at this point
175
- create_initial_subscription_status(host)
176
175
 
177
176
  User.as_anonymous_admin do
178
177
  begin
@@ -219,10 +218,6 @@ module Katello
219
218
  destroy_host_record(host.id)
220
219
  end
221
220
 
222
- def create_initial_subscription_status(host)
223
- host.subscription_facet.update_subscription_status(::Katello::SubscriptionStatus::UNKNOWN)
224
- end
225
-
226
221
  def create_in_candlepin(host, content_view_environments, consumer_params, activation_keys)
227
222
  # if CP fails, nothing to clean up yet w.r.t. backend services
228
223
  cp_create = ::Katello::Resources::Candlepin::Consumer.create(content_view_environments.map(&:cp_id), consumer_params, activation_keys.map(&:cp_name), host.organization)
@@ -243,7 +238,6 @@ module Katello
243
238
  host.subscription_facet.save!
244
239
  host.refresh_statuses([
245
240
  ::Katello::ErrataStatus,
246
- ::Katello::SubscriptionStatus,
247
241
  ::Katello::RhelLifecycleStatus
248
242
  ])
249
243
  end
@@ -314,12 +308,6 @@ module Katello
314
308
  end
315
309
 
316
310
  host.get_status(::Katello::ErrataStatus).destroy
317
- host.get_status(::Katello::PurposeSlaStatus).destroy
318
- host.get_status(::Katello::PurposeRoleStatus).destroy
319
- host.get_status(::Katello::PurposeUsageStatus).destroy
320
- host.get_status(::Katello::PurposeAddonsStatus).destroy
321
- host.get_status(::Katello::PurposeStatus).destroy
322
- host.get_status(::Katello::SubscriptionStatus).destroy
323
311
  host.get_status(::Katello::TraceStatus).destroy
324
312
  host.installed_packages.delete_all
325
313
 
@@ -12,7 +12,6 @@ attributes :import_only
12
12
  attributes :generated_for
13
13
  attributes :related_cv_count
14
14
  attributes :related_composite_cvs
15
- attributes :needs_publish? => :needs_publish
16
15
  attributes :filtered? => :filtered
17
16
 
18
17
  node :next_version do |content_view|
@@ -3,6 +3,7 @@ object @resource
3
3
  extends "katello/api/v2/content_views/base"
4
4
 
5
5
  attributes :content_host_count
6
+ attributes :needs_publish? => :needs_publish
6
7
 
7
8
  node :errors do
8
9
  unless @resource.valid?
@@ -2,3 +2,5 @@ object @resource
2
2
 
3
3
  attributes :id, :name
4
4
  attributes :version, :architecture
5
+ attributes :upgradable_versions
6
+ attributes :deb_id
@@ -4,6 +4,15 @@ object @resource
4
4
  @facet = @resource.content_facet
5
5
 
6
6
  attributes :id, :name, :description
7
+
8
+ node :operatingsystem_family do |resource|
9
+ resource.operatingsystem&.family
10
+ end
11
+
12
+ node :operatingsystem_major do |resource|
13
+ resource.operatingsystem&.major
14
+ end
15
+
7
16
  if @facet
8
17
  node :content_view do
9
18
  content_view = @facet&.single_content_view
@@ -1,6 +1,3 @@
1
1
  child :subscription_facet => :subscription_facet_attributes do
2
2
  extends 'katello/api/v2/subscription_facet/base'
3
3
  end
4
-
5
- attributes :subscription_status, :subscription_status_label, :subscription_global_status,
6
- :if => @object.get_status(Katello::SubscriptionStatus).relevant?
@@ -7,6 +7,9 @@ child :subscription_facet => :subscription_facet_attributes do |_facet|
7
7
 
8
8
  child :hypervisor_host => :virtual_host do
9
9
  attributes :id, :name
10
+ node :display_name do |host|
11
+ host.to_label
12
+ end
10
13
  end
11
14
 
12
15
  child :virtual_guests => :virtual_guests do
@@ -1,17 +1,18 @@
1
- <%= javascript 'katello/sync_management' %>
1
+ <% content_for(:katello_javascripts) do -%>
2
+ <%= javascript_include_tag 'katello/sync_management' %>
3
+ <script>
4
+ localize({
5
+ "cancel": "<%= escape_javascript(_('Cancel')) %>",
6
+ "cancelled": "<%= escape_javascript(_('Sync Canceled')) %>",
7
+ "error": "<%= escape_javascript(_('Error')) %>",
8
+ "complete": "<%= escape_javascript(_('Sync complete.')) %>",
9
+ "no_start_time": "<%= escape_javascript(_('No start time currently available.')) %>"
10
+ });
2
11
 
3
- <%= javascript do %>
4
- localize({
5
- "cancel": "<%= escape_javascript(_('Cancel')) %>",
6
- "cancelled": "<%= escape_javascript(_('Sync Canceled')) %>",
7
- "error": "<%= escape_javascript(_('Error')) %>",
8
- "complete": "<%= escape_javascript(_('Sync complete.')) %>",
9
- "no_start_time": "<%= escape_javascript(_('No start time currently available.')) %>"
10
- });
11
-
12
- KT.repo_status = $.parseJSON('<%= escape_javascript(@repo_status.to_json.html_safe) %>');
13
- KT.permissions = { "syncable" : <%= any_syncable? %> };
14
- <% end %>
12
+ KT.repo_status = $.parseJSON('<%= escape_javascript(@repo_status.to_json.html_safe) %>');
13
+ KT.permissions = { "syncable" : <%= any_syncable? %> };
14
+ </script>
15
+ <% end -%>
15
16
 
16
17
  <% if Organization.current -%>
17
18
  <%= hidden_field_tag :organization_id, Organization.current.id%>
@@ -29,23 +29,27 @@ end %>
29
29
  <% env_select_name = using_hostgroups_page? ? 'hostgroup[lifecycle_environment_id]' : 'host[content_facet_attributes][lifecycle_environment_id]' %>
30
30
  <% env_select_attr = using_hostgroups_page? ? 'lifecycle_environment' : 'content_facet.single_lifecycle_environment' %>
31
31
 
32
- <%= field(f, env_select_attr, {:label => _("Lifecycle Environment")}) do
33
- if using_hostgroups_page?
34
- select_tag env_select_id, lifecycle_environment_options(@hostgroup, :include_blank => blank_or_inherit_with_id(f, :lifecycle_environment)),
35
- :class => 'form-control', :name => env_select_name
36
- else
37
- select_tag env_select_id, lifecycle_environment_options(@host, :selected_host_group => @hostgroup || @host.hostgroup, :include_blank => blank_or_inherit_with_id(f, :lifecycle_environment)), :class => 'form-control', :name => env_select_name, :disabled => cv_lce_disabled?
38
- end
39
- end %>
32
+ <%= field(f, env_select_attr, {:label => _("Lifecycle Environment")}) do %>
33
+ <% if using_hostgroups_page? %>
34
+ <%= select_tag env_select_id, lifecycle_environment_options(@hostgroup, :include_blank => blank_or_inherit_with_id(f, :lifecycle_environment)), :class => 'form-control', :name => env_select_name %>
35
+ <% elsif cv_lce_disabled? %>
36
+ <%= hidden_field_tag 'host[content_facet_attributes][lifecycle_environment_id]', fetch_lifecycle_environment(@host).try(:id) %>
37
+ <%= select_tag env_select_id, lifecycle_environment_options(@host, :selected_host_group => @hostgroup || @host.hostgroup, :include_blank => blank_or_inherit_with_id(f, :lifecycle_environment)), :class => 'form-control', :name => env_select_name, :disabled => true %>
38
+ <% else %>
39
+ <%= select_tag env_select_id, lifecycle_environment_options(@host, :selected_host_group => @hostgroup || @host.hostgroup, :include_blank => blank_or_inherit_with_id(f, :lifecycle_environment)), :class => 'form-control', :name => env_select_name %>
40
+ <% end %>
41
+ <% end %>
40
42
 
41
43
  <% cv_select_id = using_hostgroups_page? ? :hostgroup_content_view_id : :host_content_view_id %>
42
44
  <% cv_select_name = using_hostgroups_page? ? 'hostgroup[content_view_id]' : 'host[content_facet_attributes][content_view_id]' %>
43
45
  <% cv_select_attr = using_hostgroups_page? ? 'content_view' : 'content_facet.single_content_view' %>
44
- <%= field(f, cv_select_attr, {:label => _("Content View")}) do
45
- if using_hostgroups_page?
46
- select_tag cv_select_id, content_views_for_host(@hostgroup, :include_blank => blank_or_inherit_with_id(f, :content_view)), :data => {"spinner_path" => spinner_path},
47
- :class => 'form-control', :name => cv_select_name
48
- else
49
- select_tag cv_select_id, content_views_for_host(@host, :selected_host_group => @hostgroup || @host.hostgroup, :include_blank => blank_or_inherit_with_id(f, :content_view)), :data => {"spinner_path" => spinner_path}, :class => 'form-control', :name => cv_select_name, :disabled => cv_lce_disabled?
50
- end
51
- end %>
46
+ <%= field(f, cv_select_attr, {:label => _("Content View")}) do %>
47
+ <% if using_hostgroups_page? %>
48
+ <%= select_tag cv_select_id, content_views_for_host(@hostgroup, :include_blank => blank_or_inherit_with_id(f, :content_view)), :data => {"spinner_path" => spinner_path}, :class => 'form-control', :name => cv_select_name %>
49
+ <% elsif cv_lce_disabled? %>
50
+ <%= hidden_field_tag 'host[content_facet_attributes][content_view_id]', fetch_content_view(@host).try(:id) %>
51
+ <%= select_tag cv_select_id, content_views_for_host(@host, :selected_host_group => @hostgroup || @host.hostgroup, :include_blank => blank_or_inherit_with_id(f, :content_view)), :data => {"spinner_path" => spinner_path}, :class => 'form-control', :name => cv_select_name, :disabled => true %>
52
+ <% else %>
53
+ <%= select_tag cv_select_id, content_views_for_host(@host, :selected_host_group => @hostgroup || @host.hostgroup, :include_blank => blank_or_inherit_with_id(f, :content_view)), :data => {"spinner_path" => spinner_path}, :class => 'form-control', :name => cv_select_name %>
54
+ <% end %>
55
+ <% end %>
@@ -3,7 +3,7 @@
3
3
  kickstart_repo_id = kickstart_repository_id(@host, :selected_host_group => @host&.hostgroup)
4
4
  kickstart_options = kickstart_repository_options(@host, :selected_host_group => @host&.hostgroup)
5
5
  elsif using_hostgroups_page?
6
- kickstart_repo_id = kickstart_repository_id(@host, :selected_host_group => @host&.hostgroup)
6
+ kickstart_repo_id = kickstart_repository_id(@hostgroup, :selected_host_group => @host&.hostgroup)
7
7
  kickstart_options = kickstart_repository_options(@hostgroup)
8
8
  else
9
9
  kickstart_repo_id = kickstart_repository_id(@host, :selected_host_group => @hostgroup)
@@ -23,7 +23,9 @@
23
23
  :class => 'form-control', :name => ks_repo_select_name, :disabled => kickstart_options.empty?
24
24
  end %>
25
25
 
26
- <script>
27
- KT.hosts.set_media_selection_bindings();
28
- KT.hosts.update_media_enablement();
29
- </script>
26
+ <% content_for(:javascripts) do -%>
27
+ <script>
28
+ KT.hosts.set_media_selection_bindings();
29
+ KT.hosts.update_media_enablement();
30
+ </script>
31
+ <% end -%>
@@ -11,16 +11,4 @@
11
11
  :type => :button, :style => 'margin-top: 8px;', :class => 'btn btn-small',
12
12
  'data-url' => "/katello/api/v2/organizations/#{@taxonomy.id}/download_debug_certificate"
13
13
  end %>
14
-
15
- <%= field(f, _('Simple Content Access')) do
16
- tag1 = hidden_field_tag 'simple_content_access', '0'
17
- tag2 = check_box_tag 'simple_content_access', '1', @taxonomy.simple_content_access?(cached: false)
18
- tag1 + tag2
19
- end %>
20
-
21
- <div class="alert alert-warning" role="alert">
22
- <%= link_to _('Simple Content Access'), 'https://access.redhat.com/articles/transition_of_subscription_services_to_the_hybrid_cloud_console', :rel => "external" %>
23
- <%= _(' will be required for all organizations in Katello 4.12.') %>
24
- </div>
25
-
26
14
  <% end %>
@@ -3,7 +3,6 @@ class AddUsersFields < ActiveRecord::Migration[4.2]
3
3
  add_column :users, :helptips_enabled, :boolean, :default => true
4
4
  add_column :users, :hidden, :boolean, :default => false, :null => false
5
5
  add_column :users, :page_size, :integer, :default => 25, :null => false
6
- add_column :users, :disabled, :boolean, :default => false
7
6
  add_column :users, :preferences, :text
8
7
  add_column :users, :remote_id, :string, :limit => 255
9
8
  end
@@ -2,7 +2,6 @@ class RemoveUserFields < ActiveRecord::Migration[4.2]
2
2
  def up
3
3
  remove_column :users, :helptips_enabled
4
4
  remove_column :users, :page_size
5
- remove_column :users, :disabled
6
5
  remove_column :users, :preferences
7
6
  remove_column :users, :remote_id
8
7
  end
@@ -11,7 +10,6 @@ class RemoveUserFields < ActiveRecord::Migration[4.2]
11
10
  add_column :users, :helptips_enabled, :boolean, :default => true
12
11
  add_column :users, :hidden, :boolean, :default => false, :null => false
13
12
  add_column :users, :page_size, :integer, :default => 25, :null => false
14
- add_column :users, :disabled, :boolean, :default => false
15
13
  add_column :users, :preferences, :text
16
14
  add_column :users, :remote_id, :string, :limit => 255
17
15
  end
@@ -1,26 +1,8 @@
1
1
  class RemoveKatelloFromNotificationName < ActiveRecord::Migration[4.2]
2
- class FakeMailNotification < ApplicationRecord
3
- self.table_name = 'mail_notifications'
4
- end
5
-
6
2
  def up
7
- FakeMailNotification.all.each do |notification|
8
- if notification_names.keys.include?(notification.name)
9
- new_name = notification_names[notification.name]
10
- FakeMailNotification.where(:name => new_name).destroy_all
11
- notification.name = new_name
12
- notification.save!
13
- end
14
- end
15
- end
16
-
17
- private
18
-
19
- def notification_names
20
- {
21
- :katello_promote_errata => 'promote_errata',
22
- :katello_sync_errata => 'sync_errata',
23
- :katello_host_advisory => 'host_errata_advisory'
24
- }.with_indifferent_access
3
+ # historical placeholder
4
+ # only required on setups before https://projects.theforeman.org/issues/14459
5
+ # we can safely assume that fresh installs have the above change already
6
+ # and existing install had this migration applied back in 2016
25
7
  end
26
8
  end
@@ -1,9 +1,9 @@
1
1
  class RenameKatelloSettings < ActiveRecord::Migration[4.2]
2
2
  def up
3
- Setting.where(category: 'Setting::Katello').update_all(:category => 'Setting::Content')
3
+ Setting.where(category: 'Setting::Katello').update_all(:category => 'Setting::Content') if column_exists?(:settings, :category)
4
4
  end
5
5
 
6
6
  def down
7
- Setting.where(category: 'Setting::Content').update_all(:category => 'Setting::Katello')
7
+ Setting.where(category: 'Setting::Content').update_all(:category => 'Setting::Katello') if column_exists?(:settings, :category)
8
8
  end
9
9
  end
@@ -1,12 +1,18 @@
1
1
  class UpdateSystemPurposeStatus < ActiveRecord::Migration[6.0]
2
2
  def change
3
- purpose_types = Katello::HostStatusManager::PURPOSE_STATUS.map(&:to_s)
3
+ purpose_types = [
4
+ "Katello::PurposeStatus",
5
+ "Katello::PurposeAddonsStatus",
6
+ "Katello::PurposeRoleStatus",
7
+ "Katello::PurposeSlaStatus",
8
+ "Katello::PurposeUsageStatus"
9
+ ]
4
10
 
5
11
  # load both sets of host statuses and *then* update them to make sure we update the correct statuses
6
12
  unknown_statuses = ::HostStatus::Status.where(type: purpose_types, status: 2).pluck(:id)
7
13
  matched_statuses = ::HostStatus::Status.where(type: purpose_types, status: 0).pluck(:id)
8
14
 
9
- ::HostStatus::Status.where(id: unknown_statuses).update_all(status: Katello::PurposeStatus::UNKNOWN) # 2 => 0
10
- ::HostStatus::Status.where(id: matched_statuses).update_all(status: Katello::PurposeStatus::MATCHED) # 0 => 2
15
+ ::HostStatus::Status.where(id: unknown_statuses).update_all(status: 0) # 2 => 0
16
+ ::HostStatus::Status.where(id: matched_statuses).update_all(status: 2) # 0 => 2
11
17
  end
12
18
  end
@@ -0,0 +1,16 @@
1
+ class AddIndexToHostInstalledPackages < ActiveRecord::Migration[6.1]
2
+ def up
3
+ add_index :katello_host_installed_packages, [:installed_package_id],
4
+ :name => 'katello_host_installed_packages_ip_id'
5
+ add_index :katello_host_installed_packages, [:host_id],
6
+ :name => 'katello_host_installed_packages_host_id'
7
+ end
8
+
9
+ def down
10
+ remove_index :katello_host_installed_packages,
11
+ :name => 'katello_host_installed_packages_ip_id'
12
+
13
+ remove_index :katello_host_installed_packages,
14
+ :name => 'katello_host_installed_packages_host_id'
15
+ end
16
+ end
@@ -0,0 +1,9 @@
1
+ class RemovePulpExportDestinationSetting < ActiveRecord::Migration[6.1]
2
+ def up
3
+ Setting.where(name: 'pulp_export_destination').delete_all
4
+ end
5
+
6
+ def down
7
+ # no action, seeding on app start should create the object with the default value
8
+ end
9
+ end
@@ -0,0 +1,30 @@
1
+ class RemoveEntitlementModeHostStatuses < ActiveRecord::Migration[6.1]
2
+ class FakeTablePreference < ApplicationRecord
3
+ self.table_name = 'table_preferences'
4
+ serialize :columns
5
+ end
6
+
7
+ def up
8
+ obsolete_statuses = [
9
+ "Katello::SubscriptionStatus",
10
+ "Katello::PurposeStatus",
11
+ "Katello::PurposeAddonsStatus",
12
+ "Katello::PurposeRoleStatus",
13
+ "Katello::PurposeSlaStatus",
14
+ "Katello::PurposeUsageStatus"
15
+ ]
16
+
17
+ ::HostStatus::Status.where(type: obsolete_statuses).delete_all
18
+
19
+ FakeTablePreference.where(name: "hosts").each do |table_preference|
20
+ next unless table_preference.columns.include?("subscription_status")
21
+ new_columns = table_preference.columns - ["subscription_status"]
22
+ if new_columns.present?
23
+ table_preference.columns = new_columns
24
+ table_preference.save(validate: false)
25
+ else
26
+ table_preference.destroy
27
+ end
28
+ end
29
+ end
30
+ end
@@ -9,6 +9,7 @@ UpgradeTask.define_tasks(:katello) do
9
9
  {:name => 'katello:upgrades:4.2:remove_checksum_values'},
10
10
  {:name => 'katello:upgrades:4.4:publish_import_cvvs'},
11
11
  {:name => 'katello:upgrades:4.8:fix_incorrect_providers'},
12
- {:name => 'katello:upgrades:4.8:regenerate_imported_repository_metadata'}
12
+ {:name => 'katello:upgrades:4.8:regenerate_imported_repository_metadata'},
13
+ {:name => 'katello:upgrades:4.12:update_content_access_modes'}
13
14
  ]
14
15
  end
@@ -36,5 +36,3 @@
36
36
 
37
37
  //= require "bastion/features/features.module"
38
38
  //= require_tree "./features"
39
-
40
- //= require "bastion/bastion-bootstrap"
@@ -10,11 +10,13 @@
10
10
  <% end %>
11
11
 
12
12
  <% content_for(:javascripts) do %>
13
- <%= javascript_include_tag 'bastion/bastion' %>
13
+
14
+ <%= javascript_tag("window.tfm.tools.loadPluginModule('/webpack/katello','katello','./common_index');".html_safe) %>
15
+ <%= javascript_include_tag('bastion/bastion', {type: 'module'})%>
14
16
  <% if File.exist?("#{Bastion::Engine.root}/vendor/assets/javascripts/#{Bastion.localization_path(I18n.locale)}") %>
15
17
  <%= javascript_include_tag(Bastion.localization_path(I18n.locale)) %>
16
18
  <% end %>
17
- <script type="text/javascript">
19
+ <script type="module">
18
20
  angular.module('Bastion.features').value('FeatureSettings', angular.fromJson(<%= SETTINGS[:features].nil? ? {} : SETTINGS[:features].to_json.html_safe %>));
19
21
  angular.module('Bastion').value('currentLocale', '<%= I18n.locale %>');
20
22
  angular.module('Bastion').value('CurrentOrganization', "<%= Organization.current.id if Organization.current %>");
@@ -34,6 +36,8 @@
34
36
  angular.module('Bastion').value('newHostDetailsUI', "<%= Setting[:host_details_ui] %>");
35
37
  angular.module('Bastion').value('experimentalLabsSetting', "<%= Setting[:lab_features] %>");
36
38
  </script>
39
+
40
+ <%= javascript_include_tag('bastion_katello/bastion_katello', {type: 'module'}) %>
37
41
  <% Bastion.plugins.each do |name, plugin| %>
38
42
  <%= include_plugin_js(plugin) %>
39
43
  <% end %>
@@ -39,7 +39,7 @@ angular.module('Bastion.activation-keys').controller('ActivationKeyRepositorySet
39
39
 
40
40
  $scope.contentAccessModes = {
41
41
  contentAccessModeAll: $scope.simpleContentAccessEnabled,
42
- contentAccessModeEnv: false
42
+ contentAccessModeEnv: true
43
43
  };
44
44
 
45
45
  $scope.selectRepositoryType = function () {
@@ -56,6 +56,8 @@ angular.module('Bastion.activation-keys').controller('ActivationKeyRepositorySet
56
56
  $scope.nutupane.refresh();
57
57
  };
58
58
 
59
+ $scope.toggleFilters();
60
+
59
61
  success = function () {
60
62
  $scope.table.working = false;
61
63
  Notification.setSuccessMessage(translate('Repository Sets settings saved successfully.'));
@@ -29,12 +29,8 @@
29
29
  ng-controller="ContentHostStatusController">
30
30
  <td bst-table-cell>
31
31
  <span ng-switch="newHostDetailsUI">
32
- <a ng-switch-when="true" ng-href="/new/hosts/{{host.name}}">{{ host.name }}</a>
33
- <a ng-switch-when="false" ui-sref="content-host.info({hostId: host.id})">{{ host.name }}</a>
34
- </span>
35
- </td>
36
- <td bst-table-cell ng-if="!simpleContentAccessEnabled">
37
- <span ng-class="getHostStatusIcon(host.subscription_global_status)">
32
+ <a ng-switch-when="true" ng-href="/new/hosts/{{host.name}}">{{ host.display_name }}</a>
33
+ <a ng-switch-when="false" ui-sref="content-host.info({hostId: host.id})">{{ host.display_name }}</a>
38
34
  </span>
39
35
  </td>
40
36
  <td bst-table-cell>{{ host.content_facet_attributes.lifecycle_environment.name }}</td>
@@ -31,7 +31,6 @@
31
31
  </div>
32
32
 
33
33
  <nav data-block="navigation">
34
- <div content-access-mode-banner></div>
35
34
  <ul class="nav nav-tabs details-nav">
36
35
  <li ng-class="{active: isState('activation-key.info')}">
37
36
  <a ui-sref="activation-key.info">
@@ -1,29 +1,45 @@
1
- BASTION_MODULES.push(
2
- 'Bastion.capsule-content',
3
- 'Bastion.pulp-primary',
4
- 'Bastion.activation-keys',
5
- 'Bastion.architectures' ,
6
- 'Bastion.common',
7
- 'Bastion.content-views',
8
- 'Bastion.content-views.versions',
9
- 'Bastion.debs',
10
- 'Bastion.docker-tags',
11
- 'Bastion.files',
12
- 'Bastion.ansible-collections',
13
- 'Bastion.hosts',
14
- 'Bastion.module-streams',
15
- 'Bastion.environments',
16
- 'Bastion.content-credentials',
17
- 'Bastion.hosts',
18
- 'Bastion.capsules',
19
- 'Bastion.organizations',
20
- 'Bastion.products',
21
- 'Bastion.repositories',
22
- 'Bastion.subscriptions',
23
- 'Bastion.sync-plans',
24
- 'Bastion.http-proxies',
25
- 'Bastion.host-collections',
26
- 'Bastion.content-hosts',
27
- 'Bastion.tasks',
28
- 'Bastion.settings'
29
- );
1
+ var BASTION_MODULES = [
2
+ 'angular-blocks',
3
+ 'ngAnimate',
4
+ 'ngSanitize',
5
+ 'templates',
6
+ 'ui.bootstrap',
7
+ 'ui.bootstrap.tpls',
8
+ 'Bastion.auth',
9
+ 'Bastion.menu',
10
+ 'Bastion.i18n',
11
+ 'Bastion.features',
12
+ 'Bastion.routing',
13
+ 'Bastion.capsule-content',
14
+ 'Bastion.pulp-primary',
15
+ 'Bastion.activation-keys',
16
+ 'Bastion.architectures',
17
+ 'Bastion.common',
18
+ 'Bastion.content-views',
19
+ 'Bastion.content-views.versions',
20
+ 'Bastion.debs',
21
+ 'Bastion.docker-tags',
22
+ 'Bastion.files',
23
+ 'Bastion.ansible-collections',
24
+ 'Bastion.hosts',
25
+ 'Bastion.module-streams',
26
+ 'Bastion.environments',
27
+ 'Bastion.content-credentials',
28
+ 'Bastion.hosts',
29
+ 'Bastion.capsules',
30
+ 'Bastion.organizations',
31
+ 'Bastion.products',
32
+ 'Bastion.repositories',
33
+ 'Bastion.subscriptions',
34
+ 'Bastion.sync-plans',
35
+ 'Bastion.http-proxies',
36
+ 'Bastion.host-collections',
37
+ 'Bastion.content-hosts',
38
+ 'Bastion.tasks',
39
+ 'Bastion.settings'
40
+ ];
41
+
42
+ // Check if the document has already been bootstrapped.
43
+ if (!angular.element(document).injector()) {
44
+ angular.bootstrap(document, BASTION_MODULES);
45
+ }
@@ -38,16 +38,6 @@ angular.module('Bastion.content-hosts').service('ContentHostsHelper',
38
38
  return icons[globalStatus];
39
39
  };
40
40
 
41
- this.getHostPurposeStatusIcon = function (statusCode) {
42
- var code = parseInt(statusCode);
43
-
44
- if (code === 2) { // matched
45
- return 'pficon pficon-ok';
46
- } else if (code === 1) { // mismatched
47
- return 'pficon pficon-warning-triangle-o';
48
- }
49
- };
50
-
51
41
  this.rebootRequired = function(traces) {
52
42
  return traces.some(function(trace) {
53
43
  return trace.reboot_required;
@@ -24,7 +24,6 @@ angular.module('Bastion.content-hosts').controller('ContentHostDetailsController
24
24
  $scope.menuExpander = MenuExpander;
25
25
 
26
26
  $scope.getHostStatusIcon = ContentHostsHelper.getHostStatusIcon;
27
- $scope.getHostPurposeStatusIcon = ContentHostsHelper.getHostPurposeStatusIcon;
28
27
 
29
28
  $scope.organization = Organization.get({id: CurrentOrganization}, function(org) {
30
29
  $scope.purposeAddonsCount += org.system_purposes.addons.length;