Red Hat Satellite engineering is moving the tracking of its product development work on Satellite to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1347786 - API Missing route /organizations/:orgid/repositories to list all repos in an organization
Summary: API Missing route /organizations/:orgid/repositories to list all repos in an ...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: API
Version: 6.2.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: Unspecified
Assignee: Brad Buckingham
QA Contact: Bruno Rocha
URL:
Whiteboard:
Depends On:
Blocks: 1122832
TreeView+ depends on / blocked
 
Reported: 2016-06-17 15:55 UTC by Peter Vreman
Modified: 2019-09-25 20:40 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-02-21 16:49:54 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 15487 0 None None None 2016-06-21 20:52:26 UTC

Description Peter Vreman 2016-06-17 15:55:53 UTC
Description of problem:
Missing a route to list all repositories in an organizations. This is inconsistent with other routes like the content_views or products.

[crash] root@li-lc-1578:~# curl -K /opt/hoici/etc/sat6/curl-hoici.conf "-HContent-Type: application/json" "-d{\"per_page\":9999}" -XGET https://localhost/katello/api/v2/organizations/3/repositories
<!DOCTYPE html>
<html>
<head>
  <title>The page you were looking for doesn't exist (404)</title>
  <meta name="viewport" content="width=device-width,initial-scale=1">
...

Examples for content_views and products:

[crash] root@li-lc-1578:~# curl -K /opt/hoici/etc/sat6/curl-hoici.conf "-HContent-Type: application/json" "-d{\"per_page\":9999}" -XGET https://localhost/katello/api/v2/organizations/3/content_views | jq .total
45
[crash] root@li-lc-1578:~# curl -K /opt/hoici/etc/sat6/curl-hoici.conf "-HContent-Type: application/json" "-d{\"per_page\":9999}" -XGET https://localhost/katello/api/v2/organizations/3/products | jq .total
37


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


How reproducible:


Steps to Reproduce:
1. curl "-HContent-Type: application/json" "-d{\"per_page\":9999}" -XGET https://localhost/katello/api/v2/organizations/3/repositories

2.
3.

Actual results:
HTTP error

Expected results:
All repositories of the organziation are returned


Additional info:

Comment 2 Brad Buckingham 2016-06-21 20:52:25 UTC
Created redmine issue http://projects.theforeman.org/issues/15487 from this bug

Comment 3 Brad Buckingham 2016-06-21 20:56:40 UTC
Created upstream Katello PR : https://github.com/Katello/katello/pull/6142

Comment 7 Bruno Rocha 2016-11-09 23:18:13 UTC
Verified in:

satellite-6.3.0-6.1.beta.el7sat.noarch - RHEL6 and RHEL7

Conclusion:

Issue is not reproducible.

Test made:


[brocha@localhost ~]$ curl --insecure --user admin:XXX "-HContent-Type: application/json" "-d{\"per_page\":9999}" -XGET https://FQDN/katello/api/v2/organizations/43/repositories | python -m json.tool
{
    "error": null,
    "page": 1,
    "per_page": 9999,
    "results": [
        {
            "content_counts": {
                "docker_manifest": 0,
                "docker_tag": 0,
                "erratum": 5,
                "file": 0,
                "ostree_branch": 0,
                "package": 69,
                "package_group": 1,
                "puppet_module": 0,
                "rpm": 69
            },
            "content_type": "yum",
            "id": 70,
            "label": "Red_Hat_Satellite_Tools_6_2_for_RHEL_7_Server_RPMs_x86_64",
            "last_sync": {
                "ended_at": "2016-11-09 22:25:31 UTC",
                "id": "12bc821b-f4cb-475a-a098-f2d2f8c5e2cd",
                "progress": 1.0,
                "result": "success",
                "started_at": "2016-11-09 22:25:14 UTC",
                "state": "stopped",
                "username": "admin"
            },
            "last_sync_words": "about 1 hour",
            "name": "Red Hat Satellite Tools 6.2 for RHEL 7 Server RPMs x86_64",
            "product": {
                "cp_id": "69",
                "id": 84,
                "name": "Red Hat Enterprise Linux Server",
                "sync_plan": [
                    "name",
                    "description",
                    "sync_date",
                    "interval",
                    "next_sync"
                ]
            },
            "relative_path": "pNecdLxjQ/Library/content/dist/rhel/server/7/7Server/x86_64/sat-tools/6.2/os",
            "url": "https://cdn.redhat.com/content/dist/rhel/server/7/7Server/x86_64/sat-tools/6.2/os"
        }
    ],
    "search": null,
    "sort": {
        "by": null,
        "order": null
    },
    "subtotal": 1,
    "total": 1
}

Comment 8 Bryan Kearney 2018-02-21 16:43:35 UTC
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-2018:0336

Comment 9 Satellite Program 2018-02-21 16:49:54 UTC
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-2018:0336


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