-
Notifications
You must be signed in to change notification settings - Fork 47
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
Ensure golden images do not return digests #43
Comments
The layer information is used in many outputs, so the digest (here on imgbom text ouput) changes:
The for _, l := range img.Layers {
l.Metadata.Digest = "sha256:ad8ecdc058976c07e7e347cb89fa9ad86a294b5ceaae6d09713fb035f84115abf3c4a2388a4af3aa60f13b94f4c6846930bdf53"
} |
@wagoodman should these values always be stubbed out? |
fair question, I'm not certain. I know for images that are not committed to the repo, this will be an unstable field, thus, always useless. However, I think that When implementing this we'll have to keep this in mind, otherwise I think it is safe to assume that these fields should always be stubbed. Maybe provide another helper where this behavior is more apparent in the name? |
Another helper does sound like the best path forward here, given that we can't have keyword arguments with defaults in Go. |
Currently the
GetFixtureImage
will return the build image intact, however, the digests should be stubbed out as they will always change (https://app.circleci.com/pipelines/github/anchore/imgbom/29/workflows/e36d826e-0885-4408-bdbc-a3413c2db023/jobs/70/steps)The text was updated successfully, but these errors were encountered: