katello 4.15.0 → 4.16.0.rc1

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 (505) hide show
  1. checksums.yaml +4 -4
  2. data/app/assets/javascripts/katello/common/katello_object.js +2 -2
  3. data/app/assets/javascripts/katello/locale/bn/katello.js +248 -263
  4. data/app/assets/javascripts/katello/locale/bn_IN/katello.js +247 -262
  5. data/app/assets/javascripts/katello/locale/ca/katello.js +247 -262
  6. data/app/assets/javascripts/katello/locale/cs/katello.js +521 -536
  7. data/app/assets/javascripts/katello/locale/cs_CZ/katello.js +253 -268
  8. data/app/assets/javascripts/katello/locale/de/katello.js +248 -263
  9. data/app/assets/javascripts/katello/locale/de_AT/katello.js +247 -262
  10. data/app/assets/javascripts/katello/locale/de_DE/katello.js +249 -264
  11. data/app/assets/javascripts/katello/locale/el/katello.js +251 -266
  12. data/app/assets/javascripts/katello/locale/en/katello.js +253 -268
  13. data/app/assets/javascripts/katello/locale/en_GB/katello.js +263 -278
  14. data/app/assets/javascripts/katello/locale/en_US/katello.js +247 -262
  15. data/app/assets/javascripts/katello/locale/es/katello.js +248 -263
  16. data/app/assets/javascripts/katello/locale/et_EE/katello.js +247 -262
  17. data/app/assets/javascripts/katello/locale/fr/katello.js +250 -265
  18. data/app/assets/javascripts/katello/locale/gl/katello.js +247 -262
  19. data/app/assets/javascripts/katello/locale/gu/katello.js +249 -264
  20. data/app/assets/javascripts/katello/locale/he_IL/katello.js +249 -264
  21. data/app/assets/javascripts/katello/locale/hi/katello.js +248 -263
  22. data/app/assets/javascripts/katello/locale/id/katello.js +261 -275
  23. data/app/assets/javascripts/katello/locale/it/katello.js +252 -267
  24. data/app/assets/javascripts/katello/locale/ja/katello.js +250 -265
  25. data/app/assets/javascripts/katello/locale/ka/katello.js +247 -262
  26. data/app/assets/javascripts/katello/locale/kn/katello.js +248 -263
  27. data/app/assets/javascripts/katello/locale/ko/katello.js +248 -263
  28. data/app/assets/javascripts/katello/locale/ml_IN/katello.js +247 -262
  29. data/app/assets/javascripts/katello/locale/mr/katello.js +248 -263
  30. data/app/assets/javascripts/katello/locale/nl_NL/katello.js +252 -267
  31. data/app/assets/javascripts/katello/locale/or/katello.js +248 -263
  32. data/app/assets/javascripts/katello/locale/pa/katello.js +248 -263
  33. data/app/assets/javascripts/katello/locale/pl/katello.js +248 -263
  34. data/app/assets/javascripts/katello/locale/pl_PL/katello.js +247 -262
  35. data/app/assets/javascripts/katello/locale/pt/katello.js +248 -263
  36. data/app/assets/javascripts/katello/locale/pt_BR/katello.js +248 -263
  37. data/app/assets/javascripts/katello/locale/ro/katello.js +247 -262
  38. data/app/assets/javascripts/katello/locale/ro_RO/katello.js +247 -262
  39. data/app/assets/javascripts/katello/locale/ru/katello.js +253 -268
  40. data/app/assets/javascripts/katello/locale/sl/katello.js +247 -262
  41. data/app/assets/javascripts/katello/locale/sv_SE/katello.js +248 -263
  42. data/app/assets/javascripts/katello/locale/ta/katello.js +248 -263
  43. data/app/assets/javascripts/katello/locale/ta_IN/katello.js +247 -262
  44. data/app/assets/javascripts/katello/locale/te/katello.js +248 -263
  45. data/app/assets/javascripts/katello/locale/tr/katello.js +247 -262
  46. data/app/assets/javascripts/katello/locale/vi/katello.js +247 -262
  47. data/app/assets/javascripts/katello/locale/vi_VN/katello.js +247 -262
  48. data/app/assets/javascripts/katello/locale/zh/katello.js +247 -262
  49. data/app/assets/javascripts/katello/locale/zh_CN/katello.js +250 -265
  50. data/app/assets/javascripts/katello/locale/zh_TW/katello.js +255 -270
  51. data/app/assets/javascripts/katello/sync_management/sync_management.js +16 -2
  52. data/app/controllers/katello/api/registry/registry_proxies_controller.rb +33 -9
  53. data/app/controllers/katello/api/rhsm/candlepin_proxies_controller.rb +1 -1
  54. data/app/controllers/katello/api/v2/activation_keys_controller.rb +4 -9
  55. data/app/controllers/katello/api/v2/content_uploads_controller.rb +2 -1
  56. data/app/controllers/katello/api/v2/content_view_filter_rules_controller.rb +3 -1
  57. data/app/controllers/katello/api/v2/content_views_controller.rb +4 -1
  58. data/app/controllers/katello/api/v2/environments_controller.rb +4 -0
  59. data/app/controllers/katello/api/v2/errata_controller.rb +12 -1
  60. data/app/controllers/katello/api/v2/flatpak_remote_repositories_controller.rb +81 -0
  61. data/app/controllers/katello/api/v2/flatpak_remotes_controller.rb +86 -0
  62. data/app/controllers/katello/api/v2/host_bootc_images_controller.rb +71 -0
  63. data/app/controllers/katello/api/v2/host_subscriptions_controller.rb +4 -6
  64. data/app/controllers/katello/api/v2/hosts_bulk_actions_controller.rb +3 -5
  65. data/app/controllers/katello/api/v2/repositories_controller.rb +18 -3
  66. data/app/controllers/katello/concerns/api/v2/hosts_controller_extensions.rb +0 -8
  67. data/app/controllers/katello/concerns/api/v2/http_proxies_controller_extensions.rb +17 -0
  68. data/app/controllers/katello/concerns/http_proxies_controller_extensions.rb +20 -0
  69. data/app/controllers/katello/sync_management_controller.rb +6 -2
  70. data/app/helpers/katello/content_source_helper.rb +8 -1
  71. data/app/helpers/katello/content_view_helper.rb +3 -1
  72. data/app/lib/actions/candlepin/activation_key/create.rb +1 -3
  73. data/app/lib/actions/candlepin/activation_key/update.rb +1 -3
  74. data/app/lib/actions/candlepin/environment/set_content.rb +17 -4
  75. data/app/lib/actions/katello/activation_key/create.rb +1 -2
  76. data/app/lib/actions/katello/activation_key/update.rb +2 -4
  77. data/app/lib/actions/katello/capsule_content/refresh_repos.rb +7 -1
  78. data/app/lib/actions/katello/content_view/presenters/incremental_updates_presenter.rb +3 -2
  79. data/app/lib/actions/katello/content_view/publish.rb +7 -2
  80. data/app/lib/actions/katello/content_view_environment/reassign_objects.rb +11 -2
  81. data/app/lib/actions/katello/content_view_version/incremental_update.rb +31 -22
  82. data/app/lib/actions/katello/flatpak/mirror_remote_repository.rb +30 -0
  83. data/app/lib/actions/katello/flatpak/scan_remote.rb +17 -12
  84. data/app/lib/actions/katello/host/update_system_purpose.rb +1 -6
  85. data/app/lib/actions/pulp3/orchestration/repository/import_upload.rb +18 -2
  86. data/app/lib/actions/pulp3/repository/multi_copy_units.rb +4 -0
  87. data/app/lib/katello/api/v2/rendering.rb +2 -1
  88. data/app/lib/katello/concerns/base_template_scope_extensions.rb +3 -4
  89. data/app/lib/katello/concerns/bookmark_controller_validator_extensions.rb +13 -0
  90. data/app/lib/katello/resources/candlepin/activation_key.rb +3 -5
  91. data/app/lib/katello/resources/candlepin/product.rb +2 -1
  92. data/app/lib/katello/util/cveak_migrator.rb +3 -2
  93. data/app/lib/katello/validators/alternate_content_source_path_validator.rb +2 -2
  94. data/app/lib/katello/validators/container_image_name_validator.rb +1 -1
  95. data/app/lib/katello/validators/content_validator.rb +1 -1
  96. data/app/lib/katello/validators/content_view_environment_coherent_default_validator.rb +2 -2
  97. data/app/lib/katello/validators/content_view_environment_org_validator.rb +2 -2
  98. data/app/lib/katello/validators/content_view_environment_validator.rb +3 -3
  99. data/app/lib/katello/validators/content_view_erratum_filter_rule_validator.rb +12 -12
  100. data/app/lib/katello/validators/content_view_filter_version_validator.rb +1 -1
  101. data/app/lib/katello/validators/generated_content_view_validator.rb +1 -1
  102. data/app/lib/katello/validators/gpg_key_content_type_validator.rb +2 -2
  103. data/app/lib/katello/validators/gpg_key_content_validator.rb +5 -5
  104. data/app/lib/katello/validators/katello_label_format_validator.rb +4 -4
  105. data/app/lib/katello/validators/katello_name_format_validator.rb +2 -2
  106. data/app/lib/katello/validators/katello_url_format_validator.rb +1 -1
  107. data/app/lib/katello/validators/library_presence_validator.rb +1 -1
  108. data/app/lib/katello/validators/no_trailing_space_validator.rb +1 -1
  109. data/app/lib/katello/validators/non_library_environment_validator.rb +1 -1
  110. data/app/lib/katello/validators/not_in_library_validator.rb +1 -1
  111. data/app/lib/katello/validators/path_descendents_validator.rb +1 -1
  112. data/app/lib/katello/validators/prior_validator.rb +1 -1
  113. data/app/lib/katello/validators/product_unique_attribute_validator.rb +1 -1
  114. data/app/lib/katello/validators/repo_disablement_validator.rb +2 -2
  115. data/app/lib/katello/validators/root_repository_unique_attribute_validator.rb +1 -1
  116. data/app/lib/katello/validators/self_reference_environment_validator.rb +1 -1
  117. data/app/lib/katello/validators/unique_field_in_org.rb +1 -1
  118. data/app/models/katello/activation_key.rb +6 -17
  119. data/app/models/katello/authorization/flatpak_remote.rb +33 -0
  120. data/app/models/katello/concerns/content_facet_host_extensions.rb +2 -1
  121. data/app/models/katello/concerns/host_managed_extensions.rb +8 -5
  122. data/app/models/katello/concerns/http_proxy_extensions.rb +4 -0
  123. data/app/models/katello/concerns/smart_proxy_extensions.rb +30 -6
  124. data/app/models/katello/concerns/subscription_facet_host_extensions.rb +0 -8
  125. data/app/models/katello/content_view.rb +4 -2
  126. data/app/models/katello/content_view_erratum_filter.rb +18 -2
  127. data/app/models/katello/content_view_version.rb +6 -0
  128. data/app/models/katello/docker_manifest.rb +8 -0
  129. data/app/models/katello/docker_manifest_list.rb +8 -0
  130. data/app/models/katello/erratum.rb +8 -2
  131. data/app/models/katello/flatpak_remote.rb +16 -0
  132. data/app/models/katello/flatpak_remote_repository.rb +18 -0
  133. data/app/models/katello/flatpak_remote_repository_manifest.rb +4 -0
  134. data/app/models/katello/glue/candlepin/pool.rb +1 -1
  135. data/app/models/katello/glue/pulp/repos.rb +12 -1
  136. data/app/models/katello/host/content_facet.rb +42 -3
  137. data/app/models/katello/host/subscription_facet.rb +4 -12
  138. data/app/models/katello/repository.rb +21 -8
  139. data/app/models/katello/rhel_lifecycle_status.rb +6 -0
  140. data/app/models/katello/root_repository.rb +6 -8
  141. data/app/models/katello/upstream_pool.rb +1 -0
  142. data/app/overrides/add_organization_attributes.rb +6 -0
  143. data/app/services/katello/product_content_finder.rb +2 -1
  144. data/app/services/katello/pulp3/content_view_version/importable_repositories.rb +1 -1
  145. data/app/services/katello/pulp3/docker_manifest.rb +3 -2
  146. data/app/services/katello/pulp3/docker_manifest_list.rb +3 -2
  147. data/app/services/katello/pulp3/repository/ansible_collection.rb +8 -1
  148. data/app/services/katello/pulp3/repository/apt.rb +16 -18
  149. data/app/services/katello/pulp3/repository/file.rb +4 -2
  150. data/app/services/katello/pulp3/repository.rb +4 -0
  151. data/app/services/katello/pulp3/task.rb +2 -2
  152. data/app/views/foreman/job_templates/bootc_action.erb +26 -0
  153. data/app/views/foreman/job_templates/bootc_rollback.erb +13 -0
  154. data/app/views/foreman/job_templates/bootc_status.erb +13 -0
  155. data/app/views/foreman/job_templates/bootc_switch.erb +13 -0
  156. data/app/views/foreman/job_templates/bootc_upgrade.erb +13 -0
  157. data/app/views/foreman/job_templates/flatpak_install.erb +23 -0
  158. data/app/views/foreman/job_templates/flatpak_login_action.erb +30 -0
  159. data/app/views/foreman/job_templates/flatpak_setup.erb +27 -0
  160. data/app/views/foreman/job_templates/install_errata_by_search_query.erb +1 -1
  161. data/app/views/foreman/job_templates/install_errata_by_search_query_-_katello_ansible_default.erb +1 -1
  162. data/app/views/foreman/job_templates/resolve_traces_-_katello_ansible_default.erb +1 -1
  163. data/app/views/foreman/job_templates/update_packages_by_search_query_-_katello_ansible_default.erb +1 -1
  164. data/app/views/katello/api/v2/activation_keys/base.json.rabl +0 -4
  165. data/app/views/katello/api/v2/content_facet/base.json.rabl +2 -1
  166. data/app/views/katello/api/v2/content_view_filter_rules/show.json.rabl +1 -0
  167. data/app/views/katello/api/v2/content_view_versions/base.json.rabl +5 -1
  168. data/app/views/katello/api/v2/docker_manifest_lists/show.json.rabl +1 -1
  169. data/app/views/katello/api/v2/docker_manifests/show.json.rabl +1 -1
  170. data/app/views/katello/api/v2/flatpak_remote_repositories/base.json.rabl +4 -0
  171. data/app/views/katello/api/v2/flatpak_remote_repositories/index.json.rabl +7 -0
  172. data/app/views/katello/api/v2/flatpak_remote_repositories/show.json.rabl +13 -0
  173. data/app/views/katello/api/v2/flatpak_remotes/base.json.rabl +5 -0
  174. data/app/views/katello/api/v2/flatpak_remotes/index.json.rabl +8 -0
  175. data/app/views/katello/api/v2/flatpak_remotes/permissions.json.rabl +11 -0
  176. data/app/views/katello/api/v2/flatpak_remotes/show.json.rabl +3 -0
  177. data/app/views/katello/api/v2/hosts/base.json.rabl +0 -8
  178. data/app/views/katello/api/v2/hosts/os_attributes.json.rabl +13 -0
  179. data/app/views/katello/api/v2/http_proxies/show.json.rabl +1 -0
  180. data/app/views/katello/api/v2/repositories/base.json.rabl +1 -0
  181. data/app/views/katello/api/v2/repositories/show.json.rabl +1 -0
  182. data/app/views/katello/api/v2/subscription_facet/base.json.rabl +0 -4
  183. data/app/views/katello/api/v2/subscriptions/show.json.rabl +1 -1
  184. data/app/views/overrides/activation_keys/_host_synced_content_select.html.erb +10 -4
  185. data/app/views/overrides/http_proxies/_update_setting_input.html.erb +18 -0
  186. data/app/views/overrides/organizations/_step_1_override.html.erb +5 -0
  187. data/config/initializers/monkeys.rb +0 -1
  188. data/config/initializers/pagelets.rb +6 -0
  189. data/config/routes/api/registry.rb +1 -0
  190. data/config/routes/api/v2.rb +21 -0
  191. data/config/routes/overrides.rb +1 -0
  192. data/config/routes.rb +2 -0
  193. data/db/migrate/20190605014649_add_purpose_addons.rb +0 -12
  194. data/db/migrate/20200213184848_create_evr_type.rb +126 -1
  195. data/db/migrate/20200818192230_update_system_purpose_status.rb +0 -1
  196. data/db/migrate/20240207191223_remove_entitlement_mode_host_statuses.rb +0 -1
  197. data/db/migrate/20240924161240_katello_recreate_evr_constructs.rb +160 -0
  198. data/db/migrate/20241022121706_add_sync_dependencies_option.rb +5 -0
  199. data/db/migrate/20241101144625_remove_system_purpose_addons.rb +9 -0
  200. data/db/migrate/20241107002541_add_registry_url_to_katello_flatpak_remotes.rb +5 -0
  201. data/db/migrate/20241112145802_add_manifest_entity_to_content_facets.rb +7 -0
  202. data/db/migrate/20241120213713_add_allow_other_types_to_content_view_erratum_filter_rules.rb +6 -0
  203. data/db/migrate/20241206183052_add_content_type_to_container_manifests_and_lists.rb +9 -0
  204. data/db/seeds.d/75-job_templates.rb +5 -1
  205. data/engines/bastion/vendor/assets/javascripts/bastion/angular/angular.js +2 -2
  206. data/engines/bastion/vendor/assets/javascripts/bastion/angular-bootstrap/ui-bootstrap-tpls.js +3 -3
  207. data/engines/bastion/vendor/assets/javascripts/bastion/angular-bootstrap/ui-bootstrap.js +3 -3
  208. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/activation-keys/details/activation-key-details-info.controller.js +0 -5
  209. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/activation-keys/details/activation-key-details.controller.js +1 -41
  210. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/activation-keys/details/views/activation-key-info.html +0 -12
  211. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/common/views/subscription-add-or-remove.html +1 -1
  212. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/bulk/content-hosts-bulk-system-purpose-modal.controller.js +1 -41
  213. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/bulk/content-hosts-bulk-traces-modal.controller.js +1 -1
  214. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/bulk/views/content-hosts-bulk-errata-modal.html +2 -2
  215. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/bulk/views/content-hosts-bulk-subscriptions-modal.html +2 -2
  216. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/bulk/views/content-hosts-bulk-system-purpose-modal.html +0 -13
  217. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/content/views/content-host-errata.html +1 -1
  218. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/details/content-host-details-info.controller.js +0 -5
  219. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/details/content-host-details.controller.js +1 -35
  220. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/details/views/content-host-info.html +2 -14
  221. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/details/views/content-host-provisioning-info.html +1 -1
  222. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/views/content-hosts.html +2 -2
  223. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/debs/debs.controller.js +46 -22
  224. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/debs/details/deb-content-views.controller.js +2 -1
  225. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/debs/views/debs.html +4 -0
  226. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/environments/details/views/environment-content-views.html +1 -1
  227. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/environments/details/views/environment-details.html +1 -1
  228. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/environments/details/views/environment-errata.html +1 -1
  229. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/errata/views/errata-tasks-list.html +2 -1
  230. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/bastion_katello.pot +85 -29
  231. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/bn.po +338 -93
  232. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/bn_IN.po +340 -95
  233. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/ca.po +340 -95
  234. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/cs_CZ.po +341 -96
  235. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/de.po +31 -54
  236. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/de_AT.po +338 -93
  237. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/de_DE.po +338 -93
  238. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/el.po +341 -96
  239. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/en_GB.po +349 -104
  240. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/en_US.po +338 -93
  241. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/es.po +33 -56
  242. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/et_EE.po +338 -93
  243. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/fr.po +80 -68
  244. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/gl.po +340 -95
  245. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/gu.po +340 -95
  246. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/he_IL.po +339 -111
  247. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/hi.po +340 -95
  248. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/id.po +379 -130
  249. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/it.po +342 -103
  250. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/ja.po +70 -83
  251. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/ka.po +84 -90
  252. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/kn.po +340 -95
  253. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/ko.po +130 -138
  254. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/ml_IN.po +338 -93
  255. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/mr.po +340 -95
  256. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/nl_NL.po +343 -97
  257. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/or.po +340 -95
  258. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/pa.po +340 -95
  259. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/pl.po +340 -95
  260. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/pl_PL.po +338 -93
  261. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/pt.po +338 -93
  262. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/pt_BR.po +40 -63
  263. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/ro.po +338 -93
  264. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/ro_RO.po +338 -93
  265. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/ru.po +343 -102
  266. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/sl.po +338 -93
  267. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/sv_SE.po +340 -95
  268. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/ta.po +338 -93
  269. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/ta_IN.po +340 -95
  270. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/te.po +340 -95
  271. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/tr.po +338 -93
  272. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/vi.po +338 -93
  273. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/vi_VN.po +338 -93
  274. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/zh.po +338 -93
  275. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/zh_CN.po +70 -83
  276. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/zh_TW.po +362 -105
  277. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/translations.js +29 -29
  278. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/packages/details/views/package-info.html +1 -1
  279. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/bulk/products-bulk-advanced-sync-modal.controller.js +1 -1
  280. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/bulk/views/products-bulk-sync-plan-modal.html +2 -2
  281. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/details/repositories/details/views/repository-info.html +24 -8
  282. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/details/repositories/details/views/repository-tasks.html +2 -1
  283. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/details/repositories/new/new-repository.controller.js +2 -2
  284. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/details/repositories/new/views/new-repository.html +21 -8
  285. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/details/repositories/os-versions.service.js +1 -0
  286. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/details/views/product-info.html +3 -3
  287. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/details/views/product-tasks.html +2 -1
  288. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/discovery/views/discovery-create.html +4 -2
  289. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/discovery/views/discovery.html +2 -1
  290. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/products.controller.js +3 -3
  291. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/views/partials/product-table-sync-status.html +1 -1
  292. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/subscriptions/views/subscription-start-date.html +1 -1
  293. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/sync-plans/details/views/sync-plan-info.html +1 -1
  294. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/sync-plans/views/sync-plans.html +2 -2
  295. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/tasks/tasks-table.directive.js +2 -1
  296. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/tasks/views/task-details.html +2 -2
  297. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/tasks/views/tasks-index.html +1 -1
  298. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/tasks/views/tasks-table.html +1 -1
  299. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/tasks/views/user-tasks-table.html +1 -1
  300. data/lib/katello/engine.rb +6 -0
  301. data/lib/katello/permission_creator.rb +37 -0
  302. data/lib/katello/permissions/host_permissions.rb +2 -0
  303. data/lib/katello/permissions/registry_permissions.rb +1 -0
  304. data/lib/katello/plugin.rb +18 -1
  305. data/lib/katello/repository_types/docker.rb +0 -1
  306. data/lib/katello/repository_types/python.rb +1 -1
  307. data/lib/katello/version.rb +1 -1
  308. data/lib/katello.rb +2 -0
  309. data/locale/Makefile +20 -24
  310. data/locale/bn/LC_MESSAGES/katello.mo +0 -0
  311. data/locale/bn/katello.po +248 -263
  312. data/locale/bn_IN/LC_MESSAGES/katello.mo +0 -0
  313. data/locale/bn_IN/katello.po +247 -262
  314. data/locale/ca/LC_MESSAGES/katello.mo +0 -0
  315. data/locale/ca/katello.po +247 -262
  316. data/locale/cs/LC_MESSAGES/katello.mo +0 -0
  317. data/locale/cs/katello.po +524 -799
  318. data/locale/cs_CZ/LC_MESSAGES/katello.mo +0 -0
  319. data/locale/cs_CZ/katello.po +254 -269
  320. data/locale/de/LC_MESSAGES/katello.mo +0 -0
  321. data/locale/de/katello.po +248 -263
  322. data/locale/de_AT/LC_MESSAGES/katello.mo +0 -0
  323. data/locale/de_AT/katello.po +247 -262
  324. data/locale/de_DE/LC_MESSAGES/katello.mo +0 -0
  325. data/locale/de_DE/katello.po +250 -265
  326. data/locale/el/LC_MESSAGES/katello.mo +0 -0
  327. data/locale/el/katello.po +252 -267
  328. data/locale/en/LC_MESSAGES/katello.mo +0 -0
  329. data/locale/en/katello.po +257 -271
  330. data/locale/en_GB/LC_MESSAGES/katello.mo +0 -0
  331. data/locale/en_GB/katello.po +264 -279
  332. data/locale/en_US/LC_MESSAGES/katello.mo +0 -0
  333. data/locale/en_US/katello.po +247 -262
  334. data/locale/es/LC_MESSAGES/katello.mo +0 -0
  335. data/locale/es/katello.po +248 -263
  336. data/locale/et_EE/LC_MESSAGES/katello.mo +0 -0
  337. data/locale/et_EE/katello.po +247 -262
  338. data/locale/fr/LC_MESSAGES/katello.mo +0 -0
  339. data/locale/fr/katello.po +250 -265
  340. data/locale/gl/LC_MESSAGES/katello.mo +0 -0
  341. data/locale/gl/katello.po +247 -262
  342. data/locale/gu/LC_MESSAGES/katello.mo +0 -0
  343. data/locale/gu/katello.po +250 -265
  344. data/locale/he_IL/LC_MESSAGES/katello.mo +0 -0
  345. data/locale/he_IL/katello.po +249 -264
  346. data/locale/hi/LC_MESSAGES/katello.mo +0 -0
  347. data/locale/hi/katello.po +248 -263
  348. data/locale/id/LC_MESSAGES/katello.mo +0 -0
  349. data/locale/id/katello.po +264 -275
  350. data/locale/it/LC_MESSAGES/katello.mo +0 -0
  351. data/locale/it/katello.po +254 -270
  352. data/locale/ja/LC_MESSAGES/katello.mo +0 -0
  353. data/locale/ja/katello.po +250 -265
  354. data/locale/ka/LC_MESSAGES/katello.mo +0 -0
  355. data/locale/ka/katello.po +247 -262
  356. data/locale/katello.pot +1216 -1215
  357. data/locale/kn/LC_MESSAGES/katello.mo +0 -0
  358. data/locale/kn/katello.po +248 -263
  359. data/locale/ko/LC_MESSAGES/katello.mo +0 -0
  360. data/locale/ko/katello.po +248 -263
  361. data/locale/ml_IN/LC_MESSAGES/katello.mo +0 -0
  362. data/locale/ml_IN/katello.po +247 -262
  363. data/locale/mr/LC_MESSAGES/katello.mo +0 -0
  364. data/locale/mr/katello.po +248 -263
  365. data/locale/nl_NL/LC_MESSAGES/katello.mo +0 -0
  366. data/locale/nl_NL/katello.po +254 -268
  367. data/locale/or/LC_MESSAGES/katello.mo +0 -0
  368. data/locale/or/katello.po +248 -263
  369. data/locale/pa/LC_MESSAGES/katello.mo +0 -0
  370. data/locale/pa/katello.po +248 -263
  371. data/locale/pl/LC_MESSAGES/katello.mo +0 -0
  372. data/locale/pl/katello.po +249 -264
  373. data/locale/pl_PL/LC_MESSAGES/katello.mo +0 -0
  374. data/locale/pl_PL/katello.po +247 -262
  375. data/locale/pt/LC_MESSAGES/katello.mo +0 -0
  376. data/locale/pt/katello.po +248 -263
  377. data/locale/pt_BR/LC_MESSAGES/katello.mo +0 -0
  378. data/locale/pt_BR/katello.po +248 -263
  379. data/locale/ro/LC_MESSAGES/katello.mo +0 -0
  380. data/locale/ro/katello.po +247 -262
  381. data/locale/ro_RO/LC_MESSAGES/katello.mo +0 -0
  382. data/locale/ro_RO/katello.po +247 -262
  383. data/locale/ru/LC_MESSAGES/katello.mo +0 -0
  384. data/locale/ru/katello.po +255 -270
  385. data/locale/sl/LC_MESSAGES/katello.mo +0 -0
  386. data/locale/sl/katello.po +247 -262
  387. data/locale/sv_SE/LC_MESSAGES/katello.mo +0 -0
  388. data/locale/sv_SE/katello.po +249 -264
  389. data/locale/ta/LC_MESSAGES/katello.mo +0 -0
  390. data/locale/ta/katello.po +248 -263
  391. data/locale/ta_IN/LC_MESSAGES/katello.mo +0 -0
  392. data/locale/ta_IN/katello.po +247 -262
  393. data/locale/te/LC_MESSAGES/katello.mo +0 -0
  394. data/locale/te/katello.po +248 -263
  395. data/locale/tr/LC_MESSAGES/katello.mo +0 -0
  396. data/locale/tr/katello.po +247 -262
  397. data/locale/vi/LC_MESSAGES/katello.mo +0 -0
  398. data/locale/vi/katello.po +247 -262
  399. data/locale/vi_VN/LC_MESSAGES/katello.mo +0 -0
  400. data/locale/vi_VN/katello.po +247 -262
  401. data/locale/zh/LC_MESSAGES/katello.mo +0 -0
  402. data/locale/zh/katello.po +247 -262
  403. data/locale/zh_CN/LC_MESSAGES/katello.mo +0 -0
  404. data/locale/zh_CN/katello.po +250 -265
  405. data/locale/zh_TW/LC_MESSAGES/katello.mo +0 -0
  406. data/locale/zh_TW/katello.po +257 -272
  407. data/webpack/ForemanColumnExtensions/index.js +73 -3
  408. data/webpack/ForemanColumnExtensions/index.scss +9 -0
  409. data/webpack/__mocks__/foremanReact/Root/Context/ForemanContext.js +1 -0
  410. data/webpack/components/extensions/HostDetails/Cards/ErrataOverviewCard.js +1 -1
  411. data/webpack/components/extensions/HostDetails/Cards/SystemPurposeCard/SystemPurposeCard.js +1 -20
  412. data/webpack/components/extensions/HostDetails/Cards/SystemPurposeCard/SystemPurposeEditModal.js +3 -61
  413. data/webpack/components/extensions/HostDetails/Cards/SystemPurposeCard/__tests__/SystemPurposeCard.test.js +0 -5
  414. data/webpack/components/extensions/HostDetails/Cards/SystemPurposeCard/__tests__/SystemPurposeEditModal.test.js +0 -5
  415. data/webpack/components/extensions/HostDetails/DetailsTabCards/ImageModeCard.js +87 -0
  416. data/webpack/components/extensions/HostDetails/DetailsTabCards/RegistrationCard.js +28 -2
  417. data/webpack/components/extensions/HostDetails/Tabs/DebsTab/DebInstallModal.js +1 -1
  418. data/webpack/components/extensions/HostDetails/Tabs/ErrataTab/ErrataTab.js +2 -2
  419. data/webpack/components/extensions/HostDetails/Tabs/PackagesTab/PackageInstallModal.js +1 -1
  420. data/webpack/components/extensions/Hosts/FontAwesomeImageModeIcon.js +55 -0
  421. data/webpack/containers/Application/config.js +5 -0
  422. data/webpack/global_index.js +3 -1
  423. data/webpack/redux/actions/RedHatRepositories/helpers.js +9 -0
  424. data/webpack/scenes/BootedContainerImages/BootedContainerImagesConstants.js +5 -0
  425. data/webpack/scenes/BootedContainerImages/BootedContainerImagesPage.js +242 -0
  426. data/webpack/scenes/BootedContainerImages/__tests__/bootedContainerImages.fixtures.js +42 -0
  427. data/webpack/scenes/BootedContainerImages/__tests__/bootedContainerImagesPage.test.js +233 -0
  428. data/webpack/scenes/BootedContainerImages/index.js +4 -0
  429. data/webpack/scenes/ContentViews/Delete/__tests__/affectedHosts.fixtures.json +1 -2
  430. data/webpack/scenes/ContentViews/Details/Filters/CVErrataDateFilterContent.js +39 -7
  431. data/webpack/scenes/ContentViews/Details/Filters/CVErrataIDFilterContent.js +13 -2
  432. data/webpack/scenes/ContentViews/Details/Filters/CVFilterDetailType.js +1 -1
  433. data/webpack/scenes/ContentViews/Details/Filters/__tests__/cvErrataDateFilterContent.test.js +1 -0
  434. data/webpack/scenes/ContentViews/Details/Repositories/RepoIcon.js +4 -2
  435. data/webpack/scenes/ContentViews/Details/Versions/BulkDelete/__tests__/hosts.fixtures.json +1 -2
  436. data/webpack/scenes/ContentViews/Details/Versions/Delete/RemoveSteps/CVReassignActivationKeysForm.js +20 -1
  437. data/webpack/scenes/ContentViews/Details/Versions/Delete/RemoveSteps/CVReassignHostsForm.js +20 -1
  438. data/webpack/scenes/ContentViews/Details/Versions/Delete/RemoveSteps/CVVersionRemoveReview.js +128 -18
  439. data/webpack/scenes/ContentViews/Details/Versions/Delete/__tests__/cvAffectedActivationKeys.fixture.json +0 -1
  440. data/webpack/scenes/ContentViews/Details/Versions/Delete/__tests__/cvAffectedHosts.fixture.json +1 -2
  441. data/webpack/scenes/ContentViews/Details/Versions/Delete/__tests__/cvVersionRemove.test.js +6 -4
  442. data/webpack/scenes/ContentViews/Details/Versions/Delete/affectedActivationKeys.js +5 -1
  443. data/webpack/scenes/ContentViews/Details/Versions/Delete/affectedHosts.js +6 -1
  444. data/webpack/scenes/ContentViews/__tests__/contentViewPage.test.js +1 -1
  445. data/webpack/scenes/ContentViews/expansions/DetailsExpansion.js +5 -1
  446. data/webpack/scenes/SmartProxy/ExpandableCvDetails.js +4 -2
  447. data/webpack/scenes/SmartProxy/__tests__/SmartProxyContentTest.js +38 -0
  448. data/webpack/scenes/Subscriptions/Details/SubscriptionPurposeAttributes.js +0 -1
  449. data/webpack/scenes/Subscriptions/Details/__tests__/__snapshots__/SubscriptionDetailInfo.test.js.snap +0 -10
  450. data/webpack/scenes/Subscriptions/Details/__tests__/__snapshots__/SubscriptionDetails.test.js.snap +0 -3
  451. data/webpack/scenes/Subscriptions/Details/__tests__/subscriptionDetails.fixtures.js +0 -1
  452. metadata +61 -58
  453. data/app/models/katello/activation_key_purpose_addon.rb +0 -6
  454. data/app/models/katello/purpose_addon.rb +0 -11
  455. data/app/models/katello/subscription_facet_purpose_addon.rb +0 -6
  456. data/lib/monkeys/fx_sqlite_skip.rb +0 -13
  457. data/locale/action_names.rb +0 -181
  458. data/locale/bn/katello.po.time_stamp +0 -0
  459. data/locale/bn_IN/katello.po.time_stamp +0 -0
  460. data/locale/ca/katello.po.time_stamp +0 -0
  461. data/locale/cs/katello.po.time_stamp +0 -0
  462. data/locale/cs_CZ/katello.po.time_stamp +0 -0
  463. data/locale/de/katello.po.time_stamp +0 -0
  464. data/locale/de_AT/katello.po.time_stamp +0 -0
  465. data/locale/de_DE/katello.po.time_stamp +0 -0
  466. data/locale/el/katello.po.time_stamp +0 -0
  467. data/locale/en/katello.po.time_stamp +0 -0
  468. data/locale/en_GB/katello.po.time_stamp +0 -0
  469. data/locale/en_US/katello.po.time_stamp +0 -0
  470. data/locale/es/katello.po.time_stamp +0 -0
  471. data/locale/et_EE/katello.po.time_stamp +0 -0
  472. data/locale/fr/katello.po.time_stamp +0 -0
  473. data/locale/gl/katello.po.time_stamp +0 -0
  474. data/locale/gu/katello.po.time_stamp +0 -0
  475. data/locale/he_IL/katello.po.time_stamp +0 -0
  476. data/locale/hi/katello.po.time_stamp +0 -0
  477. data/locale/id/katello.po.time_stamp +0 -0
  478. data/locale/it/katello.po.time_stamp +0 -0
  479. data/locale/ja/katello.po.time_stamp +0 -0
  480. data/locale/ka/katello.po.time_stamp +0 -0
  481. data/locale/kn/katello.po.time_stamp +0 -0
  482. data/locale/ko/katello.po.time_stamp +0 -0
  483. data/locale/ml_IN/katello.po.time_stamp +0 -0
  484. data/locale/mr/katello.po.time_stamp +0 -0
  485. data/locale/nl_NL/katello.po.time_stamp +0 -0
  486. data/locale/or/katello.po.time_stamp +0 -0
  487. data/locale/pa/katello.po.time_stamp +0 -0
  488. data/locale/pl/katello.po.time_stamp +0 -0
  489. data/locale/pl_PL/katello.po.time_stamp +0 -0
  490. data/locale/pt/katello.po.time_stamp +0 -0
  491. data/locale/pt_BR/katello.po.time_stamp +0 -0
  492. data/locale/ro/katello.po.time_stamp +0 -0
  493. data/locale/ro_RO/katello.po.time_stamp +0 -0
  494. data/locale/ru/katello.po.time_stamp +0 -0
  495. data/locale/sl/katello.po.time_stamp +0 -0
  496. data/locale/sv_SE/katello.po.time_stamp +0 -0
  497. data/locale/ta/katello.po.time_stamp +0 -0
  498. data/locale/ta_IN/katello.po.time_stamp +0 -0
  499. data/locale/te/katello.po.time_stamp +0 -0
  500. data/locale/tr/katello.po.time_stamp +0 -0
  501. data/locale/vi/katello.po.time_stamp +0 -0
  502. data/locale/vi_VN/katello.po.time_stamp +0 -0
  503. data/locale/zh/katello.po.time_stamp +0 -0
  504. data/locale/zh_CN/katello.po.time_stamp +0 -0
  505. data/locale/zh_TW/katello.po.time_stamp +0 -0
