Skip to content
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

Provide promotion trigger information in the promotion context #3708

Open
1 of 3 tasks
schildwaechter opened this issue Mar 25, 2025 · 3 comments
Open
1 of 3 tasks

Provide promotion trigger information in the promotion context #3708

schildwaechter opened this issue Mar 25, 2025 · 3 comments

Comments

@schildwaechter
Copy link

Checklist

  • I've searched the issue queue to verify this is not a duplicate feature request.
  • I've pasted the output of kargo version, if applicable.
  • I've pasted logs, if applicable.

Proposed Feature

Provide all the events associated to a promotion in the context, in particular the trigger.
Currently, the events view shows lines such as the following.

  • Automatically promoted Freight from origin "Warehouse/XXXXX" for Stage "YYYYY"
  • Promotion created for Stage "ZZZZZ" by "admin"

These should be available to re-use in the promotion steps, in particular for Git commit messages.

Motivation

This would allow better traceability of why Kargo is making changes.
This would allow to propagate reasons for changes to other systems, such as logging infrastructure or to include them in the git commit history.

Suggested Implementation

The ctx.promotion context could be extended with the message that's sent to the events view. Alternatively, the information on whether it's an automated or manual promotion and which user triggered it, could be added as individual properties.

@hiddeco
Copy link
Contributor

hiddeco commented Mar 25, 2025

Related to #3081

@schildwaechter
Copy link
Author

With the implementation from #3592, the user triggering the promotion becomes available and in cases of auto-promotion it's empty, so that's very nice already.
However, I would still suggest to add an attribute explicitly stating it's an automatic promotion for the purposes of tracebility.
Might also be worth to make the freight's alias available.

@krancour
Copy link
Member

Might also be worth to make the freight's alias available

Those mutable, so they're not the best thing to use in any sort of historical record.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants