Bug 1253589

Summary: Search works improperly for Docker(Hub) Container create procedure
Product: Red Hat Satellite Reporter: Oleksandr Shtaier <oshtaier>
Component: Container ManagementAssignee: Daniel Lobato Garcia <dlobatog>
Status: CLOSED WORKSFORME QA Contact: Katello QA List <katello-qa-list>
Severity: high Docs Contact:
Priority: unspecified    
Version: 6.1.0CC: bbuckingham, oshtaier
Target Milestone: UnspecifiedKeywords: Triaged
Target Release: Unused   
Hardware: x86_64   
OS: Linux   
URL: http://projects.theforeman.org/issues/14406
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-04-06 08:33:28 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Error messages example none

Description Oleksandr Shtaier 2015-08-14 07:59:47 UTC
Created attachment 1062916 [details]
Error messages example

Description of problem:
Getting different error messages while trying to input any string in 'search' field of Docker Hub tab in new 'New Container'->'Image' section
That issue is referring to docker daemon 1.6.2 version

Version-Release number of selected component (if applicable):
RC1

How reproducible:
Always

Steps to Reproduce:
1. Create new Docker compute resource
2. Create Product and add Docker repository to it. (e.g. 'busybox' from 'https://registry.hub.docker.com')
3. Sync that repo (In result we should have repo with some Docker Images and some Docker Tags inside)
4. Push 'New Container' button
5. Preliminary->Deploy on->Select Docker compute resource from step 1
6. Next->Image->Docker Hub
7. Input any existing container name to search field(e.g. 'centos')

Actual results:
Getting error message in UI:
NoMethodError
undefined method `info' for nil:NilClass
app/models/concerns/foreman/thread_session.rb:33:in `clear_thread'
lib/middleware/catch_json_parse_errors.rb:9:in `call' 

Expected results:
Container found and necessary tag displayed in the 'Tag' field

Additional info:

That behaviour was mentioned in 1253270 bug, but definitely worth to create separate defect

Comment 3 Daniel Lobato Garcia 2016-03-31 06:35:02 UTC
Created redmine issue http://projects.theforeman.org/issues/14406 from this bug

Comment 4 Daniel Lobato Garcia 2016-04-04 07:16:33 UTC
Do you have a reproducer for this on the latest snap? Your steps indicate you understood the container creation process wrong:

In steps 2 and 3 you create a Product and sync, but on step 6 you decide to use the Docker hub. Why do you even sync the Product if you plan to use the hub image instead?

Comment 5 Oleksandr Shtaier 2016-04-06 08:32:55 UTC
1) Yes, you are right about the process. I just used same process for all docker related things. And yes, I have lack of experience in that area, but now I see correct flow. There is a slight chance that steps 2 and 3 can impact overal flow, but it is not a case here
2) Docker package is already upgraded bunch of times and we should not support all versions of that package
3) Functionality works as intended for last docker daemon and application version