@@ -0,0 +1,17 @@
1
+ module Katello
2
+ module Concerns
3
+ module Api
4
+ module V2
5
+ module HttpProxiesControllerExtensions
6
+ extend ::Apipie::DSL::Concern
7
+
8
+ update_api(:create, :show) do
9
+ param :http_proxy, Hash do
10
+ param :content_default_http_proxy, :bool, :required => false, :desc => N_('Set this HTTP proxy as the default content HTTP proxy')
11
+ end
12
+ end
13
+ end
14
+ end
15
+ end
16
+ end
17
+ end
@@ -0,0 +1,20 @@
1
+ module Katello
2
+ module Concerns
3
+ module HttpProxiesControllerExtensions
4
+ extend ActiveSupport::Concern
5
+
6
+ included do
7
+ after_action :update_content_default_http_proxy, only: :create
8
+ end
9
+
10
+ private
11
+
12
+ def update_content_default_http_proxy
13
+ return unless @http_proxy.persisted?
14
+ return unless ActiveRecord::Type::Boolean.new.deserialize(params.dig('http_proxy', 'content_default_http_proxy'))
15
+
16
+ Setting[:content_default_http_proxy] = @http_proxy.name
17
+ end
18
+ end
19
+ end
20
+ end
@@ -32,8 +32,12 @@ module Katello
32
32
  end
33
33
 
34
34
  def sync
35
- tasks = sync_repos(params[:repoids]) || []
36
- render :json => tasks.as_json
35
+ begin
36
+ tasks = sync_repos(params[:repoids]) || []
37
+ render json: tasks.as_json
38
+ rescue StandardError => e
39
+ render json: { error: e.message }, status: :internal_server_error
40
+ end
37
41
  end
38
42
 
39
43
  def sync_status
@@ -48,7 +48,14 @@ module Katello
48
48
 
49
49
  source = Foreman::Renderer.get_source(template: template, host: host)
50
50
  scope = Foreman::Renderer.get_scope(source: source, host: host)
51
- Foreman::Renderer.render(source, scope)
51
+
52
+ <<~CMD
53
+ if [ -f /etc/yggdrasil/config.toml ]; then
54
+ cp /etc/yggdrasil/config.toml /etc/yggdrasil/config.toml.bak
55
+ export YGGDRASIL_RESTART_DELAY=10
56
+ #{Foreman::Renderer.render(source, scope)}
57
+ fi
58
+ CMD
52
59
  end
53
60
  end
54
61
  end
@@ -1,10 +1,12 @@
1
1
  module Katello
2
2
  module ContentViewHelper
3
3
  def separated_repo_mapping(repo_mapping, use_multicopy_actions)
