Description of problem: oc tag [source project/]<is name:tag1> [another destination project/]<is name:tag2> fails in the case described in summary Version-Release number of selected component (if applicable): oc v1.1.3-500-g115660e kubernetes v1.2.0-alpha.7-703-gbc4550d How reproducible: Always Steps to Reproduce: 1. oc login, create projects: xxia-proj1, xxia-proj2 2. Switch to xxia-proj1 and prepare an imagestream $ oc project xxia-proj1 $ oc tag --source=docker openshift/hello-openshift mystream:latest 3. Tag image to between 2 projects in the context of xxia-proj1. Omit or give project name(s): 1> oc tag xxia-proj1/mystream:latest xxia-proj2/stream:latest 2> oc tag mystream:latest mystream:tag1 3> oc tag xxia-proj2/stream:latest mystream:tag2 4> oc tag mystream:latest xxia-proj2/stream:tag1 Actual results: 3. 1> ~ 3>: All commands succeed. 4> Fails with following error The ImageStream "stream" is invalid. spec.tags[tag1].from.name: Not found: "mystream@sha256:dfcc619a443feb75eff04228942af3ff1f2efb580d78e097e0f10e75f93913fb" Expected results: 3. 4> Should also succeed Additional info:
Hm, I cannot seem to reproduce this bug: oc version: oc v1.3.0-alpha.0+1347137-dirty kubernetes v1.3.0+507d3a7 features: Basic-Auth 1. oc login, create projects: streamtags1, streamtags2 2. Switch to streamtags2 and prepare an imagestream $ oc tag --source=docker openshift/hello-openshift mystream:latest 3. Switch to streamtags1 and prepare an imagestream $ oc tag --source=docker openshift/hello-openshift mystream:latest 4. Tag image to between 2 projects in the context of streamtags1. Omit or give project name(s): 1> oc tag streamtags1/mystream:latest streamtags2/stream:latest 2> oc tag mystream:latest mystream:tag1 3> oc tag streamtags2/stream:latest mystream:tag2 4> oc tag mystream:latest streamtags2/stream:tag1 Actual Results: 4. 1> ~ 3>: All commands succeeded with same results as comment https://bugzilla.redhat.com/show_bug.cgi?id=1315625#c0 4> Command also succeeded with output: "Tag streamtags2/stream:tag1 set to mystream@sha256:b9b69935f23d56775aeb548d3aa526bd9cb53d8fa49faf4839f8b5eaf3dbe108."
Strictly follow comment 0 steps, error for "oc tag mystream:latest xxia-proj2/stream:tag1" is still reproduced. Strictly follow your steps in comment 0, "oc tag mystream:latest streamtags2/stream:tag1" indeed succeeds. The difference is: comment 1 has additional step "Switch to streamtags2 and prepare an imagestream". If skip this step, the error is then reproduced, as same as comment 0.
(In reply to Xingxing Xia from comment #2) > Strictly follow your steps in comment 0, "oc tag mystream:latest > streamtags2/stream:tag1" indeed succeeds. Sorry, a typo, should be "your steps in comment 1"
Thanks for the clarification. Related PR: https://github.com/openshift/origin/pull/10510
Verified in openshift v1.3.0-alpha.3+31f6add (also in OCP v3.3.0.24). Fixed. Comment 0 step 3.4 succeeds with output: Tag xxia-proj2/stream:tag1 set to mystream@sha256:...