Actions
Bug #21681
closedWrong docker tags copied over on publish
Description
- Create a docker hub account. (https://cloud.docker.com/)
- Install docker on a machine
- Run the following commands
docker login -u <username> docker.io docker pull alpine docker tag docker.io/alpine:latest docker.io/<username>/alpine:latest docker tag docker.io/alpine:latest docker.io/<username>/alpine:greatest docker push docker.io/<username>/alpine
- On your katello ui create a docker repo with the following data -> name: repo1, feed: https://registry-1.docker.io , upstream: <username>/alpine
- Sync repo1. Make sure you see a repo with 2 tags
- Now go to https://cloud.docker.com/swarm/<username>/repository/docker/<username>/alpine/tags and delete the "latest" tag
- On your katello ui create a docker repo with the following data -> name: repo2, feed: https://registry-1.docker.io , upstream: <username>/alpine
- Sync repo2. Make sure you see a repo with 1 tag
- Finally create a content view
- Add repo2 via Docker Content to the cv. Make sure its the repo that has 1 tag
- Create a Docker Content View Filter With the following data -> Type: Include
- Under Tags add a rule to only include the "greatest" tag
- Finally publish the content view and check out the published version
Expected:
A successful publish with 2 manifests and 1 Tag
Actual:
A successful publish but the manifest shows 2 Tags instead
A further look at the publish task and expanding "13: Actions::Pulp::Repository::CopyDockerTag (success) [ 1.82s / 0.39s ]"
will show the following clause.
--- source_pulp_id: f93edc01-4915-45c8-a484-e926c561949f target_pulp_id: 1-jonathan-v1_0-f93edc01-4915-45c8-a484-e926c561949f clauses: "$or": - name: "$in": - latest - greatest - greatest - greatest - greatest remote_user: admin remote_cp_user: admin locale: en
So even though the content filter should have only published "greatest" since the source repo had only the 'greatest' tag, we are ending up copying both "greatest" and "latest"
Updated by The Foreman Bot about 7 years ago
- Status changed from New to Ready For Testing
- Pull request https://github.com/Katello/katello/pull/7066 added
Updated by Partha Aji about 7 years ago
- Status changed from Ready For Testing to Closed
- % Done changed from 0 to 100
Applied in changeset katello|9b45392b655ff0c6ab81b800b7e6007d3faafa03.
Updated by Justin Sherrill about 7 years ago
- Translation missing: en.field_release set to 284
Actions