Bug 1482498 - Unable to edit image
Summary: Unable to edit image
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Node
Version: 3.4.0
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
: 3.4.z
Assignee: Maciej Szulik
QA Contact: DeShuai Ma
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-08-17 12:29 UTC by Jaspreet Kaur
Modified: 2017-09-07 19:13 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Cause: Differences in representation of image object between internal and versioned, specifically the docker image metadata field. Consequence: You can't oc edit image. Fix: ImageStreamTag allows editing only annotations, but that works only with oc annotate or oc patch command which specifically say what's edited. When oc edit is being invoked it trips over the internal Image object of an IST, due to differences between internal and external representations of this object. This approach allows setting patchStrategy on struct objects, so they can be ignored, here deleted. Result: oc edit image works without any problems.
Clone Of:
Environment:
Last Closed: 2017-09-07 19:13:34 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2017:2670 0 normal SHIPPED_LIVE OpenShift Container Platform 3.5 and 3.4 bug fix update 2017-09-07 23:13:17 UTC

Description Jaspreet Kaur 2017-08-17 12:29:04 UTC
Description of problem: Getting an error while editing image annotation

> while editing image,
> oc annotate --overwrite image sha256:c48070e4d8ec99d81170664aa8938dc2152e3c2fe4297bc511131e24f3ad6489 images.openshift.io/deny-execution=false
> 
> i get error:
> Error from server: unable to find api field in struct RawExtension for the json field "Parent" or 
> Error from server: unable to find api field in struct RawExtension for the json field "Id" or
> Error from server: unable to find api field in struct RawExtension for the json field "config"


Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results: It fails to edit the image


Expected results: It should suceed

Additional info:

Works in 3.5

Seems related to :

https://bugzilla.redhat.com/show_bug.cgi?id=1403134

and https://github.com/openshift/origin/issues/9232

Comment 4 DeShuai Ma 2017-08-30 09:43:52 UTC
Verify on openshift v3.4.1.44.17
kubernetes v1.4.0+776c994
etcd 3.1.0-rc.0

Steps:

[root@host-8-241-64 ~]# oc get images sha256:0119197c041e44c530b4dedaea4182a69b23426e0b8f7a0e87e340bf7bad25dd
NAME                                                                      DOCKER REF
sha256:0119197c041e44c530b4dedaea4182a69b23426e0b8f7a0e87e340bf7bad25dd   registry.access.redhat.com/jboss-amq-6/amq63-openshift@sha256:0119197c041e44c530b4dedaea4182a69b23426e0b8f7a0e87e340bf7bad25dd
[root@host-8-241-64 ~]# oc annotate --overwrite image sha256:0119197c041e44c530b4dedaea4182a69b23426e0b8f7a0e87e340bf7bad25dd images.openshift.io/deny-execution=false
image "sha256:0119197c041e44c530b4dedaea4182a69b23426e0b8f7a0e87e340bf7bad25dd" annotated

Comment 5 DeShuai Ma 2017-08-30 09:48:37 UTC
[root@openshift-135 ~]# oc version
oc v3.4.1.44.11
kubernetes v1.4.0+776c994
features: Basic-Auth GSSAPI Kerberos SPNEGO

Server https://openshift-135.lab.sjc.redhat.com:8443
openshift v3.4.1.44.11
kubernetes v1.4.0+776c994
[root@openshift-135 ~]# oc get images sha256:0119197c041e44c530b4dedaea4182a69b23426e0b8f7a0e87e340bf7bad25dd
NAME                                                                      DOCKER REF
sha256:0119197c041e44c530b4dedaea4182a69b23426e0b8f7a0e87e340bf7bad25dd   registry.access.redhat.com/jboss-amq-6/amq63-openshift@sha256:0119197c041e44c530b4dedaea4182a69b23426e0b8f7a0e87e340bf7bad25dd
[root@openshift-135 ~]# oc annotate --overwrite image sha256:0119197c041e44c530b4dedaea4182a69b23426e0b8f7a0e87e340bf7bad25dd images.openshift.io/deny-execution=false
image "sha256:0119197c041e44c530b4dedaea4182a69b23426e0b8f7a0e87e340bf7bad25dd" annotated

Comment 7 errata-xmlrpc 2017-09-07 19:13:34 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2017:2670


Note You need to log in before you can comment on or make changes to this bug.