katello 4.7.0.rc2 → 4.7.0

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 (28) hide show
  1. checksums.yaml +4 -4
  2. data/app/controllers/katello/api/v2/products_bulk_actions_controller.rb +1 -1
  3. data/app/controllers/katello/api/v2/repositories_controller.rb +1 -1
  4. data/app/controllers/katello/api/v2/repository_sets_controller.rb +25 -14
  5. data/app/lib/actions/katello/repository/sync.rb +3 -3
  6. data/app/lib/actions/pulp3/orchestration/repository/copy_all_units.rb +1 -0
  7. data/app/lib/katello/resources/candlepin.rb +1 -1
  8. data/app/lib/katello/resources/cdn.rb +1 -1
  9. data/app/models/katello/root_repository.rb +4 -0
  10. data/app/services/katello/pulp3/repository/apt.rb +6 -0
  11. data/app/services/katello/pulp3/repository/yum.rb +2 -1
  12. data/app/services/katello/pulp3/repository.rb +2 -2
  13. data/app/services/katello/pulp3/repository_mirror.rb +1 -0
  14. data/config/initializers/monkeys.rb +2 -1
  15. data/db/migrate/20221206170122_update_ignore_srpm_to_false_for_mirror_complete.rb +5 -0
  16. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/bulk/views/products-bulk-advanced-sync-modal.html +1 -1
  17. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/details/repositories/details/views/repository-advanced-sync-options.html +4 -4
  18. data/engines/bastion_katello/app/assets/javascripts/bastion_katello/products/details/repositories/repositories.routes.js +2 -2
  19. data/lib/katello/version.rb +1 -1
  20. data/lib/monkeys/fix_deb_optimized_sync.rb +35 -0
  21. data/lib/monkeys/{try_pulp_container_path.rb → fix_pulp_container_path.rb} +0 -0
  22. data/webpack/components/extensions/HostDetails/Tabs/__tests__/errataTab.test.js +2 -2
  23. data/webpack/components/extensions/HostDetails/Tabs/__tests__/moduleStreamsTab.test.js +2 -2
  24. data/webpack/components/extensions/HostDetails/Tabs/__tests__/packageInstallModal.test.js +2 -2
  25. data/webpack/components/extensions/HostDetails/Tabs/__tests__/packagesTab.test.js +2 -2
  26. data/webpack/components/extensions/HostDetails/Tabs/__tests__/tracesTab.test.js +3 -3
  27. data/webpack/components/extensions/HostDetails/Tabs/customizedRexUrlHelpers.js +1 -1
  28. metadata +8 -6
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 681115c601daa1728c23ca2aa5f2995c3997f8aebd24d48f465119a9daea07fe
4
- data.tar.gz: f83059ee941668d27e4ada30accf702b86f37fd20e475ffa0580fdea0fa01261
3
+ metadata.gz: 9591a00d0a788cc99232254d98eae3ea86ae4417e5e9203c38ef6d230cb64368
4
+ data.tar.gz: f912dcb619734ad43190add1ae7ea5a789805f2b6a5396fb0c00ac1171a32194
5
5
  SHA512:
6
- metadata.gz: 98206f5b247a2e33f31fe908d0294ac239334106118493c4c6f4749461960975043e560724e788d5ae922d334f0ee151deaa7ded09eb9df79ef4931e52509278
7
- data.tar.gz: 5f1528fa18239ddc42e4880b9877a81a75149a8e2c1a37242284e29ba8f6c808752d76c4afceea5b2b988f62df559ec5f3535e125e6a7465c11174ac69c71a09
6
+ metadata.gz: 28100053e3c9ff53029ceff9529565d8b29360236748be2ad1643fa9dbccf4f570cc5ce65d3395fdd0a057c1074505f9858fd542ce57a5f958b1ee2ee2deede3
7
+ data.tar.gz: bb5cf4097c1706dcea35275dc1a5f93cc3fe99587b569295af1a7c302e2b03155076ea027217ea5ecaf5201459e9fa50de9f11adb9891fc4077f864eafcc98dc
@@ -34,7 +34,7 @@ module Katello
34
34
  syncable_products = @products.syncable