4
- separated_mapping = { :pulp3_yum_multicopy => {}, :other => {} }
4
+ separated_mapping = { :pulp3_deb_multicopy => {}, :pulp3_yum_multicopy => {}, :other => {} }
5
5
  repo_mapping.each do |source_repos, dest_repo|
6
6
  if dest_repo.content_type == "yum" && SmartProxy.pulp_primary.pulp3_support?(dest_repo) && use_multicopy_actions
7
7
  separated_mapping[:pulp3_yum_multicopy][source_repos] = dest_repo
8
+ elsif dest_repo.content_type == "deb" && SmartProxy.pulp_primary.pulp3_support?(dest_repo) && use_multicopy_actions
9
+ separated_mapping[:pulp3_deb_multicopy][source_repos] = dest_repo
8
10
  else
9
11
  separated_mapping[:other][source_repos] = dest_repo
10
12
  end
@@ -8,7 +8,6 @@ module Actions
8
8
  param :release_version
9
9
  param :purpose_role
10
10
  param :purpose_usage
11
- param :purpse_addons
12
11
  end
13
12
 
14
13
  def run
@@ -18,8 +17,7 @@ module Actions
18
17
  input[:service_level],
19
18
  input[:release_version],
20
19
  input[:purpose_role],
21
- input[:purpose_usage],
22
- input[:purpose_addons])
20
+ input[:purpose_usage])
23
21
  end
