Project

General

Profile

Actions

Bug #17317

closed

Associating docker tag with incorrect docker manifest.

Added by Thomas McKay over 7 years ago. Updated almost 6 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Container
Target version:
Fixed in Releases:
Found in Releases:

Description

When a manifest changes for a tag and the repo is synced, existing tag relations incorrectly point to this new manifest.

To reproduce:
+ start a local registry (thomasmckay-desktop.usersys.redhat.com:5000 in this example)
docker run --rm -it -p 5000:5000 registry:2

+ create dockerfiles
v1/Dockerfile
FROM registry.access.redhat.com/rhel7/rhel
RUN echo "Here we go, vertigo" > sounds.txt
ENTRYPOINT ["cat", "sounds.txt"]

v2/Dockerfile
FROM katello.example.com:5000/examplecorp-production-test-for-echo-test-for-echo-test-for-echo:v1
RUN echo "Video vertigo" >> sounds.txt
RUN echo "Test for echo" >> sounds.txt
ENTRYPOINT ["cat", "sounds.txt"]

+ build v1 and push to local registry
docker build --tag thomasmckay-desktop.usersys.redhat.com:5000/thomasmckay/test-for-echo:v1 v1
docker push thomasmckay-desktop.usersys.redhat.com:5000/thomasmckay/test-for-echo

+ create docker repo test-for-echo and sync thomasmckay-desktop.usersys.redhat.com:5000/thomasmckay/test-for-echo
note 1 tag, 1 manifest

+ create content view w/ this repo

+ publish cv and promote to lifecycle env

+ visit docker tags page and note environments present

+ build v2 image, push, and resync repo
docker build --tag thomasmckay-desktop.usersys.redhat.com:5000/thomasmckay/test-for-echo:v2 v2

+ re-publish cv
note 2 tags, 2 manifests
note docker tags page correct

+ tag v2 as v1, push to local registry, resync repo, publish cv
docker tag b80dafd4d227 thomasmckay-desktop.usersys.redhat.com:5000/thomasmckay/test-for-echo:v1
docker push thomasmckay-desktop.usersys.redhat.com:5000/thomasmckay/test-for-echo
note 2 tags, 3 manifests
note docker tags page for v1 shows it in Library, Default Organization View, and Production (my lifecycle env)

From the UI there is no way to tell that these are different images for the same tag:
Library and Default Organzation View = new v1
Production = original v1

There should be 3 tags in katello, with the 2 v1 tags pointing to separate manifests.

This makes it impossible to use katello as a way to manage images.

Actions

Also available in: Atom PDF