woodpecker-ci / woodpecker

Woodpecker is a simple, yet powerful CI/CD engine with great extensibility.
https://woodpecker-ci.org
Apache License 2.0
4.07k stars 353 forks source link

Incorrect version of agent #2236

Closed zc-devs closed 1 year ago

zc-devs commented 1 year ago

Component

agent

Describe the bug

Agent image builds with next-* version instead of tag/release. Server version is OK.

System Info

{"level":"info","time":"2023-08-17T11:47:41Z","message":"Starting Woodpecker server with version '1.0.2'"}
{"level":"info","time":"2023-08-17T12:01:26Z","message":"Starting Woodpecker agent with version 'next-d9e06696' and backend 'kubernetes' using platform 'linux/amd64' running up to 1 pipelines in parallel"}

Additional context

No response

Validations

6543 commented 1 year ago

It's probably already fixed by #2229 ... but I have to make sure ...

6543 commented 1 year ago

to check run: docker run -it --rm woodpeckerci/woodpecker-agent:v1.0.2 --version ... 😆

zc-devs commented 1 year ago

The same:

PS C:\> docker run -it --rm woodpeckerci/woodpecker-agent:v1.0.2 --version
Unable to find image 'woodpeckerci/woodpecker-agent:v1.0.2' locally
v1.0.2: Pulling from woodpeckerci/woodpecker-agent
40a02314b6d4: Pull complete
743de8f4c793: Pull complete
4f4fb700ef54: Pull complete
Digest: sha256:d2e92a0b5ad91ea43ee3ef3fab70850b3da3bf68c3d6604a7e06101499d8db28
Status: Downloaded newer image for woodpeckerci/woodpecker-agent:v1.0.2
woodpecker-agent version next-d9e06696
6543 commented 1 year ago

well of course ... should mention this was a note for others if they wana check too

6543 commented 1 year ago

cli image is also affected

6543 commented 1 year ago

it's an issue since v0.15.0 ... I assume it's because docker build by default does not forward CI_COMMIT_TAG env var ...

6543 commented 1 year ago

for the server this works as we have a different build step in this case

6543 commented 1 year ago

-> https://github.com/woodpecker-ci/woodpecker/pull/2238