35
35
  syncable_roots = RootRepository.where(:product_id => syncable_products).has_url
36
36
 
37
- syncable_roots = syncable_roots.yum_type if skip_metadata_check || validate_contents
37
+ syncable_roots = syncable_roots.skipable_metadata_check if skip_metadata_check || validate_contents
38
38
  syncable_roots = syncable_roots.where.not(:download_policy => ::Katello::RootRepository::DOWNLOAD_ON_DEMAND) if validate_contents
39
39
 
40
40
  syncable_repositories = Katello::Repository.where(:root_id => syncable_roots).in_default_view
@@ -346,7 +346,7 @@ module Katello
346
346
  param :id, :number, :required => true, :desc => N_("repository ID")
347
347
  param :source_url, String, :desc => N_("temporarily override feed URL for sync"), :required => false
348
348
  param :incremental, :bool, :desc => N_("perform an incremental import"), :required => false
349
- param :skip_metadata_check, :bool, :desc => N_("Force sync even if no upstream changes are detected. Only used with yum repositories."), :required => false
349
+ param :skip_metadata_check, :bool, :desc => N_("Force sync even if no upstream changes are detected. Only used with yum or deb repositories."), :required => false
350
350
  param :validate_contents, :bool, :desc => N_("Force a sync and validate the checksums of all content. Only used with yum repositories."), :required => false
351
351
  def sync
352
352
  sync_options = {
@@ -38,12 +38,11 @@ module Katello
38
38
  param_group :search, Api::V2::ApiController
39
39
  add_scoped_search_description_for(Katello::ProductContent)
40
40
  def index
41
- collection = scoped_search(index_relation, :name, :asc, :resource_class => Katello::ProductContent)
41
+ collection = scoped_search(index_relation, :name, :asc, :resource_class => Katello::ProductContent, :custom_sort => ->(relation) { custom_sort_results(relation) })
42
42
  pcf = ProductContentFinder.wrap_with_overrides(
43
43
  product_contents: collection[:results],
44
- overrides: @consumable&.content_overrides,
45
- status: params[:status])
46
- collection[:results] = custom_sort_results(pcf)
44
+ overrides: @consumable&.content_overrides)
45
+ collection[:results] = pcf
47
46
  respond(:collection => collection)
48
47
  end
49
48
 
@@ -154,7 +153,13 @@ module Katello
154
153
  :match_subscription => !content_access_mode_all,
155
154
  :match_environment => content_access_mode_env,
156
155
  :consumable => @consumable)
157
- relation.merge(content_finder.product_content)
156
+ unfiltered = relation.merge(content_finder.product_content)
157
+ return unfiltered unless params[:status]
158
+ filtered_ids = ProductContentFinder.wrap_with_overrides(
159
+ product_contents: unfiltered,
160
+ overrides: @consumable&.content_overrides,
161
+ status: params[:status]).map(&:id).uniq
162
+ unfiltered.where(id: filtered_ids)
158
163
  end
159
164
 
160
165
  def find_product_content
@@ -236,18 +241,24 @@ module Katello
236
241
  else
237
242
  0
238
243
  end
239
- Rails.logger.debug [pc.product_name, pc.enabled_content_override, "Id: #{pc.id}", "Score: #{score}"]
240
244
  score
241
245
  end
242
246
 
243
- def custom_sort_results(product_content_finder)
244
- if params[:sort_by] == 'enabled_by_default' && params[:sort_order] == 'desc'
245
- product_content_finder.sort { |pca, pcb| sort_score(pca) <=> sort_score(pcb) }.reverse!
246
- elsif params[:sort_by] == 'enabled_by_default'
247
- product_content_finder.sort { |pca, pcb| sort_score(pca) <=> sort_score(pcb) }
248
- else
249
- product_content_finder
250
- end
247
+ def custom_sort_results(unsorted_relation)
248
+ return unsorted_relation unless params[:sort_by] == 'enabled_by_default'
249
+ product_content_finder = ProductContentFinder.wrap_with_overrides(
250
+ product_contents: unsorted_relation,
251
+ overrides: @consumable&.content_overrides,
252
+ status: params[:status])
253
+ sorted_pcps = if params[:sort_by] == 'enabled_by_default' && params[:sort_order] == 'desc'
254
+ product_content_finder.sort { |pca, pcb| sort_score(pca) <=> sort_score(pcb) }.reverse!
255
+ elsif params[:sort_by] == 'enabled_by_default'
256
+ product_content_finder.sort { |pca, pcb| sort_score(pca) <=> sort_score(pcb) }
257
+ else
258
+ product_content_finder
259
+ end
260
+ sort_order = sorted_pcps.map(&:id)
261
+ unsorted_relation.reorder(Arel.sql("array_position('{#{sort_order.join(',')}}'::int[], #{Katello::ProductContent.table_name}.id)"))
251
262
  end
