Bug 2125244
Summary: | Sync of a docker type repository containing schema 1 manifest fails with error | ||
---|---|---|---|
Product: | Red Hat Satellite | Reporter: | Vladimír Sedmík <vsedmik> |
Component: | Pulp | Assignee: | Ina Panova <ipanova> |
Status: | CLOSED ERRATA | QA Contact: | Vladimír Sedmík <vsedmik> |
Severity: | medium | Docs Contact: | |
Priority: | unspecified | ||
Version: | 6.12.0 | CC: | amasolov, dalley, iballou, ipanova, pcreech |
Target Milestone: | 6.12.0 | Keywords: | Regression, Triaged |
Target Release: | Unused | ||
Hardware: | x86_64 | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | pulp_container-2.10.9, pulp_container-2.9.8 | Doc Type: | If docs needed, set a value |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2022-11-16 13:35:50 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: |
Description
Vladimír Sedmík
2022-09-08 12:36:11 UTC
500 "Internal server error" doesn't sound like a Pulp problem necessarily. It could be a transient issue with Quay. After poking around the database, it looks like the repository in question is not getting the docker manifest indexed from Pulp into the Katello DB. This has reportedly been reproduced on 3 separate Satellite machines across snaps 9 and 10 Looks like I found the root issue. In Katello's manifest indexing code, we look for media types: ['application/vnd.docker.distribution.manifest.v1+json', 'application/vnd.docker.distribution.manifest.v2+json'] But, the Pulp API is returning a new manifest media type (+prettyjws): [root@dhcp-3-187 ~]# pulp show --href /pulp/api/v3/content/container/manifests/?repository_version_added=/pulp/api/v3/repositories/container/container/055b9df9-5ae2-484d-be70-be27f4ee87ee/versions/1/ { "count": 1, "next": null, "previous": null, "results": [ { "pulp_href": "/pulp/api/v3/content/container/manifests/796a10da-a1a1-4834-ac38-1816dfb4c130/", "pulp_created": "2022-09-08T10:57:43.725388Z", "artifact": "/pulp/api/v3/artifacts/80b8c577-9f82-47ab-a67c-42f6796dd5b7/", "digest": "sha256:ffd944135bc9fe6573e82d4578c28beb6e3fec1aea988c38d382587c7454f819", "schema_version": 1, "media_type": "application/vnd.docker.distribution.manifest.v1+prettyjws", "listed_manifests": [], "config_blob": null, "blobs": [ "/pulp/api/v3/content/container/blobs/973153f7-e098-4d59-b7c1-ae3c1a0ed435/", "/pulp/api/v3/content/container/blobs/f3930908-96df-471b-bf75-664c3f0186f8/", "/pulp/api/v3/content/container/blobs/82af9e66-f3bc-45f2-b183-8d18b5e9012f/" ] } ] } I think Katello should just need to start looking out for this "new" media type. What would be good to know though is if this means older pulp-container needs to return the signed manifest type. Edit: it sounds like Pulp shouldn't be returning this new media_type via the repository versions API. It cannot be filtered for: https://docs.pulpproject.org/pulp_container/restapi.html#tag/Content:-Manifests/operation/content_container_manifests_list After a discussion with Ina, I'm changing this to the Pulp component since the signed media type shouldn't be presented via the API. This change makes it so that the media type is taken from response headers https://github.com/pulp/pulp_container/commit/89548413a8ab78af83cd34412062eb149dd41b09#diff-b4450b457692a725eeadc0ef7b13abfb35f2969203ee4c21bea33b2d8bbf37dbR28 which happens to be signed manifest. There question is how the heck it got saved if we enforce this on the DB level with the choices fields which do not have among the signed media_type https://github.com/pulp/pulp_container/blob/main/pulp_container/app/models.py#L93 The fix is available in pulp-container 2.10.9 and 2.9.8 Verified in 6.12.0 snap 12 *** Bug 2134682 has been marked as a duplicate of this bug. *** 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 (Important: Satellite 6.12 Release), 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-2022:8506 |