Closed parkedwards closed 6 months ago
Our contributing guide explains how to run our CI locally. That plus a rebase will likely get you through the remaining build errors.
Actually, it occurs to me that we could probably save the anonymous images by ID and the named ones by name to avoid the need for filtering? I think we may even be able to pull this off by using conditional expressions in the format string that we pass on the command line. Concretely, I am imagining that the only production change needed may be to set:
LIST_COMMAND = `docker image list --format '{{ if ne .Repository "<none>" }}{{ .Repository }}{{ if ne .Tag "<none>" }}:{{ .Tag }}{{ end }}{{ else }}{{ .ID }}{{ end }}'`
This will cause us to use the image name and tag when available, but fall back on the ID otherwise. I am assuming that Docker disallows tagging of anonymous images, but if it's possible to have an image with a tag but no name, then the template would need to be modified to handle that case. Here are the pertinent Docker docs, which link to the Go template syntax.
Superseded by #816, where I have implemented the strategy described in my previous comment.
relates to https://github.com/ScribeMD/docker-cache/issues/572
through local testing, i'm finding that using
docker save {{ .ID }}
actually anonymizes named images upondocker load
given this docker client behavior, i'm thinking we might just want to filter out the anonymous images (these aren't being cached currently anyway, due to the docker client not accepting
<none>:<none>
as a save-able image input)I dont see the tests running in CI/CD, so here's an output of
npm run test