What version of crane are you running, and what are your clusters+platform:
crane: main branch
OpenShiftPlugin: v0.0.4
Source: OpenShift 4.x (cam-src)
Destination: OpenShift 4.x (cam-tgt)
Description:
ImageStreamTag resources exported from the source namespace should be whited
out by the OpenShiftPlugin during transform, similar to ImageTag (#25).
What actually happened?
ImageStreamTag survives both transform stages and ends up in the final
output. When applied on the destination after the destination registry has
already received the image (e.g. via skopeo copy during image migration),
kubectl apply fails with:
Error from server (BadRequest): ...
imagestreamtag v1 is not a spec tag in imagestream <ns>/<is>,
cannot be updated
Why it should be whited out:
ImageStreamTag is a server-managed projection that the OpenShift API server
populates from registry push events. Once image bytes land on the destination
registry, the destination's ImageStreamTag is created automatically pointing
at the correct digest, applying a migrated copy on top of it is rejected.
Same architectural pattern as ImageTag (#25): the destination recreates it,
the migration shouldn't carry it.
Reproduction steps:
- Deploy an app with a manually-pushed image on source (no BuildConfig)
crane export --namespace=<ns>
crane transform --stage 10_KubernetesPlugin
crane transform --stage 20_OpenShiftPlugin
crane apply
- On destination: create the namespace, apply the empty ImageStream
skopeo copy source digest → destination registry
kubectl apply -f output/resources/<ns>/ImageStreamTag_*.yaml
- Observe:
imagestreamtag <tag> is not a spec tag in imagestream <ns>/<is>, cannot be updated
Expected fix:
OpenShiftPlugin should add ImageStreamTag to its whiteout list during
transform, alongside the proposed ImageTag whiteout in #25.
Related:
What version of crane are you running, and what are your clusters+platform:
crane: main branch
OpenShiftPlugin: v0.0.4
Source: OpenShift 4.x (cam-src)
Destination: OpenShift 4.x (cam-tgt)
Description:
ImageStreamTag resources exported from the source namespace should be whited
out by the OpenShiftPlugin during transform, similar to ImageTag (#25).
What actually happened?
ImageStreamTag survives both transform stages and ends up in the final
output. When applied on the destination after the destination registry has
already received the image (e.g. via
skopeo copyduring image migration),kubectl applyfails with:Why it should be whited out:
ImageStreamTag is a server-managed projection that the OpenShift API server
populates from registry push events. Once image bytes land on the destination
registry, the destination's ImageStreamTag is created automatically pointing
at the correct digest, applying a migrated copy on top of it is rejected.
Same architectural pattern as ImageTag (#25): the destination recreates it,
the migration shouldn't carry it.
Reproduction steps:
crane export --namespace=<ns>crane transform --stage 10_KubernetesPlugincrane transform --stage 20_OpenShiftPlugincrane applyskopeo copysource digest → destination registrykubectl apply -f output/resources/<ns>/ImageStreamTag_*.yamlimagestreamtag <tag> is not a spec tag in imagestream <ns>/<is>, cannot be updatedExpected fix:
OpenShiftPlugin should add ImageStreamTag to its whiteout list during
transform, alongside the proposed ImageTag whiteout in #25.
Related: