Description
Recently, containers without an image tag has been encountered by watchtower users:
- Containers created with
docker compose
cannot be updated #1019 - Watchtower causes a cron crash on Ubuntu when checking for updates #1026
- Watchtower crashes when containers with hash-only images are encountered #1037
- Non-standard image refs does not map to expected repositories in config.json #796 (comment)
Since the containers' configurations does not contain the necessary information for updating, watchtower cannot check for updates or recreate them.
Since #1027 (available in watchtower:latest-dev
) it should at least no longer crash, but just skip said containers.
One source of these containers seem to be docker compose
(with no dash), but it's unclear whether they can be created in some other fashion (you could of course just manually specify the sha256:xxx
hash in docker run
, but then, what would you expect?)
To verify that containers does not have any named image, you can run docker ps
:
$ docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
fb0c2a735c38 4cdc5dd7eaad "/docker-entrypoint.…" 18 minutes ago Up 20 seconds 80/tcp
In the second column (IMAGE
), instead of the image tag, it shows just a short image id hash.
I made a PoC attempting to retrieve the image tag based on the ID, and it is possible to do so under some conditions, but it's highly volatile.
If this is a permanent change in future Docker versions, it may render watchtower unusable... 😩
Add a comment if you know anything more about the source of these containers!