252
263
  end
253
264
  end
@@ -21,7 +21,7 @@ module Actions
21
21
 
22
22
  source_url = options.fetch(:source_url, nil)
23
23
  validate_contents = options.fetch(:validate_contents, false)
24
- skip_metadata_check = options.fetch(:skip_metadata_check, false) || (validate_contents && repo.yum?)
24
+ skip_metadata_check = options.fetch(:skip_metadata_check, false) || (validate_contents && (repo.yum? || repo.deb?))
25
25
  generate_applicability = options.fetch(:generate_applicability, repo.yum? || repo.deb?)
26
26
 
27
27
  validate_repo!(repo: repo,
@@ -34,7 +34,7 @@ module Actions
34
34
  pulp_sync_options[:download_policy] = ::Katello::RootRepository::DOWNLOAD_ON_DEMAND if validate_contents && repo.yum?
35
35
 
36
36
  #pulp3 options
37
- pulp_sync_options[:optimize] = false if skip_metadata_check && repo.yum?
37
+ pulp_sync_options[:optimize] = false if skip_metadata_check && (repo.yum? || repo.deb?)
38
38
 
39
39
  sequence do
40
40
  if validate_contents
@@ -85,7 +85,7 @@ module Actions
85
85
  def validate_repo!(repo:, source_url:, validate_contents:, skip_metadata_check:, skip_candlepin_check:)
86
86
  fail ::Katello::Errors::InvalidActionOptionError, _("Unable to sync repo. This repository does not have a feed url.") if repo.url.blank? && source_url.blank?
87
87
  fail ::Katello::Errors::InvalidActionOptionError, _("Cannot validate contents on non-yum/deb repositories.") if validate_contents && !repo.yum? && !repo.deb?
88
- fail ::Katello::Errors::InvalidActionOptionError, _("Cannot skip metadata check on non-yum repositories.") if skip_metadata_check && !repo.yum?
88
+ fail ::Katello::Errors::InvalidActionOptionError, _("Cannot skip metadata check on non-yum/deb repositories.") if skip_metadata_check && !repo.yum? && !repo.deb?
89
89
  ::Katello::Util::CandlepinRepositoryChecker.check_repository_for_sync!(repo) if repo.yum? && !skip_candlepin_check
90
90
  end
91
91
 
@@ -24,6 +24,7 @@ module Actions
24
24
  copy_actions = []
25
25
  #since we're creating a new version from the first repo, start copying at the 2nd
26
26
  source_repositories[1..-1].each do |source_repo|
27
+ # TODO: In a future refactor, can :copy_all be utilized? Filters should not be needed in this code segment.
27
28
  copy_actions << plan_action(Actions::Pulp3::Repository::CopyContent, source_repo, smart_proxy, target_repo,
28
29
  filter_ids: filter_ids, solve_dependencies: solve_dependencies,
29
30
  rpm_filenames: rpm_filenames, remove_all: false)
@@ -92,7 +92,7 @@ module Katello
92
92
  cert_store = OpenSSL::X509::Store.new
93
93
  cert_store.add_file(ca_file) if ca_file
94
94
 
95
- if proxy&.cacert
95
+ if proxy&.cacert&.present?
96
96
  Foreman::Util.add_ca_bundle_to_store(proxy.cacert, cert_store)
97
97
  end
98
98
  RestClient::Resource.new(url,
@@ -49,7 +49,7 @@ module Katello
49
49
  @cert_store.add_file(options[:ssl_ca_file])
50
50
  end
51
51
 
52
- if @cert_store && proxy&.cacert
52
+ if @cert_store && proxy&.cacert&.present?
53
53
  Foreman::Util.add_ca_bundle_to_store(proxy.cacert, @cert_store)
54
54
  end
55
55
 
@@ -21,6 +21,7 @@ module Katello
21
21
  CHECKSUM_TYPES = %w(sha1 sha256).freeze
22
22
 
23
23
  SUBSCRIBABLE_TYPES = [Repository::YUM_TYPE, Repository::OSTREE_TYPE, Repository::DEB_TYPE].freeze
24
+ SKIPABLE_METADATA_TYPES = [Repository::YUM_TYPE, Repository::DEB_TYPE].freeze
24
25
 
25
26
  CONTENT_ATTRIBUTE_RESTRICTIONS = {
26
27
  :download_policy => [Repository::YUM_TYPE, Repository::DEB_TYPE, Repository::DOCKER_TYPE]
@@ -101,6 +102,7 @@ module Katello
101
102
  :message => _("must be one of the following: %s") % HTTP_PROXY_POLICIES.join(', ')
102
103
  }
103
104
  scope :subscribable, -> { where(content_type: RootRepository::SUBSCRIBABLE_TYPES) }
105
+ scope :skipable_metadata_check, -> { where(content_type: RootRepository::SKIPABLE_METADATA_TYPES) }
104
106
  scope :has_url, -> { where.not(:url => nil) }
105
107
  scope :with_repository_attribute, ->(attr, value) { joins(:repositories).where("#{Katello::Repository.table_name}.#{attr}" => value) }
106
108
  scope :in_content_view_version, ->(version) { with_repository_attribute(:content_view_version_id, version) }
@@ -225,6 +227,8 @@ module Katello
225
227
  errors.add(:ignorable_content, N_("Invalid value specified for ignorable content."))
226
228
  elsif ignorable_content.any? { |item| !IGNORABLE_CONTENT_UNIT_TYPES.include?(item) }
227
229
  errors.add(:ignorable_content, N_("Invalid value specified for ignorable content. Permissible values %s") % IGNORABLE_CONTENT_UNIT_TYPES.join(","))
230
+ elsif self.mirroring_policy == MIRRORING_POLICY_COMPLETE
231
+ errors.add(:ignorable_content, N_("Ignore SRPMs can not be set in combination with 'Complete Mirroring' mirroring policy."))
228
232
  end
229
233
  end
230
234
 
@@ -24,6 +24,12 @@ module Katello
24
24
  common_remote_options.merge(deb_remote_options)
25
25
  end
26
26
 
27
+ def sync_url_params(sync_options)
28
+ params = super
29
+ params[:optimize] = sync_options[:optimize] if sync_options.key?(:optimize)
30
+ params
31
+ end
32
+
27
33
  def mirror_remote_options
28
34
  super.merge(
29
35
  {
@@ -210,7 +210,8 @@ module Katello
210
210
  tasks << add_content(slice, first_slice)
211
211
  first_slice = false
212
212
  end
213
- else
213
+ # If we're merging composite cv repositories, don't clear out the Pulp repository.
214
+ elsif remove_all
214
215
  tasks << remove_all_content
215
216
  end
216
217
  tasks
@@ -200,7 +200,7 @@ module Katello
200
200
 
201
201
  def sync_url_params(_sync_options)
202
202
  params = {remote: repo.remote_href, mirror: repo.root.mirroring_policy == Katello::RootRepository::MIRRORING_POLICY_CONTENT}
203
- params[:skip_types] = skip_types if skip_types
203
+ params[:skip_types] = skip_types if (skip_types && repo.root.mirroring_policy != Katello::RootRepository::MIRRORING_POLICY_COMPLETE)
204
204
  params
205
205
  end
206
206
 
@@ -447,7 +447,7 @@ module Katello
447
447
  end
448
448
 
449
449
  def append_proxy_cacert(options)
450
- if root.http_proxy&.cacert && options.key?(:cacert)
450
+ if root.http_proxy&.cacert&.present? && options.key?(:cacert)
451
451
  options[:cacert] += "\n#{root.http_proxy&.cacert}"
452
452
  end
453
453
  options
@@ -132,6 +132,7 @@ module Katello
132
132
  sync_params = repo_service.sync_url_params(options)
133
133
  sync_params[:remote] = remote_href
134
134
  if repo.yum?
135
+ sync_params.delete(:skip_types) if sync_params[:skip_types]
135
136
  sync_params[:sync_policy] = 'mirror_complete'
136
137
  else
137
138
  sync_params.delete(:sync_policy)
@@ -2,4 +2,5 @@
2
2
  require 'monkeys/anemone'
3
3
  require 'monkeys/ar_postgres_evr_t'
4
4
  require 'monkeys/fx_sqlite_skip'
5
- require 'monkeys/try_pulp_container_path'
5
+ require 'monkeys/fix_pulp_container_path'
6
+ require 'monkeys/fix_deb_optimized_sync'
@@ -0,0 +1,5 @@
1
+ class UpdateIgnoreSrpmToFalseForMirrorComplete < ActiveRecord::Migration[6.1]
2
+ def change
3
+ Katello::RootRepository.yum_type.where(mirroring_policy: 'mirror_complete', ignorable_content: ['srpm']).update_all(ignorable_content: [])
4
+ end
5
+ end
@@ -12,7 +12,7 @@
12
12
 
13
13
  <div class="help-block">
14
14
  <span translate>
15
- Selecting "Complete Sync" will cause only Yum repositories of the selected product to be synced.
15
+ Selecting "Complete Sync" will cause only yum/deb repositories of the selected product to be synced.
16
16
  </span>
17
17
  </div>
18
18
 
@@ -12,7 +12,7 @@
12
12
  </div>
13
13
  </div>
14
14
 
15
- <div class="radio" ng-hide="repository.content_type === 'deb'">
15
+ <div class="radio">
16
16
  <label>
17
17
  <input type="radio" ng-model="syncType" value="skipMetadataCheck" />
18
18
  <span translate>
@@ -21,10 +21,10 @@
21
21
  </label>
22
22
  <div class="help-block">
23
23
  <span translate>
24
- Sync even if the upstream metadata appears to have no change. This option is only relevant for yum repositories and will take longer than an optimized sync. Choose this option if:
24
+ Sync even if the upstream metadata appears to have no change. This option is only relevant for yum/deb repositories and will take longer than an optimized sync. Choose this option if:
25
25
  </span>
26
26
  <ul class="list-aligned">
27
- <li translate>One or more RPMs are not showing up in the local repository even though they exist in the upstream repository.</li>
27
+ <li translate>One or more packages are not showing up in the local repository even though they exist in the upstream repository.</li>
28
28
  </ul>
29
29
  </div>
30
- </div>
30
+ </div>
@@ -169,7 +169,7 @@
169
169
  })
170
170
  .state('product.repository.tasks.index', {
171
171
  url: '/tasks',
172
- permission: 'view_repositories',
172
+ permission: 'view_products',
173
173
  templateUrl: 'products/details/repositories/details/views/repository-tasks.html',
174
174
  ncyBreadcrumb: {
175
175
  label: "{{'Tasks' | translate }}",
@@ -178,7 +178,7 @@
178
178
  })
179
179
  .state('product.repository.tasks.details', {
180
180
  url: '/tasks/:taskId',
181
- permission: 'view_repositories',
181
+ permission: 'view_products',
182
182
  controller: 'TaskDetailsController',
183
183
  templateUrl: 'tasks/views/task-details.html',
184
184
  ncyBreadcrumb: {
@@ -1,3 +1,3 @@
1
1
  module Katello
2
- VERSION = "4.7.0.rc2".freeze
2
+ VERSION = "4.7.0".freeze
3
3
  end
@@ -0,0 +1,35 @@
1
+ require 'pulp_deb_client'
2
+ PulpDebClient::AptRepositorySyncURL.class_eval do
3
+ # Initializes the object
4
+ # @param [Hash] attributes Model attributes in the form of hash
5
+ def initialize(attributes = {})
6
+ unless attributes.is_a?(Hash)
7
+ fail ArgumentError, "The input argument (attributes) must be a hash in `PulpDebClient::AptRepositorySyncURL` initialize method"
8
+ end
9
+
10
+ # check to see if the attribute exists and convert string to symbol for hash key
11
+ attributes = attributes.each_with_object({}) do |(k, v), h|
12
+ unless self.class.attribute_map.key?(k.to_sym)
13
+ fail ArgumentError, "`#{k}` is not a valid attribute in `PulpDebClient::AptRepositorySyncURL`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
14
+ end
15
+ h[k.to_sym] = v
16
+ end
17
+
18
+ if attributes.key?(:remote)
19
+ self.remote = attributes[:remote]
20
+ end
21
+
22
+ if attributes.key?(:mirror)
23
+ self.mirror = attributes[:mirror]
24
+ else
25
+ self.mirror = false
26
+ end
27
+
28
+ if attributes.key?(:optimize)
29
+ self.optimize = attributes[:optimize]
30
+ # Monkey-patch here. Rest of the initializer is copied from the gem code.
31
+ #else
32
+ # self.optimize = true
33
+ end
34
+ end
35
+ end
@@ -1132,7 +1132,7 @@ test('Can apply errata in bulk via customized remote execution', async (done) =>
1132
1132
  expect(viaRexAction).toBeInTheDocument();
1133
1133
  expect(viaRexAction).toHaveAttribute(
1134
1134
  'href',
1135
- `/job_invocations/new?feature=${feature}&host_ids=name%20%5E%20(${hostName})&inputs%5BErrata%20search%20query%5D=errata_id%20%5E%20(${errata})`,
1135
+ `/job_invocations/new?feature=${feature}&search=name%20%5E%20(${hostName})&inputs%5BErrata%20search%20query%5D=errata_id%20%5E%20(${errata})`,
1136
1136
  );
1137
1137
 
1138
1138
  viaRexAction.click();
@@ -1248,7 +1248,7 @@ test('Can apply a single erratum to the host via customized remote execution', a
1248
1248
  viaRexAction.click();
1249
1249
  expect(viaRexAction).toHaveAttribute(
1250
1250
  'href',
1251
- `/job_invocations/new?feature=${feature}&host_ids=name%20%5E%20(${hostName})&inputs%5BErrata%20search%20query%5D=errata_id%20=%20${errataId}`,
1251
+ `/job_invocations/new?feature=${feature}&search=name%20%5E%20(${hostName})&inputs%5BErrata%20search%20query%5D=errata_id%20=%20${errataId}`,
1252
1252
  );
1253
1253
  assertNockRequest(autocompleteScope);
1254
1254
  assertNockRequest(scope, done);
@@ -208,8 +208,8 @@ test('Can provide dropdown actions with redirects on Module Streams with customi
208
208
  await patientlyWaitFor(() => expect(getByLabelText('customize-checkbox-3')).toBeInTheDocument());
209
209
  fireEvent.click(getByLabelText('customize-checkbox-3'));
210
210
  await patientlyWaitFor(() => expect(getByText('Enable')).toBeInTheDocument());
211
- expect(getByText('Enable')).toHaveAttribute('href', '/job_invocations/new?feature=katello_module_stream_action&host_ids=name%20%5E%20(test-host)&inputs%5Baction%5D=enable&inputs%5Bmodule_spec%5D=walrus:2.4');
212
- expect(getByText('Install')).toHaveAttribute('href', '/job_invocations/new?feature=katello_module_stream_action&host_ids=name%20%5E%20(test-host)&inputs%5Baction%5D=install&inputs%5Bmodule_spec%5D=walrus:2.4');
211
+ expect(getByText('Enable')).toHaveAttribute('href', '/job_invocations/new?feature=katello_module_stream_action&search=name%20%5E%20(test-host)&inputs%5Baction%5D=enable&inputs%5Bmodule_spec%5D=walrus:2.4');
212
+ expect(getByText('Install')).toHaveAttribute('href', '/job_invocations/new?feature=katello_module_stream_action&search=name%20%5E%20(test-host)&inputs%5Baction%5D=install&inputs%5Bmodule_spec%5D=walrus:2.4');
213
213
  assertNockRequest(autocompleteScope);
214
214
  assertNockRequest(scope, done);
215
215
  act(done);
@@ -310,7 +310,7 @@ test('Can install a package via customized remote execution', async (done) => {
310
310
  expect(customizedRexOption).toBeInTheDocument();
311
311
  expect(customizedRexOption).toHaveAttribute(
312
312
  'href',
313
- `/job_invocations/new?feature=${REX_FEATURES.KATELLO_PACKAGE_INSTALL}&host_ids=name%20%5E%20(test-host)&inputs%5Bpackage%5D=duck,cheetah`,
313
+ `/job_invocations/new?feature=${REX_FEATURES.KATELLO_PACKAGE_INSTALL}&search=name%20%5E%20(test-host)&inputs%5Bpackage%5D=duck,cheetah`,
314
314
  );
315
315
  assertNockRequest(autocompleteScope);
316
316
  assertNockRequest(scope, done);
@@ -348,7 +348,7 @@ test('Uses package_install_by_search_query template when in select all mode', as
348
348
  expect(customizedRexOption).toBeInTheDocument();
349
349
  expect(customizedRexOption).toHaveAttribute(
350
350
  'href',
351
- `/job_invocations/new?feature=${REX_FEATURES.KATELLO_PACKAGE_INSTALL_BY_SEARCH}&host_ids=name%20%5E%20(test-host)&inputs%5BPackage%20search%20query%5D=id%20!%5E%20(32376)`,
351
+ `/job_invocations/new?feature=${REX_FEATURES.KATELLO_PACKAGE_INSTALL_BY_SEARCH}&search=name%20%5E%20(test-host)&inputs%5BPackage%20search%20query%5D=id%20!%5E%20(32376)`,
352
352
  );
353
353
  assertNockRequest(autocompleteScope);
354
354
  assertNockRequest(scope, done);
@@ -261,7 +261,7 @@ test('Can upgrade a package via customized remote execution', async (done) => {
261
261
  expect(rexAction).toBeInTheDocument();
262
262
  expect(rexAction).toHaveAttribute(
263
263
  'href',
264
- `/job_invocations/new?feature=${feature}&host_ids=name%20%5E%20(${hostname})&inputs%5Bpackage%5D=${packageName}`,
264
+ `/job_invocations/new?feature=${feature}&search=name%20%5E%20(${hostname})&inputs%5Bpackage%5D=${packageName}`,
265
265
  );
266
266
 
267
267
  fireEvent.click(rexAction);
@@ -338,7 +338,7 @@ test('Can bulk upgrade via customized remote execution', async (done) => {
338
338
  const feature = REX_FEATURES.KATELLO_PACKAGES_UPDATE_BY_SEARCH;
339
339
  const packages = `${firstPackage.id},${secondPackage.id}`;
340
340
  const job =
341
- `/job_invocations/new?feature=${feature}&host_ids=name%20%5E%20(${hostname})&inputs%5BPackages%20search%20query%5D=id%20%5E%20(${packages})&inputs%5BSelected%20update%20versions%5D=%5B%5D`;
341
+ `/job_invocations/new?feature=${feature}&search=name%20%5E%20(${hostname})&inputs%5BPackages%20search%20query%5D=id%20%5E%20(${packages})&inputs%5BSelected%20update%20versions%5D=%5B%5D`;
342
342
 
343
343
  getByRole('checkbox', { name: 'Select row 0' }).click();
344
344
  expect(getByLabelText('Select row 0').checked).toEqual(true);
@@ -298,7 +298,7 @@ describe('With tracer installed', () => {
298
298
  });
299
299
  expect(viaCustomizedRexAction).toHaveAttribute(
300
300
  'href',
301
- `/job_invocations/new?feature=${feature}&host_ids=name%20%5E%20(${hostName})&inputs%5BTraces%20search%20query%5D=id%20=%20${firstTrace.id}`,
301
+ `/job_invocations/new?feature=${feature}&search=name%20%5E%20(${hostName})&inputs%5BTraces%20search%20query%5D=id%20=%20${firstTrace.id}`,
302
302
  );
303
303
 
304
304
  assertNockRequest(autocompleteScope);
@@ -331,7 +331,7 @@ describe('With tracer installed', () => {
331
331
  expect(viaCustomizedRexAction).toBeInTheDocument();
332
332
  expect(viaCustomizedRexAction).toHaveAttribute(
333
333
  'href',
334
- `/job_invocations/new?feature=${feature}&host_ids=name%20%5E%20(${hostName})&inputs%5BTraces%20search%20query%5D=id%20%5E%20(${firstTrace.id})`,
334
+ `/job_invocations/new?feature=${feature}&search=name%20%5E%20(${hostName})&inputs%5BTraces%20search%20query%5D=id%20%5E%20(${firstTrace.id})`,
335
335
  );
336
336
 
337
337
  assertNockRequest(autocompleteScope);
@@ -430,7 +430,7 @@ describe('Without tracer installed', () => {
430
430
  expect(enableTracesModalLink)
431
431
  .toHaveAttribute(
432
432
  'href',
433
- `/job_invocations/new?feature=${feature}&host_ids=name%20%5E%20(${hostName})&inputs%5Bpackage%5D=katello-host-tools-tracer`,
433
+ `/job_invocations/new?feature=${feature}&search=name%20%5E%20(${hostName})&inputs%5Bpackage%5D=katello-host-tools-tracer`,
434
434
  );
435
435
  enableTracesModalLink.click();
436
436
  expect(enableTracesModalLink).toHaveClass('pf-m-in-progress');
@@ -10,7 +10,7 @@ export const createJob = ({
10
10
  const inputParams = Object.keys(inputs).map(key => `inputs[${key}]=${inputs[key]}`);
11
11
  const params = [
12
12
  `feature=${feature}`,
13
- `host_ids=name ^ (${hostname})`,
13
+ `search=name ^ (${hostname})`,
14
14
  ...inputParams,
15
15
  ];
16
16
  const urlQuery = encodeURI(params.join('&'));
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: katello
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.7.0.rc2
4
+ version: 4.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - N/A
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-11-28 00:00:00.000000000 Z
11
+ date: 2022-12-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -2234,6 +2234,7 @@ files:
2234
2234
  - db/migrate/20220730033504_update_custom_cdn.rb
2235
2235
  - db/migrate/20220920173656_add_http_proxy_to_smart_proxy.rb
2236
2236
  - db/migrate/20220920180858_remove_http_proxy_from_katello_alternate_content_sources.rb
2237
+ - db/migrate/20221206170122_update_ignore_srpm_to_false_for_mirror_complete.rb
2237
2238
  - db/seeds.d/101-locations.rb
2238
2239
  - db/seeds.d/102-organizations.rb
2239
2240
  - db/seeds.d/104-proxy.rb
@@ -4479,8 +4480,9 @@ files:
4479
4480
  - lib/katello/version.rb
4480
4481
  - lib/monkeys/anemone.rb
4481
4482
  - lib/monkeys/ar_postgres_evr_t.rb
4483
+ - lib/monkeys/fix_deb_optimized_sync.rb
4484
+ - lib/monkeys/fix_pulp_container_path.rb
4482
4485
  - lib/monkeys/fx_sqlite_skip.rb
4483
- - lib/monkeys/try_pulp_container_path.rb
4484
4486
  - lib/proxy_api/container_gateway.rb
4485
4487
  - lib/proxy_api/pulp.rb
4486
4488
  - lib/proxy_api/pulp_node.rb
@@ -5435,11 +5437,11 @@ required_ruby_version: !ruby/object:Gem::Requirement
5435
5437
  version: '2.5'
5436
5438
  required_rubygems_version: !ruby/object:Gem::Requirement
5437
5439
  requirements:
5438
- - - ">"
5440
+ - - ">="
5439
5441
  - !ruby/object:Gem::Version
5440
- version: 1.3.1
5442
+ version: '0'
5441
5443
  requirements: []
5442
- rubygems_version: 3.3.7
5444
+ rubygems_version: 3.3.26
5443
5445
  signing_key:
5444
5446
  specification_version: 4
5445
5447
  summary: Content and Subscription Management plugin for Foreman