-
Notifications
You must be signed in to change notification settings - Fork 120
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
SOURCE_DATE_EPOCH
is not respected
#403
Labels
Comments
Sounds good thanks |
4 tasks
I think that this is related to the code in src/meta.ts : this.date = new Date(); For now, I have a little workaround : - id: git-timestamp
run: echo "iso8601=$(git log -n1 --pretty=%cI)" >> "${GITHUB_OUTPUT}"
- uses: docker/[email protected]
id: meta
with:
labels: "org.opencontainers.image.created=${{ steps.git-timestamp.outputs.iso8601 }}" |
will #471 works for you? |
looks like they are not same, but it will help fixing this issue |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Description
metadata-action
does not seem to honor theSOURCE_DATE_EPOCH
env variable when generating labels and annotations such asorg.opencontainers.image.created
. I know these can be overridden by the calling workflow, but it would be nice if the action supportedSOURCE_DATE_EPOCH
by default, for a better out-of-the-box experience.I'm not sure if
SOURCE_DATE_EPOCH
should also affect tags that use the{{date}}
expression. Personally I don't think it should. Maybe a new expression{{source_date_epoch}}
can be added that takes the timestamp from the env variable and formats it as specified, instead of using the current time, but this can be considered separately later.The text was updated successfully, but these errors were encountered: