-
-
Notifications
You must be signed in to change notification settings - Fork 55
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
Packages upload to ghcr #208
base: main
Are you sure you want to change the base?
Conversation
Hi! This is the friendly automated conda-forge-linting service. I just wanted to let you know that I linted all conda-recipes in your PR ( |
f94d594
to
6304c1d
Compare
i'm mostly passing by, but can you share some context of what this is? is there an other issue open about this? |
Hey! So this is related to the wanted feature to add packages upload to Github container registry in addition to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This upload cannot go here. We have to do it via the webservices in order to verify the artifacts.
Oh ok! Where exactly do you suggest doing it? Is it somewhere here or somewhere else or in a another repo? |
Somewhere else completely. We'll need to do it either on the heroku server or using a dispatch to github actions. cc @wolfv for viz |
Yeah, I think there are quite some considerations that we still have to do in terms of where to put this functionality. Regarding the verification one could also do that via It would be cool though to start to put together a standalone feedstock that does the upload-after-build to the OCI registry. If we want to do the upload in the Heroku server, then this is probably the code (https://github.com/conda-forge/conda-forge-webservices/blob/ac84983eb66239c8d3bd6f5fb8b3297f709d2f8d/conda_forge_webservices/webapp.py#L498) |
So the heroku server can't itself do the upload. It'd grind to a halt. We'll need to dispatch out to another service. Or we need to stage into one OCI registry and copy to another via an api call. |
We can also use tags (e.g. |
As long as we don't ship repodata pointing to tags that'd be fine. |
Actually I'm not sure labels/tags will work. We shouldn't have keys to upload to our registry in feedstocks out in the open. We need a staging area and then a secured copy. |
IIUC, we could upload to |
Yes, a staging area could work. However, remember that the copy from cf-staging to conda-forge on anaconda.org is a simple HTTP request made to anaconda.org once the package data has been validated. We never download and reupload packages. So to make the ghcr stuff work on our webservices instance, you'll need to find a similar HTTP API endpoint. A similar HTTP endpoint also needs to return the package hash for validation. |
I am trying to figure out what would be needed to move forward with the GitHub OCI upload:
I am relatively new in the world of OCI registries, so forgive me if I am confusing things :) but I tried to look into the specs to find such an API endpoint. The open-container spec mentions an endpoint which might be helpful to avoid a download-reupload "If a necessary blob exists already in another repository within the same registry, it can be mounted into a different repository via a POST request [...]" |
Sure that looks promising but I know nothing about OCI registries. I'll leave this to you and @wolfv to work out. Ideally, we could wrap the copy in the conda oci package @wolfv has going so it is easy to use. We have some security requirements here related to tokens that I will share with @wolfv privately once the copy is working. |
I've been thinking about this and doing some research. This is not a definitive assessment but a work in progress. I am not saying all the following is a good idea, but at least it takes us to the realm of what's feasible today. The main concern right now is how to do staging in a safe way. conda-forge uses the Staging serves two purposes then:
How do we do this with OCI artifacts? The limitations are:
So, all in all, I think that we can run everything off the
Footnotes
|
|
That repo ( About visibility, I read a bit more into it and, while it could work, we must notice that:
So we would have to upload it as private, then run the validation and either publish as public or delete. I don't know if the amount of packages marked as "private" count towards some kind of quota but hopefully the number of artifacts that are marked as such at a given time is a small one.
Correct, that's my proposal so far.
Maybe a repo like |
We discussed this approach in the monthly bot meeting and Matt raised a point I had not considered: the
|
@Hind-M and I met with @wolfv today and discussed potential alternatives: Staging:
Repodata publication:
Some other notes:
|
I'm not sure what the difference with this approach and using a cronjob at channel-mirros to download from anaconda.org and push to |
Because we want to do it independently from anaconda.org. |
Checklist
0
(if the version changed)conda-smithy
(Use the phrase@conda-forge-admin, please rerender
in a comment in this PR for automated rerendering)