Show version of Go when building Secure analyzers
Problem to solve
Secure analyzer projects implemented in Go are build using a multi-stage Dockerfile that uses golang:X.YZ as a base image, making it difficult to know what version of Go was used to build one particular version of the analyzer (one particular Docker image).
See #284643 (closed) for more on why this is needed.
Proposal
Update the build script the multi-stage Dockerfile relies on to build the Go project, and make it report the version of Go.
After Remove duplication from secure analyzer Dockerfiles has been completed, this is as simple as adding go version to the shared build script.
Implementation plan
-
add go versionto the build script introduced in #289983
Is this a cross-stage feature?
This applies to Category:Container Scanning so it applies to the entire sectionsec section.
Links / references
Edited by Fabien Catteau