Bug 1479391 - POST/PUT /docker/api/v2/registries does not return organization/location
POST/PUT /docker/api/v2/registries does not return organization/location
Product: Red Hat Satellite 6
Classification: Red Hat
Component: Container Management (Show other bugs)
Unspecified Unspecified
unspecified Severity medium (vote)
: Unspecified
: --
Assigned To: satellite6-bugs
Katello QA List
Depends On:
  Show dependency treegraph
Reported: 2017-08-08 09:30 EDT by Stanislav Tkachenko
Modified: 2017-08-30 04:15 EDT (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2017-08-29 06:12:51 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Stanislav Tkachenko 2017-08-08 09:30:39 EDT
Description of problem:
It is possible to specify organization ids when creating registry, but response does not contain any information about organizations.

However, this information is present in response for GET request.

2017-08-08 14:24:53 - nailgun.client - DEBUG - Making HTTP POST request to https://sat6.com/docker/api/v2/registries with options {'verify': False, 'auth': ('admin', 'changeme'), 'headers': {'content-type': 'application/json'}}, no params and data {"registry": {"url": "https://registry.access.redhat.com", "organization_ids": [26], "name": "wEdKQQB"}}.

2017-08-08 14:24:56 - nailgun.client - DEBUG - Received HTTP 201 response: {"id":12,"url":"https://registry.access.redhat.com","name":"wEdKQQB","description":null,"created_at":"2017-08-08T12:24:55.649Z","updated_at":"2017-08-08T12:24:55.649Z","username":null,"password":null}

Version-Release number of selected component (if applicable):
Satellite 6.3 Snap 10:
* satellite-6.3.0-16.0.beta.el7sat.noarch
* katello-3.4.4-2.el7sat.noarch
* foreman-1.15.2-1.el7sat.noarch
* tfm-rubygem-foreman_docker-3.1.0-1.fm1_15.el7sat.noarch

How reproducible:

Steps to Reproduce:
1. % curl -s -H "Content-Type: application/json"  -X POST  \
     -k -u $USER:$PASS \
     -d '{"registry": {"name": "123", "organization_ids": [1], "url": "https://registry.access.redhat.com"}}' \
     $SAT_URL/docker/api/v2/registries | jq

Actual results:
Organizations information is missing from POST response.

Expected results:
Organizations information should be present in POST response.

Additional info:
Comment 1 Stanislav Tkachenko 2017-08-08 09:58:25 EDT
Same for location, actually.
Comment 2 Brad Buckingham 2017-08-08 15:17:33 EDT
Daniel, thoughts on this one?  Is it a valid issue and feasible to address?
Comment 3 Daniel Lobato Garcia 2017-08-29 06:04:07 EDT
Stanislav, what version of the foreman-docker plugin are you using? You can check this on Administer > About.

Since https://github.com/theforeman/foreman-docker/commit/c1cbf3bd157d557241a524c39823ed7aff148248 we should have this available.
Comment 4 RHEL Product and Program Management 2017-08-29 06:12:51 EDT
Development Management has reviewed and declined this request.
You may appeal this decision by reopening this request.
Comment 5 Stanislav Tkachenko 2017-08-30 04:15:12 EDT
(In reply to Daniel Lobato Garcia from comment #3)
> Stanislav, what version of the foreman-docker plugin are you using? You can
> check this on Administer > About.
> Since
> https://github.com/theforeman/foreman-docker/commit/
> c1cbf3bd157d557241a524c39823ed7aff148248 we should have this available.

It works for GET but this bug was about POST/PUT. Ok, if WONTFIX then WONTFIX.

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