agent: log injected version string at startup#5722
Conversation
|
Hi team! Just checking in on this patch — it adds a startup log line to the agent that prints the injected version string, helping validate build provenance and patch testing.
Would appreciate a quick review or workflow approval when possible. Thanks for your time! |
|
Thanks, but this doesn't look right. The version is stored at |
|
@qwerty287 Thanks for the feedback! I've updated the patch to use Let me know if you'd like any further changes! |
|
Thanks, please revert any change that is not related.
Checkout the diff to see how your change currently looks like, then you'll see what's wrong. Also, I'd put the log statement into cmd/agent/core/agent.go. |
|
@qwerty287 Thanks for the detailed feedback! I think i've made the required changes:
Let me know if anything else needs adjustment! |
|
that was the wrong now server and cli have no way of knowing what version they are 😅 |
|
@6543 yeah, thanks for pointing that out man. I misunderstood the version.go context — happy to restore version reporting properly. Would you prefer I reintroduce the version string via |
|
it's already done so via our build chain just use it, doesnt have to be as complex ;) |
|
Line 40 in 1432037 |
|
yeah, do you need me to do something else in this? i'm kinda new to open source, so don't know much how all that works. |
|
Just reverting all the changes except |
28084ce to
5a15d4d
Compare
|
@qwerty287 i made a commit, is it good now? |
|
Sorry, but no. All the files in the diff (you can see that in the files tab) except |
|
@qwerty287 bro, this branch is messed up, i created another branch and opened another pr #5724 so check that out |
This patch adds a startup log line to the Woodpecker agent that prints the injected version string.
-ldflagsto injectVersionat build timezerologinmain.goExample output:
{"level":"info","message":"Woodpecker Agent Version: localtest"}
This supports contributor validation for Issue #5685.