-
-
Notifications
You must be signed in to change notification settings - Fork 86
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
add OCI labels, rework tagging #361
Conversation
Signed-off-by: Achim Krämer <[email protected]>
Thanks for opening this PR. I am happy to add the labels, but I would prefer to stick with the current state of the tagging code. It took me ages to get this going and I just could not understand how the metadata action is expecting me to configure it, which is why the custom script is there. As I'll have to keep maintaining this I'd like to keep what I understand. Or does your patch fix anything that is broken in this regard? As far as I understand we can add the labels without changing the tagging logic, right? |
Signed-off-by: Achim Krämer <[email protected]>
Thanks! No, my patch doesn't fix somethink broken, after looking into this and reading the manuals i just found this solution some kind of easier and more streamlined. Since i haven't run the workflow, i couldn't test this fix yet and i don't know how to do this without setting up the workflow in my fork as well. Until i figured this out and tested this, i'll change the PR, so that the action only adds the labels, and the tag will be provided by your current workflow-step. |
Thanks! |
I just released an image using this for the first time and when inspecting the image, some values are double quoted "Labels": {
"org.opencontainers.image.created": "2024-02-15 UTC 11:05:49",
"org.opencontainers.image.description": "\"Backup Docker volumes locally or to any S3, WebDAV, Azure Blob Storage, Dropbox or SSH compatible storage\"",
"org.opencontainers.image.documentation": "\"https://offen.github.io/docker-volume-backup/\"",
"org.opencontainers.image.licenses": "\"MPL-2.0\"",
"org.opencontainers.image.revision": "a01fc3df3f7030569661e324687d6ae97bc84d1d",
"org.opencontainers.image.source": "https://github.com/offen/docker-volume-backup",
"org.opencontainers.image.title": "docker-volume-backup",
"org.opencontainers.image.url": "\"https://offen.github.io/docker-volume-backup/\"",
"org.opencontainers.image.vendor": "offen",
"org.opencontainers.image.version": "v2.37.3"
} Is this expected or should we do something about it? |
Seems the docs are using unqoted literal strings https://github.com/docker/metadata-action?tab=readme-ov-file#inputs |
You're right - the correct syntax would be without quotes: Should i send a commit to fix this? |
Already did that, thanks #365 |
i'm using Renovate to automatically update dependencies. Renovate (and similar tools as well) support the docker label
org.opencontainers.image.source
, also known as OCI labels to point to sources and add the release notes in the created PRs --> see for example a PR for tandoor:I noticed, that this docker-volume-backup currently doesn't leverage these labels and implemented them.
When possible i tried to stick to variables instead of hardcoding informations to keep the package dynamically, in case someone forks and wants to distribute it by himself.
Furthermore i kind of reworked the tagging code and replaced it with the popolur github-action metadata-action.
I stuck with the current logic and implemented a rule, that e.g. the tag
v2.15.4-alpha.2
doens't get thelatest
-tag.See the full documentation for the semver-mapping.
I look forward to improvements, reviews and tips!