Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 1190224 - Incorrect error message on docker repository creation
Incorrect error message on docker repository creation
Status: CLOSED ERRATA
Product: Red Hat Satellite 6
Classification: Red Hat
Component: Hammer (Show other bugs)
6.1.0
Unspecified Unspecified
unspecified Severity medium (vote)
: Unspecified
: Unused
Assigned To: David Davis
sthirugn@redhat.com
: Triaged
Depends On:
Blocks: 1190289
  Show dependency treegraph
 
Reported: 2015-02-06 12:16 EST by sthirugn@redhat.com
Modified: 2017-02-23 15:34 EST (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-08-12 01:23:53 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2015:1592 normal SHIPPED_LIVE Important: Red Hat Satellite 6.1.1 on RHEL 6 2015-08-12 05:04:35 EDT

  None (edit)
Description sthirugn@redhat.com 2015-02-06 12:16:03 EST
Description of problem:
Incorrect error message on docker repository creation

Version-Release number of selected component (if applicable):
Version: Satellite-6.1.0-RHEL-7-20150205.0

How reproducible:
Always

Steps to Reproduce:
hammer> repository create --name='dockerrepo4' --content-type='docker' --url='https://registry.hub.docker.com' --product='testproduct3' --organization-id=1
Could not create the repository:
  Validation failed: Repository URL and Upstream Name cannot be empty. Both are required for syncing from the upstream.


Actual results:
As shown above

Expected results:
Could not create the repository:
  Validation failed: Upstream Name cannot be empty.

Additional info:
Comment 2 David Davis 2015-02-11 12:23:55 EST
This is the intended behavior I believe. To create a docker repo you must supply either both the upstream name and url:

h repository create --name='dockerrepo4' --content-type='docker' --url='https://registry.hub.docker.com' --product='testproduct3' --organization-id=1 --docker-upstream-name=centos

Or neither:

h repository create --name='dockerrepo4' --content-type='docker' -product='testproduct3' --organization-id=1
Comment 3 sthirugn@redhat.com 2015-02-11 12:30:25 EST
I expected a more smarter error message for usability:

Current error message for the scenario I mentioned in the bug is:
"Could not create the repository:
  Validation failed: Repository URL and Upstream Name cannot be empty. Both are required for syncing from the upstream."

Note that I already provided Repository URL.  So I expected error message to be something like:
"Could not create the repository:
  Validation failed: Upstream Name cannot be empty when Repository URL is provided. Both are required for syncing from the upstream."
Comment 4 David Davis 2015-02-18 15:37:19 EST
Talked with sthirugn. The latest compose should say this:

"Validation failed: Docker upstream name cannot be blank. Either provide all or no sync information. Repository URL or Upstream Name is empty. Both are required for syncing from the upstream."
Comment 6 sthirugn@redhat.com 2015-02-18 15:54:21 EST
Verified.

Version Tested:
Satellite-6.1.0-RHEL-6-20150217.0

hammer> repository create --name='dockerrepo1' --content-type='docker' --product='testproduct1' --organization-id=1 --docker-upstream-name='fedora/ssh'
Could not create the repository:
  Validation failed: Url cannot be blank. Either provide all or no sync information., Repository URL or Upstream Name is empty. Both are required for syncing from the upstream.



hammer> repository create --name='dockerrepo4' --content-type='docker' --url='https://registry.hub.docker.com' --product='testproduct1' --organization-id=1
Could not create the repository:
  Validation failed: Docker upstream name cannot be blank. Either provide all or no sync information., Repository URL or Upstream Name is empty. Both are required for syncing from the upstream.
Comment 7 Bryan Kearney 2015-08-11 09:30:16 EDT
This bug is slated to be released with Satellite 6.1.
Comment 8 errata-xmlrpc 2015-08-12 01:23:53 EDT
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2015:1592

Note You need to log in before you can comment on or make changes to this bug.