24
22
  end
25
23
  end
@@ -9,7 +9,6 @@ module Actions
9
9
  param :auto_attach
10
10
  param :purpose_role
11
11
  param :purpose_usage
12
- param :purpose_addons
13
12
  end
14
13
 
15
14
  def run
@@ -19,8 +18,7 @@ module Actions
19
18
  input[:service_level],
20
19
  input[:auto_attach],
21
20
  input[:purpose_role],
22
- input[:purpose_usage],
23
- input[:purpose_addons])
21
+ input[:purpose_usage])
24
22
  end
25
23
  end
26
24
  end
@@ -1,7 +1,11 @@
1
1
  module Actions
2
2
  module Candlepin
3
3
  module Environment
4
- class SetContent < Candlepin::Abstract
4
+ class SetContent < Actions::Base
5
+ middleware.use ::Actions::Middleware::RemoteAction
6
+ middleware.use ::Actions::Middleware::CandlepinServicesCheck
7
+ middleware.use ::Actions::Middleware::KeepSessionId
8
+
5
9
  def plan(content_view, environment, content_view_environment, new_content_id = nil)
6
10
  plan_self(:content_view_id => content_view.id,
7
11
  :environment_id => environment.id,
@@ -9,7 +13,7 @@ module Actions
9
13
  :new_content_id => new_content_id)
10
14
  end
11
15
 
12
- def finalize # rubocop:disable Metrics/AbcSize
16
+ def finalize # rubocop:disable Metrics/AbcSize, Metrics/MethodLength
13
17
  content_view = ::Katello::ContentView.find(input[:content_view_id])
14
18
  environment = ::Katello::KTEnvironment.find(input[:environment_id])
15
19
  content_ids = content_view.repos(environment).map(&:content_id).uniq.compact
@@ -32,6 +36,14 @@ module Actions
32
36
  # Since its a dup id refresh the existing ids list (which hopefully will not have the duplicate content)
33
37
  # and try again.
34
38
  output[:add_ids] = content_ids - existing_ids
39
+ rescue RestClient::ResourceNotFound => e
40
+ # Set a higher limit for retries just in case the missing content is not being parsed from the error body correctly.
41
+ # If the content is not found after the retries, assume it is gone and continue.
42
+ raise e if ((retries += 1) == 1_000)
43
+ # Parse the missing content from the Candlepin response and remove it from the add_ids list.
44
+ missing_content = JSON.parse(e.response.body)['displayMessage'].split(' ')[-1].gsub(/"(.+?)"\./, '\1')
45
+ Rails.logger.debug "Content #{missing_content} not found in the environment. Removing it from the add_ids list."
46
+ output[:add_ids].delete(missing_content)
35
47
  end
36
48
  end
37
49
  retries = 0
@@ -39,8 +51,9 @@ module Actions
39
51
  begin
40
52
  output[:delete_response] = ::Katello::Resources::Candlepin::Environment.delete_content(input[:cp_environment_id], output[:delete_ids])
41
53
  break
42
- rescue RestClient::ResourceNotFound => e
43
- raise e if ((retries += 1) == max_retries)
54
+ rescue RestClient::ResourceNotFound
55
+ # If the content is not found after the retries, assume it is gone and continue.
56
+ break if ((retries += 1) == max_retries)
44
57
  # Candlepin raises a 404 in case a content id is not found in this environment
45
58
  # If thats the case lets just refresh the existing ids list (which hopefully will not have the 404'd content)
46
59
  # and try again.
@@ -10,8 +10,7 @@ module Actions
10
10
  service_level: params[:service_level],
11
11
  release_version: activation_key.release_version,
12
12
  purpose_role: activation_key.purpose_role,
13
- purpose_usage: activation_key.purpose_usage,
14
- purpose_addons: activation_key.purpose_addons.pluck(:name))
13
+ purpose_usage: activation_key.purpose_usage)
15
14
  cp_id = cp_create.output[:response][:id]
16
15
  action_subject(activation_key, :cp_id => cp_id)
17
16
  plan_self
@@ -14,8 +14,7 @@ module Actions
14
14
  service_level: activation_key.service_level,
15
15
  auto_attach: activation_key.auto_attach,
16
16
  purpose_role: activation_key.purpose_role,
17
- purpose_usage: activation_key.purpose_usage,
18
- purpose_addons: activation_key.purpose_addons.pluck(:name))
17
+ purpose_usage: activation_key.purpose_usage)
19
18
  end
20
19
  end
21
20
 
@@ -24,8 +23,7 @@ module Actions
24
23
  cp_changed?(activation_key.service_level, activation_key_params[:service_level]) ||
25
24
  cp_changed?(activation_key.release_version, activation_key_params[:release_version]) ||
26
25
  cp_changed?(activation_key.purpose_role, activation_key_params[:purpose_role]) ||
27
- cp_changed?(activation_key.purpose_usage, activation_key_params[:purpose_usage]) ||
28
- cp_changed?(activation_key.purpose_addon_ids, activation_key_params[:purpose_addon_ids])
26
+ cp_changed?(activation_key.purpose_usage, activation_key_params[:purpose_usage])
29
27
  end
30
28
 
31
29
  def cp_changed?(activation_key, activation_key_params)
@@ -45,9 +45,15 @@ module Actions
45
45
 
46
46
  pulp_repo = repo.backend_service(smart_proxy)
47
47
  if !current_repos_on_capsule_ids.include?(repo.id)
48
+ # create_mirror_entities does not apply to the primary smart proxy
48
49
  pulp_repo.create_mirror_entities
49
50
  else
50
- tasks += pulp_repo.refresh_mirror_entities
51
+ if smart_proxy.pulp_primary?
52
+ # The primary smart proxy has extra remote options, like proxy_url
53
+ tasks += pulp_repo.refresh_entities
54
+ else
55
+ tasks += pulp_repo.refresh_mirror_entities
56
+ end
51
57
  end
52
58
  end
53
59
  tasks
@@ -6,7 +6,8 @@ module Actions
6
6
  HUMANIZED_TYPES = {
7
7
  ::Katello::Erratum::CONTENT_TYPE => "Errata",
8
8
  ::Katello::ModuleStream::CONTENT_TYPE => "Module Streams",
9
- ::Katello::Rpm::CONTENT_TYPE => "Packages",
9
+ ::Katello::Rpm::CONTENT_TYPE => "RPM Packages",
10
+ ::Katello::Deb::CONTENT_TYPE => "Deb Packages",
10
11
  }.freeze
11
12
 
12
13
  def humanized_output
@@ -25,7 +26,7 @@ module Actions
25
26
  if cvv
26
27
  humanized_lines << "Content View: #{cvv.content_view.name} version #{cvv.version}"
27
28
  humanized_lines << _("Added Content:")
28
- [::Katello::Erratum, ::Katello::ModuleStream, ::Katello::Rpm].each do |content_type|
29
+ [::Katello::Erratum, ::Katello::ModuleStream, ::Katello::Rpm, ::Katello::Deb].each do |content_type|
29
30
  unless output[:added_units][content_type::CONTENT_TYPE].blank?
30
31
  humanized_lines << " #{HUMANIZED_TYPES[content_type::CONTENT_TYPE]}:"
31
32
  humanized_lines += output[:added_units][content_type::CONTENT_TYPE].sort.map { |unit| " #{unit}" }
@@ -59,8 +59,13 @@ module Actions
59
59
 
60
60
  if options[:importing]
61
61
  handle_import(version, **options.slice(:path, :metadata))
62
- elsif separated_repo_map[:pulp3_yum_multicopy].keys.flatten.present?
63
- plan_action(Repository::MultiCloneToVersion, separated_repo_map[:pulp3_yum_multicopy], version)
62
+ else
63
+ if separated_repo_map[:pulp3_deb_multicopy].keys.flatten.present?
64
+ plan_action(Repository::MultiCloneToVersion, separated_repo_map[:pulp3_deb_multicopy], version)
65
+ end
66
+ if separated_repo_map[:pulp3_yum_multicopy].keys.flatten.present?
67
+ plan_action(Repository::MultiCloneToVersion, separated_repo_map[:pulp3_yum_multicopy], version)
68
+ end
64
69
  end
65
70
 
66
71
  concurrence do
@@ -5,11 +5,20 @@ module Actions
5
5
  def plan(content_view_environment, options)
6
6
  concurrence do
7
7
  content_view_environment.hosts.each do |host|
8
- plan_action(Host::Reassign, host, options[:system_content_view_id], options[:system_environment_id])
8
+ content_facet_attributes = host.content_facet
9
+ if content_facet_attributes.multi_content_view_environment?
10
+ content_facet_attributes.content_view_environments -= [content_view_environment]
11
+ else
12
+ plan_action(Host::Reassign, host, options[:system_content_view_id], options[:system_environment_id])
13
+ end
9
14
  end
10
15
 
11
16
  content_view_environment.activation_keys.each do |key|
12
- plan_action(ActivationKey::Reassign, key, options[:key_content_view_id], options[:key_environment_id])
17
+ if key.multi_content_view_environment?
18
+ key.content_view_environments = key.content_view_environments - [content_view_environment]
19
+ else
20
+ plan_action(ActivationKey::Reassign, key, options[:key_content_view_id], options[:key_environment_id])
21
+ end
13
22
  end
14
23
  end
15
24
  end
@@ -74,29 +74,31 @@ module Actions
74
74
  end
75
75
 
76
76
  concurrence do
