pgcat icon indicating copy to clipboard operation
pgcat copied to clipboard

Publish tagged releases to a container registry

Open jawnsy opened this issue 2 years ago • 5 comments

Is your feature request related to a problem? Please describe. A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

There's a workflow that builds container images and publishes them to GitHub's container registry. However, even though there are version tags (and the build runs with those tags), the versioned tags are not published.

Describe the solution you'd like A clear and concise description of what you want to happen.

It would be nice to have tags we can use, like: ghcr.io/postgresml/pgcat:1, ghcr.io/postgresml/pgcat:1.0.0, ghcr.io/postgresml/pgcat:1.1.0, etc.

Describe alternatives you've considered A clear and concise description of any alternative solutions or features you've considered.

We can pin to a digest and always use the latest tag, but it's a lot less straightforward to know when a given release is "recommended" (users generally assume that tagged releases are better than "whatever the latest main branch build is")

Additional context Add any other context or screenshots about the feature request here.

jawnsy avatar Jul 25 '23 22:07 jawnsy

We tried to do this recently, but apparently it didn't work: https://github.com/postgresml/pgcat/pull/508

A PR for this is absolutely welcome.

levkk avatar Jul 25 '23 22:07 levkk

it looks like that the CI was triggered correctly: https://github.com/postgresml/pgcat/actions/runs/5659957126/job/15334598381

Should we add so many tags. Checking current setup we will generate a tag for:

  • Each commit hash
  • nightly
  • tag
  • branch
  • pr id
  • lastest that will point to the latest build of the main branch

Is not the case just to:

  1. use latest for the latest stable tag?
  2. use edge to the latest commit?
  3. a tag for every new tag in the project?

sebastianwebber avatar Aug 05 '23 03:08 sebastianwebber

@sebastianwebber @levkk if you want to I can open a PR with this suggestions next week.

mpfeil avatar Aug 05 '23 11:08 mpfeil

I'm not too familiar with how Docker generates its metadata using the plugin, but looking at the last run from a few weeks ago, the only tag being built is the hashed tag:

image

It only has one tag output (ghcr.io/postgresml/pgcat:1f2c6507f7fb5461df1a599c0b380aa114597bb5), and I'd have expected there to be multiple tags (the hash, latest, as well as a versioned tag)

Only the tags for latest, the branch (main), and the hash seem to be making it to the repository for some reason:

image

jawnsy avatar Aug 22 '23 03:08 jawnsy