You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Bug: registry host is dropped from image names, so ghcr.io / quay.io / mcr.microsoft.com images are looked up on Docker Hub #578
Both parseDockerfile and parseDockerCompose in src/core-open/scanners/docker-scanner.ts build the row name as ${parsed.namespace || 'library'}/${parsed.image}, ignoring parsed.registry from parseDockerImage (src/core-open/scanners/docker-cache.ts). So:
ghcr.io/acme/api:1.4.0 is recorded as acme/api
mcr.microsoft.com/dotnet/sdk:8.0 is recorded as dotnet/sdk
quay.io/prometheus/node-exporter:v1.8.0 is recorded as prometheus/node-exporter
and each is then compared with whatever Docker Hub has under that name, which can be a different image entirely. Two images with the same path on different registries also collapse into one row.
What to do
Keep the registry in the recorded name for non-Docker-Hub images (Docker Hub stays library/<image> / <ns>/<image> as documented in DOCS.md).
Only query Docker Hub for Docker Hub images; leave others with drift unknown (or a registry lookup if one already exists) rather than a wrong Hub answer.
Add unit tests for Dockerfile and Compose inputs.
Acceptance
The three examples above keep their registry in the row name.
None of them triggers a Docker Hub tag lookup.
nginx:1.27 and bitnami/redis:7.4 behave exactly as today.
Confirmed on main: both parsers build the row name as `${parsed.namespace || 'library'}/${parsed.image}` and drop parsed.registry, and scanDocker then sends every name to fetchDockerVersionsBulk, which is a Docker Hub lookup.
Two pieces to watch: (1) keep the registry in the name only when it's set and isn't a Docker Hub alias (docker.io, index.docker.io, registry-1.docker.io), and (2) filter non-Hub names out before the bulk fetch so they keep drift unknown instead of a wrong answer. This depends a little on #587, since parseDockerImage currently mis-splits host:port registries, so a test with ghcr.io/... and mcr.microsoft.com/... is the safest place to start.
I'd like to take this one. I'll add a shared dockerRowName() in docker-cache.ts that keeps the registry host unless it is a Docker Hub alias (docker.io, index.docker.io, registry-1.docker.io), and use it in both parsers plus the cache key, so the existing non-Hub guard in fetchDockerLatestVersion finally sees the registry. Tests cover your three examples, compose, the aliases, the same path on two registries, and a registry port.
Activity
vibgrate-team commentedon Nov 4, 2026
Confirmed on
main: both parsers build the row name as`${parsed.namespace || 'library'}/${parsed.image}`and dropparsed.registry, andscanDockerthen sends every name tofetchDockerVersionsBulk, which is a Docker Hub lookup.Two pieces to watch: (1) keep the registry in the name only when it's set and isn't a Docker Hub alias (
docker.io,index.docker.io,registry-1.docker.io), and (2) filter non-Hub names out before the bulk fetch so they keep driftunknowninstead of a wrong answer. This depends a little on #587, sinceparseDockerImagecurrently mis-splitshost:portregistries, so a test withghcr.io/...andmcr.microsoft.com/...is the safest place to start.17302513901yh-lang commentedon Nov 8, 2026
I'd like to take this one. I'll add a shared
dockerRowName()indocker-cache.tsthat keeps the registry host unless it is a Docker Hub alias (docker.io,index.docker.io,registry-1.docker.io), and use it in both parsers plus the cache key, so the existing non-Hub guard infetchDockerLatestVersionfinally sees the registry. Tests cover your three examples, compose, the aliases, the same path on two registries, and a registry port.fix(docker): keep registry hosts on non-Hub image names (vibgrate#599)