os-image modifier in python-tripleoclient causes conflict with OS_IMAGE from glance

Bug #1693344 reported by Yolanda Robla
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
tripleo
Fix Released
High
Yolanda Robla

Bug Description

When using the --os-image command from python-tripleoclient, that gets translated into the OS_IMAGE env var:

757 parser.add_argument(
758 "--os-image",
759 default=os.environ.get('OS_IMAGE', 'overcloud-full.qcow2'),
760 help=_("OpenStack disk image filename"),

But when we try to use it, we are getting this error:

image version overcloud-full.qcow2 is not in supported versions 1, 2
Invalid image client version 'overcloud-full.qcow2'. must be one of: 1, 2

That is actually because OS_IMAGE env var ends somehow being part of os_client_config in the openstackclient:

{'auth_type': 'password', 'beta_command': False, 'tripleoclient_api_version': '1', u'compute_api_version': u'2', 'key': None, u'database_api_version': u'1.0', 'metrics_api_version': '1', 'data_proce
ssing_api_version': '1.1', 'inspector_api_version': '1', 'auth_url': 'http://192.168.24.1:5000/v2.0', u'network_api_version': u'2', u'message': u'', u'image_format': u'qcow2', 'networks': [], u'imag
e_api_version': u'overcloud-full.qcow2' }

This bug has been tested with stable/newton

Changed in tripleo:
status: New → Triaged
importance: Undecided → High
milestone: none → pike-2
Revision history for this message
Yolanda Robla (yolanda.robla) wrote :

I can confirm that this happens in Ocata as well

Changed in tripleo:
milestone: pike-2 → pike-3
Changed in tripleo:
assignee: nobody → Pranali Deore (pranali-deore)
Revision history for this message
Yolanda Robla (yolanda.robla) wrote :

How is progress on it? Will it land for Pike? It is blocking the ability to upload different overcloud-full.qcow2 images, as the image name cannot be specified. So without that, we cannot use different images per role, as no clean way to upload them.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to python-tripleoclient (master)

Fix proposed to branch: master
Review: https://review.openstack.org/480036

Changed in tripleo:
status: Triaged → In Progress
Changed in tripleo:
assignee: Pranali Deore (pranali-deore) → Yolanda Robla (yolanda.robla)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to python-tripleoclient (master)

Reviewed: https://review.openstack.org/480036
Committed: https://git.openstack.org/cgit/openstack/python-tripleoclient/commit/?id=dd5cb7885c7bc3534aa194a9612a45cff8bf2531
Submitter: Jenkins
Branch: master

commit dd5cb7885c7bc3534aa194a9612a45cff8bf2531
Author: PranaliD <email address hidden>
Date: Tue Jul 4 12:34:51 2017 +0530

    Modified --os-image option in overcloud image upload

    While using --os-image option in overcloud image upload command
    from python-tripleoclient, it was getting translated somehow
    into the OS_IMAGE env variable which was causing conflict.

    Changed os-image to os-image-name to avoid the conflict.

    Change-Id: Id55c838714263c0f886a7402ab72dfb1820cee7c
    Closes-Bug: 1693344

Changed in tripleo:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to python-tripleoclient (stable/ocata)

Fix proposed to branch: stable/ocata
Review: https://review.openstack.org/484626

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to python-tripleoclient (stable/ocata)

Reviewed: https://review.openstack.org/484626
Committed: https://git.openstack.org/cgit/openstack/python-tripleoclient/commit/?id=8ea64c4ec6117854828ac6b23eb53ea1acfec92d
Submitter: Jenkins
Branch: stable/ocata

commit 8ea64c4ec6117854828ac6b23eb53ea1acfec92d
Author: PranaliD <email address hidden>
Date: Tue Jul 4 12:34:51 2017 +0530

    Modified --os-image option in overcloud image upload

    While using --os-image option in overcloud image upload command
    from python-tripleoclient, it was getting translated somehow
    into the OS_IMAGE env variable which was causing conflict.

    Changed os-image to os-image-name to avoid the conflict.

    Change-Id: Id55c838714263c0f886a7402ab72dfb1820cee7c
    Closes-Bug: 1693344
    (cherry picked from commit dd5cb7885c7bc3534aa194a9612a45cff8bf2531)

tags: added: in-stable-ocata
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/python-tripleoclient 7.2.0

This issue was fixed in the openstack/python-tripleoclient 7.2.0 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/python-tripleoclient 6.2.1

This issue was fixed in the openstack/python-tripleoclient 6.2.1 release.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.