-
Notifications
You must be signed in to change notification settings - Fork 65
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
certification-project-id with multiple dashes causes 404 status when trying to submit #758
Comments
Seems like the problem is this line https://github.com/redhat-openshift-ecosystem/openshift-preflight/blob/main/certification/runtime/config.go#L69 |
@jrsmroz This is confusing, but the projectid is not the |
That is misleading, because for the other image we publish, providing ospid works fine. I will modify the pipeline and verify. The code, that checks for |
I confirm that it worked. Would it be possible to prevent those kind of failures somehow? |
I understand that this is confusing, since images need to be pushed to our registry using We will look at handling this error better in preflight, to avoid confusion. One other question, are you submitting images to Red Hat nightly? If so this isn't supported and will cause issues, we do not even push Red Hat images nightly ie UBI images. Only images that are intended to be published should be pushed to Red Hat. You can still run preflight in your nightly build, but without the |
Yeah, our pipeline pushes the images nightly. But those are our nightly images, build on top od released UBI image. The reasoning was doing the security scans often. However, we do not publish them, they stay in red hat scan registry. What is the problem with nightly images? So far it worked. We also have a release pipeline that pushes the release images. |
We should only see images that you intend to publish, not every intermediate image, our systems were not designed for this type of use. If used this way, there will be a point where you will not be able to see or publish your images without manual intervention. UBI images are not published nightly, they are only published when there is a vulnerability. If your concern is to address vulnerabilities when they happen, there are other processes that you can setup, happy to discuss that via other partner channels. |
Thanks for clarification. |
One clarification on Adam's comment about OSPID values. For all projects created prior to July of 2021, the OSPID was derived from a process that created a value that had several dashes embedded and bore no resemblance to the Pyxis project ID. For all projects created AFTER July 2021, the OSPID value is the same as the Pyxis database project ID. There's an easy way to tell, besides the presence of dashes in the OSPID value. Pyxis project IDs for projects created before the cut-over will have a leading 5 in their value - hence |
Bug Description
When a certification-project-id has multiple dashes, the preflight fails with 404 error as a result of truncating the project id.
Version and Command Invocation
preflight version 1.3.3 <commit: 6c30f7c>
Steps to Reproduce:
Expected Result
Should behave same as with project id with a single dash or no dashes at all.
Actual Result
The "URL is: https://catalog.redhat.com/api/containers/v1/projects/certification/id/f8304390" indicates that the project id was truncated. As a result project was no found, thus 404 status.
Additional Context
N/A
The text was updated successfully, but these errors were encountered: