katello 3.16.0.rc5 → 3.17.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.
- checksums.yaml +4 -4
- data/app/assets/stylesheets/katello/katello.scss +3 -7
- data/app/controllers/katello/api/registry/registry_proxies_controller.rb +44 -26
- data/app/controllers/katello/api/rhsm/candlepin_dynflow_proxy_controller.rb +1 -1
- data/app/controllers/katello/api/rhsm/candlepin_proxies_controller.rb +2 -2
- data/app/controllers/katello/api/v2/activation_keys_controller.rb +8 -0
- data/app/controllers/katello/api/v2/api_controller.rb +1 -1
- data/app/controllers/katello/api/v2/content_credentials_controller.rb +1 -1
- data/app/controllers/katello/api/v2/content_uploads_controller.rb +5 -5
- data/app/controllers/katello/api/v2/content_view_filters_controller.rb +5 -1
- data/app/controllers/katello/api/v2/content_view_repositories_controller.rb +47 -0
- data/app/controllers/katello/api/v2/content_view_versions_controller.rb +50 -19
- data/app/controllers/katello/api/v2/gpg_keys_controller.rb +1 -1
- data/app/controllers/katello/api/v2/host_subscriptions_controller.rb +10 -4
- data/app/controllers/katello/api/v2/host_tracer_controller.rb +0 -5
- data/app/controllers/katello/api/v2/hosts_bulk_actions_controller.rb +10 -0
- data/app/controllers/katello/api/v2/products_bulk_actions_controller.rb +15 -0
- data/app/controllers/katello/api/v2/repositories_controller.rb +24 -11
- data/app/controllers/katello/api/v2/subscriptions_controller.rb +1 -1
- data/app/controllers/katello/api/v2/upstream_subscriptions_controller.rb +16 -0
- data/app/controllers/katello/concerns/api/v2/{associations_permission_check.rb → authorization.rb} +20 -2
- data/app/controllers/katello/concerns/api/v2/bulk_hosts_extensions.rb +4 -4
- data/app/controllers/katello/concerns/api/v2/hostgroups_controller_extensions.rb +1 -1
- data/app/controllers/katello/concerns/hosts_controller_extensions.rb +11 -5
- data/app/helpers/katello/concerns/dashboard_helper_extensions.rb +10 -0
- data/app/helpers/katello/content_view_helper.rb +15 -0
- data/app/helpers/katello/hosts_and_hostgroups_helper.rb +6 -7
- data/app/lib/actions/katello/capsule_content/refresh_repos.rb +1 -1
- data/app/lib/actions/katello/capsule_content/sync.rb +4 -3
- data/app/lib/actions/katello/capsule_content/sync_capsule.rb +17 -3
- data/app/lib/actions/katello/content_view/capsule_sync.rb +1 -1
- data/app/lib/actions/katello/content_view/destroy.rb +2 -2
- data/app/lib/actions/katello/content_view/incremental_updates.rb +3 -1
- data/app/lib/actions/katello/content_view/promote_to_environment.rb +1 -0
- data/app/lib/actions/katello/content_view/publish.rb +63 -19
- data/app/lib/actions/katello/content_view_puppet_environment/clone.rb +1 -1
- data/app/lib/actions/katello/content_view_puppet_environment/create.rb +2 -2
- data/app/lib/actions/katello/content_view_version/incremental_update.rb +83 -53
- data/app/lib/actions/katello/host/attach_subscriptions.rb +5 -1
- data/app/lib/actions/katello/organization/manifest_delete.rb +1 -0
- data/app/lib/actions/katello/organization/manifest_import.rb +1 -0
- data/app/lib/actions/katello/organization/manifest_refresh.rb +1 -0
- data/app/lib/actions/katello/organization/simple_content_access/disable.rb +17 -0
- data/app/lib/actions/katello/organization/simple_content_access/enable.rb +17 -0
- data/app/lib/actions/katello/organization/simple_content_access/toggle.rb +36 -0
- data/app/lib/actions/katello/orphan_cleanup/remove_orphans.rb +13 -0
- data/app/lib/actions/katello/product/destroy.rb +25 -4
- data/app/lib/actions/katello/repository/clone_contents.rb +3 -3
- data/app/lib/actions/katello/repository/clone_to_environment.rb +2 -2
- data/app/lib/actions/katello/repository/clone_to_version.rb +1 -1
- data/app/lib/actions/katello/repository/create.rb +1 -1
- data/app/lib/actions/katello/repository/destroy.rb +10 -4
- data/app/lib/actions/katello/repository/export.rb +3 -3
- data/app/lib/actions/katello/repository/finish_upload.rb +2 -2
- data/app/lib/actions/katello/repository/import_upload.rb +3 -3
- data/app/lib/actions/katello/repository/metadata_generate.rb +1 -1
- data/app/lib/actions/katello/repository/multi_clone_contents.rb +62 -0
- data/app/lib/actions/katello/repository/multi_clone_to_version.rb +30 -0
- data/app/lib/actions/katello/repository/purge_empty_content.rb +1 -1
- data/app/lib/actions/katello/repository/remove_content.rb +1 -1
- data/app/lib/actions/katello/repository/sync.rb +35 -25
- data/app/lib/actions/katello/repository/update.rb +11 -16
- data/app/lib/actions/katello/repository/update_http_proxy_details.rb +1 -1
- data/app/lib/actions/katello/repository/update_metadata_sync.rb +1 -1
- data/app/lib/actions/katello/repository/upload_files.rb +2 -2
- data/app/lib/actions/katello/repository/verify_checksum.rb +28 -0
- data/app/lib/actions/katello/sync_plan/run.rb +1 -1
- data/app/lib/actions/pulp/content_view_puppet_environment/copy_contents.rb +1 -1
- data/app/lib/actions/pulp/orchestration/orphan_cleanup/remove_orphans.rb +1 -1
- data/app/lib/actions/pulp/orchestration/repository/smart_proxy_sync.rb +1 -0
- data/app/lib/actions/pulp/orchestration/repository/sync.rb +2 -1
- data/app/lib/actions/pulp/repository/copy_all_units.rb +1 -1
- data/app/lib/actions/pulp/repository/copy_units.rb +1 -1
- data/app/lib/actions/pulp/repository/create.rb +1 -1
- data/app/lib/actions/pulp/repository/destroy.rb +1 -1
- data/app/lib/actions/pulp/repository/remove_units.rb +2 -2
- data/app/lib/actions/pulp/repository/sync.rb +3 -2
- data/app/lib/actions/pulp3/abstract_async_task.rb +62 -58
- data/app/lib/actions/pulp3/capsule_content/refresh_content_guard.rb +17 -0
- data/app/lib/actions/pulp3/capsule_content/sync.rb +3 -1
- data/app/lib/actions/pulp3/{ContentGuard → content_guard}/refresh.rb +0 -0
- data/app/lib/actions/pulp3/content_guard/refresh_all_distributions.rb +19 -0
- data/app/lib/actions/pulp3/content_migration.rb +7 -3
- data/app/lib/actions/pulp3/content_view_version/create_exporter.rb +20 -0
- data/app/lib/actions/pulp3/content_view_version/destroy_exporter.rb +16 -0
- data/app/lib/actions/pulp3/content_view_version/export.rb +19 -0
- data/app/lib/actions/pulp3/import_migration.rb +3 -3
- data/app/lib/actions/pulp3/orchestration/content_view_version/export.rb +69 -0
- data/app/lib/actions/pulp3/orchestration/repository/copy_all_units.rb +2 -4
- data/app/lib/actions/pulp3/orchestration/repository/create.rb +1 -1
- data/app/lib/actions/pulp3/orchestration/repository/multi_copy_all_units.rb +36 -0
- data/app/lib/actions/pulp3/orchestration/repository/sync.rb +3 -1
- data/app/lib/actions/pulp3/orchestration/repository/trigger_update_repo_cert_guard.rb +22 -0
- data/app/lib/actions/pulp3/orchestration/repository/upload_content.rb +1 -1
- data/app/lib/actions/pulp3/repository/copy_content.rb +0 -1
- data/app/lib/actions/pulp3/repository/multi_copy_content.rb +28 -0
- data/app/lib/actions/pulp3/repository/multi_copy_units.rb +15 -8
- data/app/lib/actions/pulp3/repository/presenters/content_unit_presenter.rb +1 -1
- data/app/lib/actions/pulp3/repository/presenters/repair_presenter.rb +85 -0
- data/app/lib/actions/pulp3/repository/refresh_distribution.rb +11 -5
- data/app/lib/actions/pulp3/repository/repair.rb +29 -0
- data/app/lib/actions/pulp3/repository/save_artifact.rb +1 -1
- data/app/lib/actions/pulp3/repository/save_distribution_references.rb +2 -2
- data/app/lib/actions/pulp3/repository/save_version.rb +20 -8
- data/app/lib/actions/pulp3/repository/save_versions.rb +47 -13
- data/app/lib/actions/pulp3/repository/sync.rb +1 -1
- data/app/lib/actions/pulp3/repository/update_cv_repository_cert_guard.rb +6 -2
- data/app/lib/actions/pulp3/repository/upload_file.rb +2 -2
- data/app/lib/katello/concerns/base_template_scope_extensions.rb +9 -3
- data/app/lib/katello/concerns/permission_extensions.rb +14 -0
- data/app/lib/katello/errors.rb +1 -15
- data/app/lib/katello/foreman.rb +1 -1
- data/app/lib/katello/resources/registry.rb +3 -3
- data/app/lib/katello/util/cdn_var_substitutor.rb +1 -0
- data/app/lib/katello/validators/hostgroup_kickstart_repository_validator.rb +11 -11
- data/app/models/katello/activation_key.rb +1 -1
- data/app/models/katello/authorization/content_view_version_export_history.rb +11 -0
- data/app/models/katello/authorization/product.rb +4 -0
- data/app/models/katello/authorization/repository.rb +8 -0
- data/app/models/katello/concerns/content_facet_host_extensions.rb +9 -1
- data/app/models/katello/concerns/host_managed_extensions.rb +39 -0
- data/app/models/katello/concerns/hostgroup_extensions.rb +46 -24
- data/app/models/katello/concerns/organization_extensions.rb +6 -1
- data/app/models/katello/concerns/pulp_database_unit.rb +2 -2
- data/app/models/katello/concerns/redhat_extensions.rb +4 -2
- data/app/models/katello/concerns/smart_proxy_extensions.rb +35 -21
- data/app/models/katello/concerns/subscription_facet_host_extensions.rb +1 -1
- data/app/models/katello/concerns/widget_extensions.rb +23 -0
- data/app/models/katello/content_view.rb +28 -8
- data/app/models/katello/content_view_erratum_filter.rb +13 -0
- data/app/models/katello/content_view_filter.rb +4 -0
- data/app/models/katello/content_view_module_stream_filter.rb +30 -3
- data/app/models/katello/content_view_package_filter.rb +1 -1
- data/app/models/katello/content_view_puppet_environment.rb +1 -1
- data/app/models/katello/content_view_version.rb +10 -1
- data/app/models/katello/content_view_version_export_history.rb +22 -0
- data/app/models/katello/docker_meta_tag.rb +1 -1
- data/app/models/katello/errata_status.rb +21 -12
- data/app/models/katello/erratum.rb +14 -1
- data/app/models/katello/erratum_cve.rb +8 -0
- data/app/models/katello/glue/candlepin/owner.rb +4 -2
- data/app/models/katello/glue/pulp/repo.rb +3 -1
- data/app/models/katello/host/content_facet.rb +26 -0
- data/app/models/katello/host_collection.rb +6 -0
- data/app/models/katello/hostgroup/content_facet.rb +18 -0
- data/app/models/katello/installed_package.rb +8 -0
- data/app/models/katello/kt_environment.rb +10 -2
- data/app/models/katello/model.rb +16 -0
- data/app/models/katello/module_stream.rb +1 -1
- data/app/models/katello/package_group.rb +1 -1
- data/app/models/katello/ping.rb +9 -6
- data/app/models/katello/pool.rb +17 -0
- data/app/models/katello/product.rb +6 -0
- data/app/models/katello/pulp3/content_guard.rb +1 -1
- data/app/models/katello/purpose_addons_status.rb +1 -0
- data/app/models/katello/purpose_role_status.rb +1 -0
- data/app/models/katello/purpose_sla_status.rb +1 -0
- data/app/models/katello/purpose_status.rb +2 -2
- data/app/models/katello/purpose_usage_status.rb +1 -0
- data/app/models/katello/repository.rb +37 -16
- data/app/models/katello/rhsm_fact_parser.rb +1 -1
- data/app/models/katello/root_repository.rb +11 -12
- data/app/models/katello/subscription_status.rb +1 -1
- data/app/models/katello/sync_plan.rb +8 -0
- data/app/models/katello/trace_status.rb +1 -1
- data/app/models/setting/content.rb +8 -2
- data/app/presenters/katello/sync_status_presenter.rb +4 -2
- data/app/services/cert/certs.rb +10 -2
- data/app/services/katello/candlepin/event_handler.rb +1 -0
- data/app/services/katello/event_daemon.rb +7 -8
- data/app/services/katello/host_status_manager.rb +20 -0
- data/app/services/katello/pulp/content.rb +1 -1
- data/app/services/katello/pulp/repository.rb +7 -7
- data/app/services/katello/pulp/repository/deb.rb +2 -2
- data/app/services/katello/pulp/repository/docker.rb +5 -5
- data/app/services/katello/pulp/repository/file.rb +2 -2
- data/app/services/katello/pulp/repository/ostree.rb +2 -2
- data/app/services/katello/pulp/repository/puppet.rb +2 -2
- data/app/services/katello/pulp/repository/yum.rb +7 -7
- data/app/services/katello/pulp/smart_proxy_repository.rb +1 -1
- data/app/services/katello/pulp3/ansible_collection.rb +2 -2
- data/app/services/katello/pulp3/api/core.rb +20 -0
- data/app/services/katello/pulp3/content.rb +3 -3
- data/app/services/katello/pulp3/content_view_version/export.rb +71 -0
- data/app/services/katello/pulp3/distribution.rb +2 -2
- data/app/services/katello/pulp3/docker_blob.rb +2 -2
- data/app/services/katello/pulp3/docker_manifest.rb +2 -2
- data/app/services/katello/pulp3/docker_manifest_list.rb +2 -2
- data/app/services/katello/pulp3/docker_tag.rb +2 -2
- data/app/services/katello/pulp3/erratum.rb +5 -3
- data/app/services/katello/pulp3/file_unit.rb +2 -2
- data/app/services/katello/pulp3/migration.rb +145 -35
- data/app/services/katello/pulp3/migration_plan.rb +55 -19
- data/app/services/katello/pulp3/migration_switchover.rb +41 -9
- data/app/services/katello/pulp3/module_stream.rb +2 -2
- data/app/services/katello/pulp3/package_group.rb +2 -2
- data/app/services/katello/pulp3/repository.rb +15 -6
- data/app/services/katello/pulp3/repository/docker.rb +18 -10
- data/app/services/katello/pulp3/repository/yum.rb +187 -42
- data/app/services/katello/pulp3/repository_mirror.rb +9 -3
- data/app/services/katello/pulp3/rpm.rb +2 -2
- data/app/services/katello/pulp3/smart_proxy_mirror_repository.rb +2 -2
- data/app/services/katello/pulp3/smart_proxy_repository.rb +1 -1
- data/app/services/katello/pulp3/srpm.rb +2 -2
- data/app/services/katello/pulp3/task.rb +100 -0
- data/app/services/katello/pulp3/task_group.rb +79 -0
- data/app/services/katello/pulp3/yum_metadata_file.rb +2 -2
- data/app/services/katello/registration_manager.rb +9 -3
- data/app/services/katello/repository_type.rb +1 -1
- data/app/services/katello/smart_proxy_helper.rb +14 -17
- data/app/views/foreman/job_templates/install_errata_-_katello_ansible_default.erb +10 -2
- data/app/views/foreman/smart_proxies/_content_sync.html.erb +1 -1
- data/app/views/katello/api/v2/content_view_filters/base.json.rabl +4 -0
- data/app/views/katello/api/v2/content_view_repositories/show_all.json.rabl +8 -0
- data/app/views/katello/api/v2/content_view_version_export_histories/index.json.rabl +7 -0
- data/app/views/katello/api/v2/content_view_version_export_histories/show.json.rabl +13 -0
- data/app/views/katello/api/v2/package_groups/show.json.rabl +1 -1
- data/app/views/katello/api/v2/packages/show.json.rabl +1 -1
- data/app/views/katello/api/v2/repositories/base.json.rabl +1 -0
- data/app/views/katello/api/v2/srpms/show.json.rabl +1 -1
- data/app/views/katello/api/v2/sync_plans/show.json.rabl +2 -1
- data/config/routes/api/rhsm.rb +1 -0
- data/config/routes/api/v2.rb +10 -1
- data/db/migrate/20141222151001_add_host_content_view_environment.rb +1 -1
- data/db/migrate/20180904122343_create_hostgroup_content_facet.katello.rb +16 -0
- data/db/migrate/20200514092553_move_katello_fields_from_hostgroups.katello.rb +53 -0
- data/db/migrate/20200610112009_remove_audits_of_root_repo_with_content_id.rb +9 -0
- data/db/migrate/20200701150946_add_auto_enabled_to_root_repository.rb +5 -0
- data/db/migrate/20200709021250_add_original_modules_to_content_view_module_stream_filter.rb +5 -0
- data/db/migrate/20200721142707_remove_duplicate_katello_pools_index.rb +5 -0
- data/db/migrate/20200818040551_add_content_view_version_export_history.rb +13 -0
- data/db/migrate/20200818192230_update_system_purpose_status.rb +12 -0
- data/db/migrate/20200820145217_add_download_concurrency_to_katello_root_repositories.rb +5 -0
- data/db/migrate/20200910140340_remove_distribution_uuid.rb +5 -0
- data/db/migrate/20200914200906_remove_auto_enabled.rb +5 -0
- data/db/seeds.d/75-job_templates.rb +2 -2
- data/engines/bastion/app/assets/javascripts/bastion/bastion.js +1 -0
- data/engines/bastion/app/assets/javascripts/bastion/components/nutupane.factory.js +3 -1
- data/engines/bastion/app/assets/javascripts/bastion/routing.module.js +1 -1
- data/engines/bastion/vendor/assets/javascripts/bastion/angular-ui-router/stateEvents.js +300 -0
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/activation-keys/activation-keys.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/activation-keys/details/activation-key-add-subscriptions.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/activation-keys/details/activation-key-associations.controller.js +6 -3
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/activation-keys/details/activation-key-details.controller.js +4 -2
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/activation-keys/details/activation-key-subscriptions.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/activation-keys/details/views/activation-key-add-subscriptions.html +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/activation-keys/details/views/activation-key-associations-content-hosts.html +2 -2
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/activation-keys/details/views/activation-key-details.html +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/capsule-content/capsule-content.routes.js +1 -13
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-credentials/details/content-credential-products.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-credentials/details/content-credential-repositories.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/bulk/content-hosts-bulk-errata-modal.controller.js +5 -2
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/bulk/content-hosts-bulk-host-collections-modal.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/bulk/content-hosts-bulk-module-streams-modal.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/bulk/content-hosts-bulk-packages-modal.controller.js +4 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/bulk/content-hosts-bulk-repository-sets-modal.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/bulk/content-hosts-bulk-subscriptions-modal.controller.js +2 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/bulk/content-hosts-bulk-traces-modal.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/bulk/views/content-hosts-bulk-environment-modal.html +7 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/bulk/views/content-hosts-bulk-errata-modal.html +1 -0
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/bulk/views/content-hosts-bulk-packages-modal.html +1 -0
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/content-hosts-helper.service.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/content-hosts.controller.js +5 -3
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/content-hosts.routes.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/content/content-host-debs-installed.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/content/content-host-errata.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/content/content-host-module-streams.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/content/content-host-packages-applicable.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/content/content-host-packages-installed.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/content/content-host-traces.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/details/content-host-add-host-collections.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/details/content-host-add-subscriptions.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/details/content-host-details-info.controller.js +11 -3
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/details/content-host-details.controller.js +4 -2
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/details/content-host-host-collections.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/details/content-host-subscriptions.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/details/views/content-host-add-subscriptions.html +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/details/views/content-host-details.html +1 -0
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/details/views/content-host-info.html +16 -8
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/details/views/content-host-subscriptions-list.html +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-hosts/views/content-hosts.html +6 -6
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-views/content-views.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-views/details/components/content-view-composite-available-content-views.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-views/details/components/content-view-composite-content-views-list.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-views/details/content-view-available-docker-repositories.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-views/details/content-view-available-ostree-repositories.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-views/details/content-view-docker-repositories-list.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-views/details/content-view-ostree-repositories-list.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-views/details/content-view-versions.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-views/details/filters/available-errata-filter.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-views/details/filters/available-package-group-filter.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-views/details/filters/filter-details.controller.js +17 -4
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-views/details/filters/views/module-stream-filter-details.html +17 -0
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-views/details/puppet-modules/content-view-puppet-module-names.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-views/details/puppet-modules/content-view-puppet-module-versions.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-views/details/puppet-modules/content-view-puppet-modules.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/content-views/versions/content-view-version-content.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/debs/debs.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/debs/details/deb-content-views.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/debs/details/deb-repositories.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/environments/details/environment-content.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/errata/details/erratum-repositories.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/files/details/file-content-views.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/files/details/file-repositories.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/files/files.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/host-collections/details/host-collection-details.controller.js +5 -2
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/host-collections/details/views/host-collection-info.html +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/host-collections/host-collections.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/bastion_katello.pot +45 -4
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/de.po +58 -13
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/es.po +46 -9
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/fr.po +43 -6
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/it.po +37 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/ja.po +37 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/ko.po +37 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/pt_BR.po +46 -9
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/ru.po +37 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/zh_CN.po +37 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/locale/zh_TW.po +37 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/i18n/translations.js +4 -4
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/organizations/fenced-pages.service.js +11 -2
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/organizations/organization-selector.controller.js +5 -14
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/ostree-branches/details/ostree-branch-repositories.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/packages/details/package-repositories.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/packages/packages.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/bulk/product-bulk-action.factory.js +1 -0
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/bulk/products-bulk-sync-plan-modal.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/details/product-repositories.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/details/repositories/details/repository-details-manage-content.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/details/repositories/details/repository-details.controller.js +6 -0
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/details/repositories/details/views/repository-details.html +7 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/details/repositories/details/views/repository-info.html +1 -0
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/details/repositories/new/views/new-repository.html +3 -2
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/details/repositories/repository.factory.js +1 -0
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/products.controller.js +16 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/views/products.html +6 -0
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/puppet-modules/details/puppet-module-content-views.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/puppet-modules/details/puppet-module-repositories.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/puppet-modules/puppet-modules.controller.js +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/subscriptions/views/content-access-mode-banner.html +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/sync-plans/details/sync-plan-details-info.controller.js +4 -3
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/sync-plans/details/views/sync-plan-info.html +1 -1
- data/engines/bastion_katello/app/assets/javascripts/bastion_katello/sync-plans/sync-plans.controller.js +1 -1
- data/lib/katello/engine.rb +8 -5
- data/lib/katello/permission_creator.rb +15 -10
- data/lib/katello/plugin.rb +20 -17
- data/lib/katello/tasks/clean_published_repo_directories.rake +3 -3
- data/lib/katello/tasks/pulp3_content_switchover.rake +24 -6
- data/lib/katello/tasks/pulp3_migration.rake +4 -2
- data/lib/katello/tasks/pulp3_post_migration_check.rake +2 -2
- data/lib/katello/tasks/reimport.rake +1 -1
- data/lib/katello/tasks/reports.rake +4 -0
- data/lib/katello/tasks/repository.rake +15 -2
- data/lib/katello/tasks/test.rake +15 -0
- data/lib/katello/tasks/unify_hosts.rake +1 -0
- data/lib/katello/tasks/upgrades/3.11/update_puppet_repos.rake +3 -3
- data/lib/katello/tasks/upgrades/3.12/remove_pulp2_notifier.rake +2 -2
- data/lib/katello/tasks/upgrades/3.8/clear_checksum_type.rake +2 -2
- data/lib/katello/version.rb +1 -1
- data/locale/action_names.rb +40 -40
- data/locale/bn/katello.po +137 -14
- data/locale/cs/katello.po +137 -14
- data/locale/de/katello.po +138 -15
- data/locale/en/katello.po +137 -14
- data/locale/es/katello.po +138 -15
- data/locale/fr/katello.po +138 -15
- data/locale/gu/katello.po +137 -14
- data/locale/hi/katello.po +137 -14
- data/locale/it/katello.po +138 -15
- data/locale/ja/katello.po +138 -15
- data/locale/katello.pot +976 -776
- data/locale/kn/katello.po +137 -14
- data/locale/ko/katello.po +138 -15
- data/locale/mr/katello.po +137 -14
- data/locale/or/katello.po +137 -14
- data/locale/pa/katello.po +137 -14
- data/locale/pt/katello.po +137 -14
- data/locale/pt_BR/katello.po +138 -15
- data/locale/ru/katello.po +138 -15
- data/locale/ta/katello.po +137 -14
- data/locale/te/katello.po +137 -14
- data/locale/zh_CN/katello.po +138 -15
- data/locale/zh_TW/katello.po +138 -15
- data/package.json +8 -25
- data/webpack/__mocks__/foremanReact/Root/Context/ForemanContext.js +3 -0
- data/webpack/components/ActionableDetail.js +63 -0
- data/webpack/components/Content/ContentTable.js +2 -2
- data/webpack/components/Content/Details/ContentDetailRepositoryTableSchema.js +1 -1
- data/webpack/components/Content/Details/ContentDetails.js +1 -1
- data/webpack/components/Content/__tests__/ContentTable.test.js +2 -2
- data/webpack/components/Content/__tests__/__snapshots__/ContentPage.test.js.snap +1 -1
- data/webpack/components/EditableSwitch.js +30 -0
- data/webpack/components/EditableTextInput/EditableTextInput.js +120 -0
- data/webpack/components/EditableTextInput/__tests__/editableTextInput.test.js +52 -0
- data/webpack/components/EditableTextInput/editableTextInput.scss +14 -0
- data/webpack/components/EditableTextInput/index.js +3 -0
- data/webpack/{scenes/ContentViews/components → components}/Loading.js +8 -5
- data/webpack/{move_to_pf → components}/LoadingState/LoadingState.js +0 -0
- data/webpack/{move_to_pf → components}/LoadingState/LoadingState.scss +0 -0
- data/webpack/{move_to_pf → components}/LoadingState/LoadingState.test.js +0 -0
- data/webpack/{move_to_pf → components}/LoadingState/__snapshots__/LoadingState.test.js.snap +0 -0
- data/webpack/{move_to_pf → components}/LoadingState/index.js +0 -0
- data/webpack/components/MultiSelect/index.js +1 -1
- data/webpack/{move_to_pf → components}/OptionTooltip/OptionTooltip.scss +0 -0
- data/webpack/{move_to_pf → components}/OptionTooltip/__tests__/OptionTooltip.test.js +0 -0
- data/webpack/{move_to_pf → components}/OptionTooltip/__tests__/__snapshots__/OptionTooltip.test.js.snap +0 -0
- data/webpack/{move_to_pf → components}/OptionTooltip/index.js +0 -0
- data/webpack/components/Search/Search.js +124 -0
- data/webpack/components/Search/Search.test.js +2 -1
- data/webpack/components/Search/__snapshots__/Search.test.js.snap +2 -0
- data/webpack/components/Search/__tests__/search.test.js +124 -0
- data/webpack/components/Search/index.js +11 -87
- data/webpack/{move_to_pf → components}/Select/Select.js +0 -0
- data/webpack/components/SelectOrg/SetOrganization.js +2 -2
- data/webpack/components/TabWrapper/TabWrapper.js +26 -0
- data/webpack/components/TabWrapper/index.js +3 -0
- data/webpack/components/TabbedView/TabbedView.js +38 -0
- data/webpack/components/TabbedView/TabbedView.scss +3 -0
- data/webpack/components/TabbedView/index.js +3 -0
- data/webpack/components/Table/EmptyStateMessage.js +61 -0
- data/webpack/{scenes/ContentViews/Table/TableWrapper.js → components/Table/MainTable.js} +23 -12
- data/webpack/components/Table/TableWrapper.js +94 -0
- data/webpack/{move_to_pf → components}/TooltipButton/TooltipButton.js +0 -0
- data/webpack/{move_to_pf → components}/TooltipButton/TooltipButton.scss +0 -0
- data/webpack/{move_to_pf → components}/TooltipButton/TooltipButton.test.js +0 -0
- data/webpack/{move_to_pf → components}/TooltipButton/__snapshots__/TooltipButton.test.js.snap +0 -0
- data/webpack/{move_to_pf → components}/TooltipButton/index.js +0 -0
- data/webpack/components/TypeAhead/TypeAhead.js +109 -0
- data/webpack/{move_to_pf → components}/TypeAhead/TypeAhead.scss +0 -0
- data/webpack/components/TypeAhead/helpers/commonPropTypes.js +35 -0
- data/webpack/components/TypeAhead/helpers/helpers.js +32 -0
- data/webpack/components/TypeAhead/index.js +3 -0
- data/webpack/{move_to_pf/TypeAhead → components/TypeAhead/pf3Search}/TypeAheadInput.js +3 -6
- data/webpack/{move_to_pf/TypeAhead → components/TypeAhead/pf3Search}/TypeAheadItems.js +3 -7
- data/webpack/components/TypeAhead/pf3Search/TypeAheadSearch.js +52 -0
- data/webpack/components/TypeAhead/pf4Search/TypeAheadInput.js +44 -0
- data/webpack/components/TypeAhead/pf4Search/TypeAheadInput.scss +11 -0
- data/webpack/components/TypeAhead/pf4Search/TypeAheadItems.js +57 -0
- data/webpack/components/TypeAhead/pf4Search/TypeAheadSearch.js +66 -0
- data/webpack/components/TypeAhead/pf4Search/TypeAheadSearch.scss +5 -0
- data/webpack/components/extensions/about/__tests__/SystemStatuses.test.js +1 -1
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/components/CollapseSubscriptionGroupButton.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/components/CollapseSubscriptionGroupButton.test.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/components/Table.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/components/Table.test.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/components/TableBody.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/components/TableBody.test.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/components/TableBodyMessage.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/components/TableBodyMessage.test.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/components/TableFixtures.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/components/TableSelectionCell.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/components/TableSelectionCell.test.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/components/TableSelectionHeaderCell.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/components/TableSelectionHeaderCell.test.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/components/__snapshots__/CollapseSubscriptionGroupButton.test.js.snap +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/components/__snapshots__/Table.test.js.snap +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/components/__snapshots__/TableBody.test.js.snap +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/components/__snapshots__/TableBodyMessage.test.js.snap +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/components/__snapshots__/TableSelectionCell.test.js.snap +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/components/__snapshots__/TableSelectionHeaderCell.test.js.snap +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/components/index.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/formatters/EntitlementsInlineEditFormatter.js +1 -1
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/formatters/__tests__/EntitlementsInlineEditFormatter.test.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/formatters/__tests__/__snapshots__/EntitlementsInlineEditFormatter.test.js.snap +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/formatters/cellFormatter.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/formatters/collapseableAndSelectionCellFormatter.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/formatters/ellipsisCellFormatter.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/formatters/headerFormatter.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/formatters/index.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/formatters/selectionCellFormatter.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/formatters/selectionHeaderCellFormatter.js +0 -0
- data/webpack/{move_to_foreman/components/common/table → components/pf3Table}/index.js +0 -0
- data/webpack/{move_to_pf → components}/react-bootstrap-select/index.js +0 -0
- data/webpack/containers/Application/config.js +9 -4
- data/webpack/containers/Application/overrides.scss +5 -0
- data/webpack/global_test_setup.js +3 -1
- data/webpack/redux/OrganizationProducts/OrganizationProductsActions.js +1 -1
- data/webpack/redux/OrganizationProducts/__tests__/OrganizationProductsActions.test.js +2 -2
- data/webpack/redux/actions/RedHatRepositories/enabled.js +1 -1
- data/webpack/redux/actions/RedHatRepositories/helpers.js +6 -6
- data/webpack/redux/actions/RedHatRepositories/repositorySetRepositories.js +1 -1
- data/webpack/redux/reducers/index.js +2 -0
- data/webpack/scenes/AnsibleCollections/AnsibleCollectionsActions.js +1 -1
- data/webpack/scenes/AnsibleCollections/AnsibleCollectionsTableSchema.js +1 -1
- data/webpack/scenes/AnsibleCollections/Details/AnsibleCollectionDetailsActions.js +1 -1
- data/webpack/scenes/AnsibleCollections/Details/__tests__/AnsibleCollectionDetailsActions.test.js +2 -2
- data/webpack/scenes/AnsibleCollections/__tests__/AnsibleCollectionsTable.test.js +1 -1
- data/webpack/scenes/ContentViews/ContentViewSelectors.js +1 -2
- data/webpack/scenes/ContentViews/ContentViewsActions.js +4 -4
- data/webpack/scenes/ContentViews/ContentViewsConstants.js +4 -1
- data/webpack/scenes/ContentViews/ContentViewsPage.js +12 -6
- data/webpack/scenes/ContentViews/Details/ContentViewDetailActions.js +44 -0
- data/webpack/scenes/ContentViews/Details/ContentViewDetailReducer.js +23 -0
- data/webpack/scenes/ContentViews/{details → Details}/ContentViewDetailSelectors.js +3 -0
- data/webpack/scenes/ContentViews/Details/ContentViewDetails.js +70 -0
- data/webpack/scenes/ContentViews/Details/ContentViewInfo.js +116 -0
- data/webpack/scenes/ContentViews/{details → Details}/DetailsContainer.js +8 -4
- data/webpack/scenes/ContentViews/Details/__tests__/contentViewDetail.test.js +101 -0
- data/webpack/scenes/ContentViews/Details/__tests__/contentViewDetails.fixtures.json +106 -0
- data/webpack/scenes/ContentViews/Details/contentViewInfo.scss +8 -0
- data/webpack/scenes/ContentViews/Details/index.js +7 -0
- data/webpack/scenes/ContentViews/Table/ContentViewsTable.js +51 -36
- data/webpack/scenes/ContentViews/Table/tableDataGenerator.js +47 -44
- data/webpack/scenes/ContentViews/__tests__/basicContentViews.fixtures.js +31 -0
- data/webpack/scenes/ContentViews/__tests__/contentViewList.fixtures.json +2 -1
- data/webpack/scenes/ContentViews/__tests__/contentViewPage.test.js +173 -23
- data/webpack/scenes/ContentViews/components/ContentViewIcon.js +26 -0
- data/webpack/scenes/ContentViews/components/{contentViewName.scss → contentViewIcon.scss} +0 -0
- data/webpack/scenes/ModuleStreams/Details/ModuleStreamDetailsActions.js +1 -1
- data/webpack/scenes/ModuleStreams/Details/Profiles/TableSchema.js +1 -1
- data/webpack/scenes/ModuleStreams/Details/__tests__/ModuleStreamDetailsActions.test.js +2 -2
- data/webpack/scenes/ModuleStreams/ModuleStreamsActions.js +1 -1
- data/webpack/scenes/ModuleStreams/ModuleStreamsTableSchema.js +1 -1
- data/webpack/scenes/ModuleStreams/__tests__/ModuleStreamsTable.test.js +1 -1
- data/webpack/scenes/Organizations/OrganizationSelectors.js +14 -0
- data/webpack/scenes/Products/ProductActions.js +1 -1
- data/webpack/scenes/RedHatRepositories/RedHatRepositoriesPage.js +1 -1
- data/webpack/scenes/Settings/SettingsConstants.js +3 -0
- data/webpack/scenes/Settings/SettingsReducer.js +33 -0
- data/webpack/scenes/Settings/SettingsSelectors.js +4 -0
- data/webpack/scenes/Settings/index.js +2 -1
- data/webpack/scenes/Subscriptions/Details/SubscriptionDetailActions.js +1 -1
- data/webpack/scenes/Subscriptions/Details/SubscriptionDetails.js +1 -1
- data/webpack/scenes/Subscriptions/Manifest/ManageManifestModal.js +67 -91
- data/webpack/scenes/Subscriptions/Manifest/ManageManifestModal.scss +15 -0
- data/webpack/scenes/Subscriptions/Manifest/ManifestActions.js +43 -1
- data/webpack/scenes/Subscriptions/Manifest/ManifestConstants.js +8 -0
- data/webpack/scenes/Subscriptions/Manifest/ManifestHistoryTableSchema.js +1 -1
- data/webpack/scenes/Subscriptions/Manifest/SimpleContentAccess.js +78 -0
- data/webpack/scenes/Subscriptions/Manifest/__tests__/ManageManifestModal.test.js +2 -0
- data/webpack/scenes/Subscriptions/Manifest/__tests__/ManifestActions.test.js +56 -1
- data/webpack/scenes/Subscriptions/Manifest/__tests__/SimpleContentAccess.test.js +100 -0
- data/webpack/scenes/Subscriptions/Manifest/__tests__/__snapshots__/ManageManifestModal.test.js.snap +6 -6
- data/webpack/scenes/Subscriptions/Manifest/__tests__/manifest.fixtures.js +36 -0
- data/webpack/scenes/Subscriptions/Manifest/index.js +4 -5
- data/webpack/scenes/Subscriptions/SubscriptionActions.js +1 -1
- data/webpack/scenes/Subscriptions/SubscriptionConstants.js +4 -0
- data/webpack/scenes/Subscriptions/SubscriptionHelpers.js +0 -3
- data/webpack/scenes/Subscriptions/SubscriptionReducer.js +48 -12
- data/webpack/scenes/Subscriptions/SubscriptionsPage.js +29 -18
- data/webpack/scenes/Subscriptions/SubscriptionsSelectors.js +2 -2
- data/webpack/scenes/Subscriptions/UpstreamSubscriptions/UpstreamSubscriptionsActions.js +1 -1
- data/webpack/scenes/Subscriptions/UpstreamSubscriptions/UpstreamSubscriptionsPage.js +2 -2
- data/webpack/scenes/Subscriptions/UpstreamSubscriptions/UpstreamSubscriptionsTableSchema.js +1 -1
- data/webpack/scenes/Subscriptions/__tests__/SubscriptionHelpers.test.js +0 -11
- data/webpack/scenes/Subscriptions/__tests__/SubscriptionsReducer.test.js +24 -0
- data/webpack/scenes/Subscriptions/__tests__/__snapshots__/SubscriptionsActions.test.js.snap +2 -2
- data/webpack/scenes/Subscriptions/__tests__/__snapshots__/SubscriptionsPage.test.js.snap +4 -4
- data/webpack/scenes/Subscriptions/__tests__/__snapshots__/SubscriptionsReducer.test.js.snap +114 -1
- data/webpack/scenes/Subscriptions/components/SubscriptionsTable/SubscriptionTypeFormatter.js +2 -2
- data/webpack/scenes/Subscriptions/components/SubscriptionsTable/SubscriptionsTable.js +27 -21
- data/webpack/scenes/Subscriptions/components/SubscriptionsTable/SubscriptionsTableHelpers.js +6 -2
- data/webpack/scenes/Subscriptions/components/SubscriptionsTable/SubscriptionsTableSchema.js +2 -2
- data/webpack/scenes/Subscriptions/components/SubscriptionsTable/__tests__/__snapshots__/SubscriptionTypeFormatter.test.js.snap +3 -3
- data/webpack/scenes/Subscriptions/components/SubscriptionsTable/components/Table.js +1 -1
- data/webpack/scenes/Subscriptions/components/SubscriptionsToolbar/SubscriptionsToolbar.js +28 -3
- data/webpack/scenes/Subscriptions/components/SubscriptionsToolbar/__snapshots__/SubscriptionsToolbar.test.js.snap +5 -10
- data/webpack/scenes/Subscriptions/index.js +6 -2
- data/webpack/test-utils/nockWrapper.js +39 -5
- data/webpack/test-utils/react-testing-lib-wrapper.js +35 -9
- data/webpack/{move_to_foreman/common → utils}/helpers.js +12 -8
- data/webpack/utils/useEventListener.js +37 -0
- metadata +215 -101
- data/app/lib/actions/katello/repository/update_cv_repo_cert_guard.rb +0 -17
- data/vendor/assets/stylesheets/katello/jquery.loadmask.css.scss +0 -40
- data/vendor/assets/stylesheets/katello/ui.spinner.css.scss +0 -3
- data/webpack/__mocks__/foremanReact/components/ForemanModal/ForemanModalActions.js +0 -2
- data/webpack/__mocks__/foremanReact/components/ForemanModal/ForemanModalSelectors.js +0 -2
- data/webpack/__mocks__/foremanReact/components/ForemanModal/index.js +0 -4
- data/webpack/__mocks__/foremanReact/components/Settings/SettingsActions.js +0 -4
- data/webpack/__mocks__/foremanReact/components/Settings/SettingsConstants.js +0 -2
- data/webpack/move_to_pf/TypeAhead/TypeAhead.js +0 -138
- data/webpack/move_to_pf/TypeAhead/helpers.js +0 -5
- data/webpack/scenes/ContentViews/components/ContentViewName.js +0 -33
- data/webpack/scenes/ContentViews/components/EmptyStateMessage.js +0 -43
- data/webpack/scenes/ContentViews/details/ContentViewDetailActions.js +0 -12
- data/webpack/scenes/ContentViews/expansions/RepositoriesExpansion.js +0 -12
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3c7f446fd8f4d3af288f0bbbf1f5b56bdac0f903d0c55fc332221d2cf2830384
|
4
|
+
data.tar.gz: 621fc49c5e82b6698a805c7a9b29143bad8b4b17690b94cd6cae3a65de1f33d9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e88e27186ae85ae6787743e2295b1076e9b6af862a531fc6aec29de59c18a378aa377725b0f7687594fcb8e9d891e6dc3d19e03f26aed3f1e9009eb03c03877d
|
7
|
+
data.tar.gz: 71d88ce6981546419a0f01f22a634727fdf36e11d164b69366aeabf00eb8ac1490935123c66e0733896ffc158b68b62d61817e4f03329f29cf6873fd1075da58
|
@@ -1,10 +1,3 @@
|
|
1
|
-
/**
|
2
|
-
* = require "katello/jquery.loadmask.css"
|
3
|
-
* = require "katello/jquery-ui-1.8.11.custom.css"
|
4
|
-
* = require "katello/jquery.treeTable.css"
|
5
|
-
* = require "katello/ui.spinner.css"
|
6
|
-
*/
|
7
|
-
|
8
1
|
@import "katello/overrides";
|
9
2
|
@import "katello/katello_base";
|
10
3
|
@import "katello/look";
|
@@ -18,6 +11,9 @@
|
|
18
11
|
@import "katello/generic";
|
19
12
|
@import "katello/notifications";
|
20
13
|
|
14
|
+
@import "katello/jquery.treeTable";
|
15
|
+
@import "katello/jquery-ui-1.8.11.custom.css";
|
16
|
+
|
21
17
|
body {
|
22
18
|
background-color: white;
|
23
19
|
}
|
@@ -6,12 +6,12 @@ module Katello
|
|
6
6
|
before_action :confirm_push_settings, only: [:start_upload_blob, :upload_blob, :finish_upload_blob,
|
7
7
|
:chunk_upload_blob, :push_manifest]
|
8
8
|
skip_before_action :authorize
|
9
|
-
before_action :optional_authorize, only: [:token]
|
10
|
-
before_action :registry_authorize, except: [:token, :v1_search]
|
9
|
+
before_action :optional_authorize, only: [:token, :catalog]
|
10
|
+
before_action :registry_authorize, except: [:token, :v1_search, :catalog]
|
11
11
|
before_action :authorize_repository_read, only: [:pull_manifest, :tags_list]
|
12
12
|
before_action :authorize_repository_write, only: [:push_manifest]
|
13
|
-
skip_before_action :
|
14
|
-
|
13
|
+
skip_before_action :check_media_type, only: [:start_upload_blob, :upload_blob, :finish_upload_blob,
|
14
|
+
:chunk_upload_blob, :push_manifest]
|
15
15
|
|
16
16
|
wrap_parameters false
|
17
17
|
|
@@ -39,20 +39,7 @@ module Katello
|
|
39
39
|
"scope=\"repository:registry:pull,push\""
|
40
40
|
end
|
41
41
|
|
42
|
-
def
|
43
|
-
@repository = find_scope_repository
|
44
|
-
if @repository && (@repository.environment.registry_unauthenticated_pull || ssl_client_authorized?(@repository.organization.label))
|
45
|
-
true
|
46
|
-
else
|
47
|
-
authorize
|
48
|
-
end
|
49
|
-
end
|
50
|
-
|
51
|
-
def registry_authorize
|
52
|
-
@repository = find_readable_repository
|
53
|
-
return true if ['GET', 'HEAD'].include?(request.method) && @repository && !require_user_authorization?
|
54
|
-
|
55
|
-
token = request.headers['Authorization']
|
42
|
+
def set_user_by_token(token, redirect_on_failure = true)
|
56
43
|
if token
|
57
44
|
token_type, token = token.split
|
58
45
|
if token_type == 'Bearer' && token
|
@@ -63,10 +50,34 @@ module Katello
|
|
63
50
|
end
|
64
51
|
elsif token_type == 'Basic' && token
|
65
52
|
return true if authorize
|
66
|
-
redirect_authorization_headers
|
53
|
+
redirect_authorization_headers if redirect_on_failure
|
67
54
|
return false
|
68
55
|
end
|
69
56
|
end
|
57
|
+
false
|
58
|
+
end
|
59
|
+
|
60
|
+
def optional_authorize
|
61
|
+
@repository = find_scope_repository
|
62
|
+
if @repository && (@repository.environment.registry_unauthenticated_pull || ssl_client_authorized?(@repository.organization.label))
|
63
|
+
true
|
64
|
+
elsif params['action'] == 'catalog'
|
65
|
+
set_user_by_token(request.headers['Authorization'], false)
|
66
|
+
elsif (params['action'] == 'token' && params['scope'].blank? && params['account'].blank?)
|
67
|
+
true
|
68
|
+
else
|
69
|
+
authorize
|
70
|
+
end
|
71
|
+
end
|
72
|
+
|
73
|
+
def registry_authorize
|
74
|
+
@repository = find_readable_repository
|
75
|
+
return true if ['GET', 'HEAD'].include?(request.method) && @repository && !require_user_authorization?
|
76
|
+
|
77
|
+
is_user_set = set_user_by_token(request.headers['Authorization'])
|
78
|
+
|
79
|
+
return true if is_user_set
|
80
|
+
|
70
81
|
redirect_authorization_headers
|
71
82
|
render_error('unauthorized', :status => :unauthorized)
|
72
83
|
return false
|
@@ -87,12 +98,8 @@ module Katello
|
|
87
98
|
# Also include repositories in lifecycle environments with registry_unauthenticated_pull=true
|
88
99
|
def readable_repositories
|
89
100
|
table_name = Repository.table_name
|
90
|
-
in_products = Repository.in_product(Katello::Product.authorized(:view_products)).select(:id)
|
91
|
-
in_environments = Repository.where(:environment_id => Katello::KTEnvironment.authorized(:view_lifecycle_environments)).select(:id)
|
92
101
|
in_unauth_environments = Repository.joins(:environment).where("#{Katello::KTEnvironment.table_name}.registry_unauthenticated_pull" => true).select(:id)
|
93
|
-
|
94
|
-
in_versions = Repository.joins(:content_view_version).where("#{Katello::ContentViewVersion.table_name}.content_view_id" => Katello::ContentView.readable).select(:id)
|
95
|
-
Repository.where("#{table_name}.id in (?) or #{table_name}.id in (?) or #{table_name}.id in (?) or #{table_name}.id in (?) or #{table_name}.id in (?)", in_products, in_content_views, in_versions, in_environments, in_unauth_environments)
|
102
|
+
Repository.readable.or(Repository.joins(:root).where("#{table_name}.id in (?)", in_unauth_environments))
|
96
103
|
end
|
97
104
|
|
98
105
|
def find_readable_repository
|
@@ -105,7 +112,8 @@ module Katello
|
|
105
112
|
end
|
106
113
|
|
107
114
|
def require_user_authorization?(repository = @repository)
|
108
|
-
!
|
115
|
+
!(params['action'] == 'token' && params['scope'].blank? && params['account'].blank?) &&
|
116
|
+
(!repository || (!repository.environment.registry_unauthenticated_pull && !ssl_client_authorized?(repository.organization.label)))
|
109
117
|
end
|
110
118
|
|
111
119
|
def ssl_client_authorized?(org_label)
|
@@ -192,7 +200,9 @@ module Katello
|
|
192
200
|
end
|
193
201
|
|
194
202
|
def pull_blob
|
195
|
-
|
203
|
+
headers = {}
|
204
|
+
headers['Accept'] = request.headers['Accept'] if request.headers['Accept']
|
205
|
+
r = Resources::Registry::Proxy.get(@_request.fullpath, headers)
|
196
206
|
render json: r
|
197
207
|
end
|
198
208
|
|
@@ -293,6 +303,14 @@ module Katello
|
|
293
303
|
end
|
294
304
|
|
295
305
|
def v1_search
|
306
|
+
# Checks for podman client and issues a 404 in that case. Podman
|
307
|
+
# examines the response from a /v1_search request. If the result
|
308
|
+
# is a 4XX, it will then proceed with a request to /_catalog
|
309
|
+
if request.headers['HTTP_USER_AGENT'].downcase.include?('libpod')
|
310
|
+
render json: {}, status: :not_found
|
311
|
+
return
|
312
|
+
end
|
313
|
+
|
296
314
|
authenticate # to set current_user, not to enforce
|
297
315
|
options = {
|
298
316
|
resource_class: Katello::Repository
|
@@ -10,7 +10,7 @@ module Katello
|
|
10
10
|
before_action :find_host, :only => [:upload_package_profile, :upload_profiles, :deb_package_profile]
|
11
11
|
before_action :authorize_client_or_user, :only => [:upload_package_profile, :upload_profiles, :deb_package_profile]
|
12
12
|
|
13
|
-
skip_before_action :
|
13
|
+
skip_before_action :check_media_type
|
14
14
|
|
15
15
|
#api :PUT, "/consumers/:id/packages", N_("Update installed packages")
|
16
16
|
#api :PUT, "/consumers/:id/profile", N_("Update installed packages")
|
@@ -26,7 +26,7 @@ module Katello
|
|
26
26
|
before_action :set_organization_id, :except => [:hypervisors_update, :async_hypervisors_update]
|
27
27
|
before_action :find_hypervisor_organization, :only => [:async_hypervisors_update, :hypervisors_update]
|
28
28
|
|
29
|
-
before_action :
|
29
|
+
before_action :check_media_type, :except => :async_hypervisors_update
|
30
30
|
|
31
31
|
prepend_before_action :convert_owner_to_organization_id, :except => [:hypervisors_update, :async_hypervisors_update], :if => lambda { params.key?(:owner) }
|
32
32
|
prepend_before_action :convert_organization_label_to_id, :only => [:rhsm_index, :consumer_activate, :consumer_create], :if => lambda { params.key?(:organization_id) }
|
@@ -480,7 +480,7 @@ module Katello
|
|
480
480
|
else
|
481
481
|
User.consumer? || ::User.current.can?(:view_organizations, self)
|
482
482
|
end
|
483
|
-
when "rhsm_proxy_owner_servicelevels_path"
|
483
|
+
when "rhsm_proxy_owner_servicelevels_path", "rhsm_proxy_owner_system_purpose_path"
|
484
484
|
(User.consumer? || ::User.current.can?(:view_organizations, self))
|
485
485
|
when "rhsm_proxy_consumer_accessible_content_path", "rhsm_proxy_consumer_certificates_path",
|
486
486
|
"rhsm_proxy_consumer_releases_path", "rhsm_proxy_certificate_serials_path",
|
@@ -1,4 +1,5 @@
|
|
1
1
|
module Katello
|
2
|
+
# rubocop:disable Metrics/ClassLength
|
2
3
|
class Api::V2::ActivationKeysController < Api::V2::ApiController
|
3
4
|
include Katello::Concerns::FilteredAutoCompleteSearch
|
4
5
|
include Katello::Concerns::Api::V2::ContentOverridesController
|
@@ -11,6 +12,7 @@ module Katello
|
|
11
12
|
:content_override, :add_subscriptions, :remove_subscriptions,
|
12
13
|
:subscriptions]
|
13
14
|
before_action :authorize
|
15
|
+
before_action :verify_simple_content_access_disabled, :only => [:add_subscriptions]
|
14
16
|
|
15
17
|
wrap_parameters :include => (ActivationKey.attribute_names + %w(host_collection_ids service_level auto_attach purpose_role purpose_usage purpose_addons content_view_environment))
|
16
18
|
|
@@ -348,5 +350,11 @@ module Katello
|
|
348
350
|
|
349
351
|
key_params
|
350
352
|
end
|
353
|
+
|
354
|
+
def verify_simple_content_access_disabled
|
355
|
+
if @activation_key.organization.simple_content_access?
|
356
|
+
fail HttpErrors::BadRequest, _("The specified organization is in Simple Content Access mode. Attaching subscriptions is disabled")
|
357
|
+
end
|
358
|
+
end
|
351
359
|
end
|
352
360
|
end
|
@@ -5,7 +5,7 @@ module Katello
|
|
5
5
|
include Api::V2::Rendering
|
6
6
|
include Api::V2::ErrorHandling
|
7
7
|
include ::Foreman::Controller::CsvResponder
|
8
|
-
include Concerns::Api::V2::
|
8
|
+
include Concerns::Api::V2::Authorization
|
9
9
|
|
10
10
|
# support for session (thread-local) variables must be the last filter in this class
|
11
11
|
include Foreman::ThreadSession::Cleaner
|
@@ -4,7 +4,7 @@ module Katello
|
|
4
4
|
before_action :authorize
|
5
5
|
before_action :find_organization, :only => [:create, :index, :auto_complete_search]
|
6
6
|
before_action :find_content_credential, :only => [:show, :update, :destroy, :content, :set_content]
|
7
|
-
skip_before_action :
|
7
|
+
skip_before_action :check_media_type, :only => [:create, :content, :set_content]
|
8
8
|
|
9
9
|
def resource_class
|
10
10
|
Katello::GpgKey
|
@@ -1,7 +1,7 @@
|
|
1
1
|
module Katello
|
2
2
|
class Api::V2::ContentUploadsController < Api::V2::ApiController
|
3
3
|
before_action :find_repository
|
4
|
-
skip_before_action :
|
4
|
+
skip_before_action :check_media_type, :only => [:update]
|
5
5
|
|
6
6
|
include ::Foreman::Controller::FilterParameters
|
7
7
|
filter_parameters :content
|
@@ -13,8 +13,8 @@ module Katello
|
|
13
13
|
param :content_type, RepositoryTypeManager.uploadable_content_types.map(&:label), :required => false, :desc => N_("content type ('deb', 'docker_manifest', 'file', 'ostree', 'puppet_module', 'rpm', 'srpm')")
|
14
14
|
def create
|
15
15
|
content_type = params[:content_type] || ::Katello::RepositoryTypeManager.find(@repository.content_type).default_managed_content_type.label
|
16
|
-
unit_type_id = SmartProxy.
|
17
|
-
render :json => @repository.backend_content_service(::SmartProxy.
|
16
|
+
unit_type_id = SmartProxy.pulp_primary.content_service(content_type).content_type
|
17
|
+
render :json => @repository.backend_content_service(::SmartProxy.pulp_primary).create_upload(params[:size], params[:checksum], unit_type_id)
|
18
18
|
end
|
19
19
|
|
20
20
|
api :PUT, "/repositories/:repository_id/content_uploads/:id", N_("Upload a chunk of the file's content")
|
@@ -24,7 +24,7 @@ module Katello
|
|
24
24
|
param :offset, :number, :required => true, :desc => N_("The offset in the file where the content starts")
|
25
25
|
param :content, File, :required => true, :desc => N_("The actual file contents")
|
26
26
|
def update
|
27
|
-
@repository.backend_content_service(::SmartProxy.
|
27
|
+
@repository.backend_content_service(::SmartProxy.pulp_primary)
|
28
28
|
.upload_chunk(params[:id], params[:offset], params[:content], params[:size])
|
29
29
|
head :no_content
|
30
30
|
end
|
@@ -33,7 +33,7 @@ module Katello
|
|
33
33
|
param :repository_id, :number, :required => true, :desc => N_("Repository id")
|
34
34
|
param :id, String, :required => true, :desc => N_("Upload request id")
|
35
35
|
def destroy
|
36
|
-
@repository.backend_content_service(::SmartProxy.
|
36
|
+
@repository.backend_content_service(::SmartProxy.pulp_primary).delete_upload(params[:id])
|
37
37
|
head :no_content
|
38
38
|
end
|
39
39
|
|
@@ -37,6 +37,8 @@ module Katello
|
|
37
37
|
param :type, String, :desc => N_("type of filter (e.g. rpm, package_group, erratum, docker, modulemd)"), :required => true
|
38
38
|
param :original_packages, :bool, :desc => N_("add all packages without errata to the included/excluded list. " \
|
39
39
|
"(package filter only)")
|
40
|
+
param :original_module_streams, :bool, :desc => N_("add all module streams without errata to the included/excluded list. " \
|
41
|
+
"(module stream filter only)")
|
40
42
|
param :inclusion, :bool, :desc => N_("specifies if content should be included or excluded, default: inclusion=false")
|
41
43
|
param :repository_ids, Array, :desc => N_("list of repository ids")
|
42
44
|
param :description, String, :desc => N_("description of the filter")
|
@@ -60,6 +62,8 @@ module Katello
|
|
60
62
|
param :name, String, :desc => N_("new name for the filter")
|
61
63
|
param :original_packages, :bool, :desc => N_("add all packages without errata to the included/excluded list. " \
|
62
64
|
"(package filter only)")
|
65
|
+
param :original_module_streams, :bool, :desc => N_("add all module streams without errata to the included/excluded list. " \
|
66
|
+
"(module stream filter only)")
|
63
67
|
param :inclusion, :bool, :desc => N_("specifies if content should be included or excluded, default: inclusion=false")
|
64
68
|
param :repository_ids, Array, :desc => N_("list of repository ids")
|
65
69
|
param :description, String, :desc => N_("description of the filter"), :required => false
|
@@ -95,7 +99,7 @@ module Katello
|
|
95
99
|
end
|
96
100
|
|
97
101
|
def filter_params
|
98
|
-
params.require(:content_view_filter).permit(:name, :inclusion, :original_packages, :description, :repository_ids => [])
|
102
|
+
params.require(:content_view_filter).permit(:name, :inclusion, :original_packages, :original_module_streams, :description, :repository_ids => [])
|
99
103
|
end
|
100
104
|
end
|
101
105
|
end
|
@@ -0,0 +1,47 @@
|
|
1
|
+
module Katello
|
2
|
+
class Api::V2::ContentViewRepositoriesController < Api::V2::ApiController
|
3
|
+
# There are other Content View Repository related endpoints that are in RepositoriesController
|
4
|
+
include Katello::Concerns::FilteredAutoCompleteSearch
|
5
|
+
|
6
|
+
before_action :find_content_view
|
7
|
+
before_action :find_organization_from_cv
|
8
|
+
|
9
|
+
# content_views/:id/repositories/show_all
|
10
|
+
# Shows all repositories, added and available to add, for a content view
|
11
|
+
# Undocumented endpoint since the functionality exists in separate calls already.
|
12
|
+
# This was created for ease of pagination and search for the UI
|
13
|
+
param :id, :number, desc: N_("Content View id"), required: true
|
14
|
+
def show_all
|
15
|
+
kr = Katello::Repository.table_name
|
16
|
+
krr = Katello::RootRepository.table_name
|
17
|
+
kcvr = Katello::ContentViewRepository.table_name
|
18
|
+
join_query = <<-SQL
|
19
|
+
LEFT OUTER JOIN #{kcvr}
|
20
|
+
ON #{kr}.id = #{kcvr}.repository_id
|
21
|
+
AND #{kcvr}.content_view_id = #{@content_view.id}
|
22
|
+
SQL
|
23
|
+
order_query = <<-SQL
|
24
|
+
CAST (#{kcvr}.repository_id as BOOLEAN) ASC, #{krr}.name
|
25
|
+
SQL
|
26
|
+
|
27
|
+
query = Katello::Repository.readable.in_default_view.in_organization(@organization)
|
28
|
+
# Use custom sort to perform the join and order since we need to order by specific content_view
|
29
|
+
# and the ORDER BY query needs access to the katello_content_view_repositories table
|
30
|
+
custom_sort = ->(sort_query) { sort_query.joins(:root).joins(join_query).order(order_query) }
|
31
|
+
options = { resource_class: Katello::Repository, custom_sort: custom_sort }
|
32
|
+
repos = scoped_search(query, nil, nil, options)
|
33
|
+
|
34
|
+
respond_for_index(:collection => repos)
|
35
|
+
end
|
36
|
+
|
37
|
+
private
|
38
|
+
|
39
|
+
def find_content_view
|
40
|
+
@content_view = ContentView.find(params[:content_view_id])
|
41
|
+
end
|
42
|
+
|
43
|
+
def find_organization_from_cv
|
44
|
+
@organization = @content_view.organization
|
45
|
+
end
|
46
|
+
end
|
47
|
+
end
|
@@ -82,33 +82,64 @@ module Katello
|
|
82
82
|
respond_for_async :resource => task
|
83
83
|
end
|
84
84
|
|
85
|
+
api :GET, "/content_view_versions/export_histories", N_("Show the export history for a content view version")
|
86
|
+
param :content_view_version_id, :number, :desc => N_("Content view version identifier"), :required => false
|
87
|
+
param :content_view_id, :number, :desc => N_("Content view identifier"), :required => false
|
88
|
+
param :destination_server, String, :desc => N_("Destination Server name"), :required => false
|
89
|
+
param :organization_id, :number, :desc => N_("Organization identifier"), :required => false
|
90
|
+
param_group :search, Api::V2::ApiController
|
91
|
+
add_scoped_search_description_for(ContentViewVersionExportHistory)
|
92
|
+
def export_histories
|
93
|
+
history = ContentViewVersionExportHistory.readable
|
94
|
+
history = history.where(:content_view_version_id => params[:content_view_version_id]) unless params[:content_view_version_id].blank?
|
95
|
+
history = history.where(:destination_server => params[:destination_server]) unless params[:destination_server].blank?
|
96
|
+
history = history.with_organization_id(params[:organization_id]) unless params[:organization_id].blank?
|
97
|
+
history = history.with_content_view_id(params[:content_view_id]) unless params[:content_view_id].blank?
|
98
|
+
respond_for_index(:collection => scoped_search(history, 'id', 'asc', resource_class: ContentViewVersionExportHistory),
|
99
|
+
:template => '../../../api/v2/content_view_version_export_histories/index')
|
100
|
+
end
|
101
|
+
|
85
102
|
api :POST, "/content_view_versions/:id/export", N_("Export a content view version"), :deprecated => true
|
86
103
|
param :id, :number, :desc => N_("Content view version identifier"), :required => true
|
87
|
-
param :
|
88
|
-
param :
|
89
|
-
param :
|
104
|
+
param :destination_server, String, :desc => N_("Destination Server name, required for Pulp3")
|
105
|
+
param :export_to_iso, :bool, :desc => N_("Export to ISO format. Relevant only for Pulp 2 repositories"), :required => false
|
106
|
+
param :iso_mb_size, :number, :desc => N_("maximum size of each ISO in MB. Relevant only for Pulp 2 repositories"), :required => false
|
107
|
+
param :since, Date, :desc => N_("Optional date of last export (ex: 2010-01-01T12:00:00Z). Relevant only for Pulp 2 repositories"), :required => false
|
90
108
|
def export
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
109
|
+
if SmartProxy.pulp_primary.pulp3_repository_type_support?(Katello::Repository::YUM_TYPE)
|
110
|
+
invalid_params = [:export_to_iso, :iso_mb_size, :since].reject { |param| params[param].blank? }
|
111
|
+
unless invalid_params.empty?
|
112
|
+
fail HttpErrors::BadRequest, _("Invalid parameters provided - %{params}. These are only relevant for Pulp 2 repositories" % { params: invalid_params.join(', ')})
|
113
|
+
end
|
95
114
|
|
96
|
-
|
97
|
-
|
98
|
-
|
115
|
+
if params[:destination_server].blank?
|
116
|
+
fail HttpErrors::BadRequest, _("Destination Server Name required for Pulp3 repositories")
|
117
|
+
end
|
118
|
+
|
119
|
+
task = async_task(::Actions::Pulp3::Orchestration::ContentViewVersion::Export, @version, destination_server: params[:destination_server])
|
120
|
+
else
|
121
|
+
::Foreman::Deprecation.api_deprecation_warning("Export is being deprecated and will be removed in a future version of Katello. Use hammer content-view version export instead.")
|
122
|
+
if params[:export_to_iso].blank? && params[:iso_mb_size].present?
|
123
|
+
fail HttpErrors::BadRequest, _("ISO export must be enabled when specifying ISO size")
|
124
|
+
end
|
99
125
|
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
126
|
+
if (repos = @version.content_view.on_demand_repositories).any?
|
127
|
+
fail HttpErrors::BadRequest, _("This content view has on demand repositories that cannot be exported: %{repos}" % {repos: repos.pluck(:label).join(", ")})
|
128
|
+
end
|
129
|
+
|
130
|
+
if params[:since].present?
|
131
|
+
begin
|
132
|
+
params[:since].to_datetime
|
133
|
+
rescue
|
134
|
+
raise HttpErrors::BadRequest, _("Invalid date provided.")
|
135
|
+
end
|
105
136
|
end
|
137
|
+
task = async_task(::Actions::Katello::ContentViewVersion::Export, @version,
|
138
|
+
::Foreman::Cast.to_bool(params[:export_to_iso]),
|
139
|
+
params[:since].try(:to_datetime),
|
140
|
+
params[:iso_mb_size])
|
106
141
|
end
|
107
142
|
|
108
|
-
task = async_task(::Actions::Katello::ContentViewVersion::Export, @version,
|
109
|
-
::Foreman::Cast.to_bool(params[:export_to_iso]),
|
110
|
-
params[:since].try(:to_datetime),
|
111
|
-
params[:iso_mb_size])
|
112
143
|
respond_for_async :resource => task
|
113
144
|
end
|
114
145
|
|
@@ -5,7 +5,7 @@ module Katello
|
|
5
5
|
before_action :authorize
|
6
6
|
before_action :find_organization, :only => [:create, :index, :auto_complete_search]
|
7
7
|
before_action :find_gpg_key, :only => [:show, :update, :destroy, :content, :set_content]
|
8
|
-
skip_before_action :
|
8
|
+
skip_before_action :check_media_type, :only => [:create, :content, :set_content]
|
9
9
|
|
10
10
|
def_param_group :gpg_key do
|
11
11
|
param :name, :identifier, :action_aware => true, :required => true, :desc => N_("identifier of the gpg key")
|
@@ -39,7 +39,9 @@ module Katello
|
|
39
39
|
respond_for_index :collection => @collection
|
40
40
|
end
|
41
41
|
|
42
|
-
def index_response
|
42
|
+
def index_response(reload_host = false)
|
43
|
+
# Host needs to be reloaded because of lazy accessor
|
44
|
+
@host.reload if reload_host
|
43
45
|
entitlements = @host.subscription_facet.candlepin_consumer.entitlements
|
44
46
|
subscriptions = entitlements.map { |entitlement| ::Katello::HostSubscriptionPresenter.new(entitlement) }
|
45
47
|
full_result_response(subscriptions)
|
@@ -53,7 +55,7 @@ module Katello
|
|
53
55
|
end
|
54
56
|
|
55
57
|
sync_task(::Actions::Katello::Host::AutoAttachSubscriptions, @host)
|
56
|
-
respond_for_index(:collection => index_response, :template => "index")
|
58
|
+
respond_for_index(:collection => index_response(true), :template => "index")
|
57
59
|
end
|
58
60
|
|
59
61
|
api :DELETE, "/hosts/:host_id/subscriptions/", N_("Unregister the host as a subscription consumer")
|
@@ -124,7 +126,7 @@ module Katello
|
|
124
126
|
end
|
125
127
|
|
126
128
|
sync_task(::Actions::Katello::Host::RemoveSubscriptions, @host, pool_id_quantities.values)
|
127
|
-
respond_for_index(:collection => index_response, :template => "index")
|
129
|
+
respond_for_index(:collection => index_response(true), :template => "index")
|
128
130
|
end
|
129
131
|
|
130
132
|
api :PUT, "/hosts/:host_id/subscriptions/add_subscriptions", N_("Add a subscription to a host")
|
@@ -134,12 +136,16 @@ module Katello
|
|
134
136
|
param :quantity, :number, :desc => N_("Quantity of this subscriptions to add"), :required => true
|
135
137
|
end
|
136
138
|
def add_subscriptions
|
139
|
+
if @host.organization.simple_content_access?
|
140
|
+
fail ::Katello::HttpErrors::BadRequest, _("This host's organization is in Simple Content Access mode. Attaching subscriptions is disabled.")
|
141
|
+
end
|
142
|
+
|
137
143
|
pools_with_quantities = params.require(:subscriptions).map do |sub_params|
|
138
144
|
PoolWithQuantities.new(Pool.with_identifier(sub_params['id']), sub_params['quantity'].to_i)
|
139
145
|
end
|
140
146
|
|
141
147
|
sync_task(::Actions::Katello::Host::AttachSubscriptions, @host, pools_with_quantities)
|
142
|
-
respond_for_index(:collection => index_response, :template => "index")
|
148
|
+
respond_for_index(:collection => index_response(true), :template => "index")
|
143
149
|
end
|
144
150
|
|
145
151
|
api :PUT, "/hosts/:host_id/subscriptions/content_override", N_("Set content overrides for the host")
|