Project

General

Profile

Actions

Bug #32745

closed

Capsule sync fails with ISE (500) during container gateway repository list update

Added by James Jeffers almost 3 years ago. Updated almost 3 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Container
Target version:
Difficulty:
Triaged:
Yes
Fixed in Releases:
Found in Releases:

Description

The following error occurs if the container repository list is empty during a capsule sync:

On the katello server, the repo list is empty:

19:07:38 rails.1   |
19:07:38 rails.1   | [7, 16] in /home/vagrant/katello/lib/proxy_api/container_gateway.rb
19:07:38 rails.1   |     7:
19:07:38 rails.1   |     8:     def repository_list(args)
19:07:38 rails.1   |     9:       # put '/v2/repository_list/?'
19:07:38 rails.1   |    10:       @url += "/repository_list" 
19:07:38 rails.1   |    11:       byebug
19:07:38 rails.1   | => 12:       parse put(args)
19:07:38 rails.1   |    13:     rescue => e
19:07:38 rails.1   |    14:       raise ::ProxyAPI::ProxyException.new(url, e, N_("Unable to update the repository list"))
19:07:38 rails.1   |    15:     end
19:07:38 rails.1   |    16:
19:07:41 rails.1   | (byebug) args
19:07:41 rails.1   | {:repositories=>[]}

And therefore on the proxy:

2021-06-07T19:14:02  [I] WEBrick::HTTPServer#start: pid=9768 port=9090
2021-06-07T19:14:02  [I] Smart proxy has launched on 2 socket(s), waiting for requests
2021-06-07T19:14:36 f82fa9f2 [I] Started PUT /container_gateway/repository_list/
2021-06-07T19:14:36 f82fa9f2 [W] <Sinatra::IndifferentHash> {"repositories"=>nil}
2021-06-07T19:14:36 f82fa9f2 [W] Error processing request 'f82fa9f2-e00c-4bfb-85d0-33ff76a9432a: <NoMethodError>: undefined method `each' for nil:NilClass
/opt/theforeman/tfm/root/usr/share/gems/gems/smart_proxy_container_gateway-1.0.4/lib/smart_proxy_container_gateway/container_gateway_main.rb:81:in `update_repository_list'
/opt/theforeman/tfm/root/usr/share/gems/gems/smart_proxy_container_gateway-1.0.4/lib/smart_proxy_container_gateway/container_gateway_api.rb:127:in `block in <class:Api>'

Actions #1

Updated by James Jeffers almost 3 years ago

  • Target version set to Katello 4.2.0
  • Triaged changed from No to Yes
Actions #2

Updated by Justin Sherrill almost 3 years ago

  • Bugzilla link set to 1966868
Actions #3

Updated by The Foreman Bot almost 3 years ago

  • Status changed from New to Ready For Testing
  • Assignee set to Ian Ballou
  • Pull request https://github.com/Katello/smart_proxy_container_gateway/pull/16 added
Actions #4

Updated by Anonymous almost 3 years ago

  • Status changed from Ready For Testing to Closed
Actions

Also available in: Atom PDF