konflux-ci / rpm-lockfile-prototype

GNU General Public License v3.0
3 stars 10 forks source link

Add a Dockerfile to build and publish the image #34

Open vdemeester opened 1 month ago

vdemeester commented 1 month ago

The idea is to push an image to ghcr.io so that one can just run podman run -v … ghcr.io/konflux-ci/… … instead of having to use venv or manage our own image.

This is probably not the best implementation — maybe we could rely on podman only and a Containerfile or something, and just use the metadata and login command to ease pushing to ghcr.io.

lubomir commented 1 month ago

I like this. I'm not sure the way the build is hooked into the current action is very good though. It's a matrix build on multiple fedora containers (to get different python versions). This PR would build and push the container from each of them. It would likely be nicer to just have this as a separate check that builds and pushes the image.

lubomir commented 1 month ago

I merged this change in a separate PR with additional commit to make the build a separate job. The action ran, but it failed to push the image: https://github.com/konflux-ci/rpm-lockfile-prototype/actions/runs/10505287664/job/29102535128

#10 ERROR: failed to push ghcr.io/konflux-ci/rpm-lockfile-prototype/rpm-lockfile-prototype:main: unexpected status from POST request to https://ghcr.io/v2/konflux-ci/rpm-lockfile-prototype/rpm-lockfile-prototype/blobs/uploads/: 403 Forbidden

@vdemeester , do you know what's wrong?

vdemeester commented 1 month ago

Ah, there might be some options in the settings of the repository to allow the actions to push to the registry (I need to check on other repositories what settings I did set) 🤔

vdemeester commented 1 month ago

2024-08-22-145639 Could be this one 🤔

lubomir commented 1 month ago

I don't know. I tried re-running the job, but it failed in the same way. I don't have access to the repository settings, so I can't try anything else there.

vdemeester commented 1 month ago

I don't know. I tried re-running the job, but it failed in the same way. I don't have access to the repository settings, so I can't try anything else there.

Ah damn… not sure what to do then 🤔

lubomir commented 1 month ago

I have reverted the changes for now as the job isn't working.