77
- if separated_repo_map[:pulp3_yum_multicopy].keys.flatten.present?
78
- extended_repo_mapping = pulp3_repo_mapping(separated_repo_map[:pulp3_yum_multicopy], old_version)
79
- unit_map = pulp3_content_mapping(content)
80
-
81
- unless extended_repo_mapping.empty? || unit_map.values.flatten.empty?
82
- sequence do
83
- # Pre-copy content if dest_repo is a soft copy of its library instance.
84
- # Don't use extended_repo_mapping because the source repositories are library instances.
85
- # We want the old CV snapshot repositories here so as to not pull in excess new content.
86
- separated_repo_map[:pulp3_yum_multicopy].each do |source_repos, dest_repo|
87
- if dest_repo.soft_copy_of_library?
88
- source_repos.each do |source_repo|
89
- # remove_all flag is set to cover the case of incrementally updating more than once with different content.
90
- # Without it, content from the previous incremental update will be copied as well due to how Pulp repo versions work.
91
- plan_action(Pulp3::Repository::CopyContent, source_repo, SmartProxy.pulp_primary, dest_repo, copy_all: true, remove_all: true)
77
+ [:pulp3_deb_multicopy, :pulp3_yum_multicopy].each do |mapping|
78
+ if separated_repo_map[mapping].keys.flatten.present?
79
+ extended_repo_mapping = pulp3_repo_mapping(separated_repo_map[mapping], old_version)
80
+ unit_map = pulp3_content_mapping(content)
81
+
82
+ unless extended_repo_mapping.empty? || unit_map.values.flatten.empty?
83
+ sequence do
84
+ # Pre-copy content if dest_repo is a soft copy of its library instance.
85
+ # Don't use extended_repo_mapping because the source repositories are library instances.
86
+ # We want the old CV snapshot repositories here so as to not pull in excess new content.
87
+ separated_repo_map[mapping].each do |source_repos, dest_repo|
88
+ if dest_repo.soft_copy_of_library?
89
+ source_repos.each do |source_repo|
90
+ # remove_all flag is set to cover the case of incrementally updating more than once with different content.
91
+ # Without it, content from the previous incremental update will be copied as well due to how Pulp repo versions work.
92
+ plan_action(Pulp3::Repository::CopyContent, source_repo, SmartProxy.pulp_primary, dest_repo, copy_all: true, remove_all: true)
93
+ end
92
94
  end
93
95
  end
94
- end
95
- copy_action_outputs << plan_action(Pulp3::Repository::MultiCopyUnits, extended_repo_mapping, unit_map,
96
- dependency_solving: dep_solve).output
97
- repos_to_clone.each do |source_repos|
98
- if separated_repo_map[:pulp3_yum_multicopy].keys.include?(source_repos)
99
- copy_repos(repository_mapping[source_repos])
96
+ copy_action_outputs << plan_action(Pulp3::Repository::MultiCopyUnits, extended_repo_mapping, unit_map,
97
+ dependency_solving: dep_solve).output
98
+ repos_to_clone.each do |source_repos|
99
+ if separated_repo_map[mapping].keys.include?(source_repos)
100
+ copy_repos(repository_mapping[source_repos])
101
+ end
100
102
  end
101
103
  end
102
104
  end
@@ -124,12 +126,15 @@ module Actions
124
126
 
125
127
  def pulp3_content_mapping(content)
126
128
  units = ::Katello::Erratum.with_identifiers(content[:errata_ids]) +
129
+ ::Katello::Deb.with_identifiers(content[:deb_ids]) +
127
130
  ::Katello::Rpm.with_identifiers(content[:package_ids])
128
- unit_map = { :errata => [], :rpms => [] }
131
+ unit_map = { :errata => [], :debs => [], :rpms => [] }
129
132
  units.each do |unit|
130
133
  case unit.class.name
131
134
  when "Katello::Erratum"
132
135
  unit_map[:errata] << unit.id
136
+ when "Katello::Deb"
137
+ unit_map[:debs] << unit.id
133
138
  when "Katello::Rpm"
134
139
  unit_map[:rpms] << unit.id
135
140
  end
@@ -230,6 +235,7 @@ module Actions
230
235
  new_errata = new_repo.errata - (matched_old_repo&.errata || [])
231
236
  new_module_streams = new_repo.module_streams - (matched_old_repo&.module_streams || [])
232
237
  new_rpms = new_repo.rpms - (matched_old_repo&.rpms || [])
238
+ new_debs = new_repo.debs - (matched_old_repo&.debs || [])
233
239
 
234
240
  new_errata.each do |erratum|
235
241
  content[::Katello::Erratum::CONTENT_TYPE] << erratum.errata_id
@@ -241,6 +247,9 @@ module Actions
241
247
  new_rpms.each do |rpm|
242
248
  content[::Katello::Rpm::CONTENT_TYPE] << rpm.nvra
243
249
  end
250
+ new_debs.each do |deb|
251
+ content[::Katello::Deb::CONTENT_TYPE] << deb.nva
252
+ end
244
253
  end
245
254
  end
246
255
  output[:added_units] = content
@@ -0,0 +1,30 @@
1
+ module Actions
2
+ module Katello
3
+ module Flatpak
4
+ class MirrorRemoteRepository < Actions::EntryAction
5
+ def plan(remote_repository, product)
6
+ repo_params = {
7
+ name: remote_repository.name,
8
+ label: remote_repository.label,
9
+ url: remote_repository.flatpak_remote&.registry_url,
10
+ description: 'Mirrored from: ' + remote_repository.flatpak_remote.name,
11
+ product_id: product.id,
12
+ content_type: 'docker',
13
+ docker_upstream_name: remote_repository.name,
14
+ include_tags: ["latest"],
15
+ upstream_username: remote_repository.flatpak_remote.username,
16
+ upstream_password: remote_repository.flatpak_remote.token,
17
+ unprotected: true,
18
+ mirroring_policy: ::Katello::RootRepository::MIRRORING_POLICY_CONTENT,
19
+ }
20
+ root = product.add_repo(repo_params)
21
+ plan_action(::Actions::Katello::Repository::CreateRoot, root)
22
+ end
23
+
24
+ def humanized_name
25
+ _("Mirror Remote Repository")
26
+ end
27
+ end
28
+ end
29
+ end
30
+ end
@@ -5,25 +5,16 @@ module Actions
5
5
  module Flatpak
6
6
  class ScanRemote < Actions::EntryAction
7
7
  def plan(remote, _args = {})
8
- url = format_url(remote.url)
9
- plan_self({:remote_id => remote.id, :url => url})
8
+ plan_self({:remote_id => remote.id, :url => format_url(remote.url)})
10
9
  end
11
10
 
12
11
  def run
13
12
  remote = ::Katello::FlatpakRemote.find(input[:remote_id])
14
- url = input[:url]
15
- request_params = {
16
- method: :get,
17
- headers: { accept: :json },
18
- url: url,
19
- }
20
- results = RestClient::Request.execute(request_params)
21
- results = JSON.parse(results)
13
+ results = fetch_results(input[:url])
14
+ remote.update!(registry_url: results['Registry']) unless remote.registry_url
22
15
  repositories = results['Results']
23
16
  repositories.each do |repository|
24
17
  remote_repository = remote.remote_repositories.find_or_initialize_by(name: repository['Name'])
25
- remote_repository.label = remote.name + '-' + repository['Name']
26
- remote_repository.flatpak_remote = remote
27
18
  remote_repository.save!
28
19
  repository['Images'].each do |image|
29
20
  remote_repository_manifest = remote_repository.manifests.find_or_initialize_by(digest: image['Digest'])
@@ -38,8 +29,22 @@ module Actions
38
29
  end
39
30
  end
40
31
 
32
+ def rescue_strategy
33
+ Dynflow::Action::Rescue::Skip
34
+ end
35
+
41
36
  private
42
37
 
38
+ def fetch_results(url)
39
+ request_params = {
40
+ method: :get,
41
+ headers: { accept: :json },
42
+ url: url,
43
+ }
44
+ response = RestClient::Request.execute(request_params)
45
+ JSON.parse(response)
46
+ end
47
+
43
48
  def extract_runtime_from_metadata(metadata)
44
49
  match = metadata.match(/^runtime=(.*)$/)
45
50
  match ? "runtime/" + match[1] : nil
@@ -2,18 +2,13 @@ module Actions
2
2
  module Katello
3
3
  module Host
4
4
  class UpdateSystemPurpose < Actions::EntryAction
5
- def plan(host, service_level, purpose_role, purpose_usage, purpose_addons)
5
+ def plan(host, service_level, purpose_role, purpose_usage)
6
6
  fail _("Host %s has not been registered with subscription-manager.") % host.name unless host.subscription_facet
7
7
 
8
8
  host.subscription_facet.service_level = service_level unless service_level.nil?
9
9
  host.subscription_facet.purpose_role = purpose_role unless purpose_role.nil?
10
10
  host.subscription_facet.purpose_usage = purpose_usage unless purpose_usage.nil?
11
11
 
12
- if purpose_addons
13
- purpose_addon_objects = purpose_addons.delete_if(&:blank?).uniq.map { |x| ::Katello::PurposeAddon.find_or_create_by(name: x) }
14
- host.subscription_facet.purpose_addons = purpose_addon_objects
15
- end
16
-
17
12
  host.save!
18
13
  plan_self(:hostname => host.name)
19
14
  end
@@ -19,8 +19,22 @@ module Actions
19
19
  plan_action(Pulp3::Repository::SaveVersion, repository, {force_fetch_version: true, tasks: tag_manifest_output[:pulp_tasks]})
20
20
  else
21
21
  if content_unit_href
22
- artifact_output = { :content_unit_href => content_unit_href }
23
22
  commit_output = {}
23
+ if repository.deb?
24
+ # find artifact-href
25
+ content_backend_service = smart_proxy.content_service('deb')
26
+ artifact_href = content_backend_service.content_api.read(content_unit_href).artifact
27
+
28
+ artifact_output = plan_action(Pulp3::Repository::SaveArtifact,
29
+ file,
30
+ repository,
31
+ smart_proxy,
32
+ nil,
33
+ args.dig(:unit_type_id),
34
+ args.merge({artifact_href: artifact_href})).output
35
+ else
36
+ artifact_output = { :content_unit_href => content_unit_href }
37
+ end
24
38
  else
25
39
  commit_output = plan_action(Pulp3::Repository::CommitUpload,
26
40
  repository,
@@ -48,7 +62,9 @@ module Actions
48
62
  if input[:content_unit_href]
49
63
  output[:content_unit_href] = input[:content_unit_href]
50
64
  elsif input[:artifact_output]
51
- output[:content_unit_href] = input[:artifact_output][:content_unit_href] || input[:artifact_output][:pulp_tasks].last[:created_resources].first
65
+ output[:content_unit_href] = input[:artifact_output][:content_unit_href] ||
66
+ input[:artifact_output][:pulp_tasks].last[:created_resources].find { |href| href.include?("/deb/packages") } ||
67
+ input[:artifact_output][:pulp_tasks].last[:created_resources].first
52
68
  else
53
69
  output[:content_unit_href] = nil
54
70
  end
@@ -35,6 +35,10 @@ module Actions
35
35
  katello_errata.id in (#{input[:unit_map][:errata].join(",")})").map(&:erratum_pulp3_href)
36
36
  end
37
37
 
38
+ if input[:unit_map][:debs].any?
39
+ unit_hrefs << ::Katello::Deb.where(:id => input[:unit_map][:debs]).map(&:pulp_id)
40
+ end
41
+
38
42
  if input[:unit_map][:rpms].any?
39
43
  unit_hrefs << ::Katello::Rpm.where(:id => input[:unit_map][:rpms]).map(&:pulp_id)
40
44
  end
@@ -41,8 +41,9 @@ module Katello
41
41
  def respond_with_template(action, resource_name, options = {}, &_block)
42
42
  yield if block_given?
43
43
  status = options[:status] || 200
44
+ template = options[:full_template] || "katello/api/v2/#{resource_name}/#{action}"
44
45
 
45
- render :template => "katello/api/v2/#{resource_name}/#{action}",
46
+ render :template => template,
46
47
  :status => status,
47
48
  :locals => options.slice(:object_name, :root_name, :locals),
48
49
  :layout => "katello/api/v2/layouts/#{options[:layout]}"
@@ -257,17 +257,16 @@ module Katello
257
257
  search_since = since.present? ? "ended_at > \"#{since}\"" : nil
258
258
  search_result = status.present? && status != 'all' ? "result = #{status}" : nil
259
259
  labels = 'label ^ (Actions::Katello::Host::Erratum::Install, Actions::Katello::Host::Erratum::ApplicableErrataInstall)'
260
- select = 'foreman_tasks_tasks.*'
261
260
 
262
261
  new_labels = 'label = Actions::RemoteExecution::RunHostJob AND remote_execution_feature.label ^ (katello_errata_install, katello_errata_install_by_search)'
263
262
  labels = [labels, new_labels].map { |label| "(#{label})" }.join(' OR ')
264
- select += ',template_invocations.id AS template_invocation_id'
265
263
 
266
264
  search = [search_up_to, search_since, search_result, "state = stopped", labels].compact.join(' and ')
267
265
 
268
266
  tasks = load_resource(klass: ForemanTasks::Task,
269
267
  permission: 'view_foreman_tasks',
270
- select: select,
268
+ joins: [:template_invocation],
269
+ preload: [:template_invocation],
271
270
  search: search)
272
271
  only_host_ids = ::Host.search_for(host_filter).pluck(:id) if host_filter
273
272
 
@@ -383,7 +382,7 @@ module Katello
383
382
  found = script.lines.find { |line| line.start_with? '# RESOLVED_ERRATA_IDS=' } || ''
384
383
  (found.chomp.split('=', 2).last || '').split(',')
385
384
  else
386
- TemplateInvocationInputValue.joins(:template_input).where("template_invocation_id = ? AND template_inputs.name = ?", task.template_invocation_id, 'errata')
385
+ TemplateInvocationInputValue.joins(:template_input).where("template_invocation_id = ? AND template_inputs.name = ?", task.template_invocation.id, 'errata')
387
386
  .first&.value&.split(',') || []
388
387
  end
389
388
  end
@@ -0,0 +1,13 @@
1
+ module Katello
2
+ module Concerns
3
+ module BookmarkControllerValidatorExtensions
4
+ extend ActiveSupport::Concern
5
+
6
+ def valid_controllers_list
7
+ @valid_controllers_list ||= (["dashboard", "common_parameters", "/katello/api/v2/host_bootc_images"] +
8
+ ActiveRecord::Base.connection.tables.map(&:to_s) +
9
+ Permission.resources.map(&:tableize)).uniq
10
+ end
11
+ end
12
+ end
13
+ end
@@ -10,8 +10,7 @@ module Katello
10
10
  ::Katello::Util::Data.array_with_indifferent_access akeys
11
11
  end
12
12
 
13
- # rubocop:disable Metrics/ParameterLists
14
- def create(name, owner_key, auto_attach, service_level, release_version, purpose_role, purpose_usage, purpose_addons)
13
+ def create(name, owner_key, auto_attach, service_level, release_version, purpose_role, purpose_usage)
15
14
  url = "/candlepin/owners/#{owner_key}/activation_keys"
16
15
  params = {
17
16
  name: name,
@@ -20,14 +19,13 @@ module Katello
20
19
  releaseVer: release_version,
21
20
  role: purpose_role,
22
21
  usage: purpose_usage,
23
- addOns: purpose_addons,
24
22
  }
25
23
  response = self.post(url, params.to_json, self.default_headers)
26
24
  JSON.parse(response.body).with_indifferent_access
27
25
  end
28
26
 
29
- def update(id, release_version, service_level, auto_attach, purpose_role, purpose_usage, purpose_addons)
30
- attrs = { :releaseVer => release_version, :serviceLevel => service_level, :autoAttach => auto_attach, :role => purpose_role, :usage => purpose_usage, :addOns => purpose_addons }.delete_if { |_k, v| v.nil? }
27
+ def update(id, release_version, service_level, auto_attach, purpose_role, purpose_usage)
28
+ attrs = { :releaseVer => release_version, :serviceLevel => service_level, :autoAttach => auto_attach, :role => purpose_role, :usage => purpose_usage }.delete_if { |_k, v| v.nil? }
31
29
  JSON.parse(self.put(path(id), attrs.to_json, self.default_headers).body).with_indifferent_access
32
30
  end
33
31
 
@@ -4,7 +4,8 @@ module Katello
4
4
  class Product < CandlepinResource
5
5
  class << self
6
6
  def all(owner_label, included = [])
7
- products = JSON.parse(Candlepin::CandlepinResource.get(path(owner_label) + "?#{included_list(included)}", self.default_headers).body)
7
+ url = path(owner_label) + "?active=include" + "&#{included_list(included)}"
8
+ products = JSON.parse(Candlepin::CandlepinResource.get(url, self.default_headers).body)
8
9
  ::Katello::Util::Data.array_with_indifferent_access products
9
10
  end
10
11
 
@@ -27,8 +27,9 @@ module Katello
27
27
  Rails.logger.info "You may want to change the content view / lifecycle environment for these activation keys manually."
28
28
  end
29
29
  (aks_with_no_cve + aks_with_missing_cve).each do |ak|
30
- default_content_view = ak.organization.default_content_view
31
- library = ak.organization.library
30
+ ak_organization = ::Organization.find_by(id: ak.organization_id)
31
+ default_content_view = ak_organization.default_content_view
32
+ library = ak_organization.library
32
33
  Rails.logger.info "Updating activation key #{ak.name} with default content_view_id and lifecycle_environment_id"
33
34
  ak&.update_columns(content_view_id: default_content_view&.id, environment_id: library&.id)
34
35
  end