overcloudrc should not be managed by the CLI

Bug #1615720 reported by Tomas Sedovic
24
This bug affects 4 people
Affects Status Importance Assigned to Milestone
tripleo
Fix Released
Medium
Dougal Matthews

Bug Description

The `openstack overcloud deploy` command generates the overcloudrc file which contains the environment variables necessary to interact with the deployed OpenStack.

Right now, that code lives in python-tripleoclient and is unavailable to the GUI. This is true even with the current Mistral patches.

Generating overcloudrc would be a useful thing for the GUI as well and moving this logic outside of tripleoclient will help reduce the disparity between the command line and web interfaces.

Tomas Sedovic (tsedovic)
Changed in tripleo:
importance: Undecided → Medium
tags: added: tripleoclient
Dougal Matthews (d0ugal)
Changed in tripleo:
assignee: nobody → Dougal Matthews (d0ugal)
milestone: ongoing → ocata-1
Revision history for this message
Dougal Matthews (d0ugal) wrote :

At the moment tripleoclient creates two different overcloudrc files. overcloudrc and overcloudrc.v3. The second is for KeyStone v3. The two files look like this:

[stack@instack ~]$ cat overcloudrc
# Clear any old environment that may conflict.
for key in $( set | awk '{FS="="} /^OS_/ {print $1}' );do unset $key ; done
export OS_NO_CACHE=True
export OS_CLOUDNAME=overcloud
export OS_AUTH_URL=http://192.0.2.11:5000/v2.0
export NOVA_VERSION=1.1
export COMPUTE_API_VERSION=1.1
export OS_USERNAME=admin
export OS_PASSWORD=9EgEvRtzKfEVhA748mcJcXc8B
export no_proxy=,192.0.2.11,192.0.2.11
export OS_PROJECT_NAME=admin
export PYTHONWARNINGS="ignore:Certificate has no, ignore:A true SSLContext object is not available"

[stack@instack ~]$ cat overcloudrc.v3
# Clear any old environment that may conflict.
for key in $( set | awk '{FS="="} /^OS_/ {print $1}' );do unset $key ; done
export OS_NO_CACHE=True
export COMPUTE_API_VERSION=1.1
export OS_USERNAME=admin
export no_proxy=,192.0.2.11,192.0.2.11
export OS_USER_DOMAIN_NAME=Default
export OS_PROJECT_DOMAIN_NAME=Default
export OS_CLOUDNAME=overcloud
export OS_AUTH_URL=http://192.0.2.11:5000/v3
export NOVA_VERSION=1.1
export OS_PROJECT_NAME=admin
export OS_IDENTITY_API_VERSION=3
export OS_PASSWORD=9EgEvRtzKfEVhA748mcJcXc8B
export PYTHONWARNINGS="ignore:Certificate has no, ignore:A true SSLContext object is not available"

so they are similar, but contain a few obvious differences. How should this be handled from Mistral? Should be action return JSON with both? Something like this?

{"overcloudrc": "....", "overcloudrc.v3": "...."}

Changed in tripleo:
milestone: ocata-1 → ocata-2
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to tripleo-common (master)

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

Changed in tripleo:
status: Triaged → In Progress
Revision history for this message
Dougal Matthews (d0ugal) wrote :

We will also likely need a new CLI command to just generate the overcloudrc files. This would be for times when users deploy with the GUI and then switch to the CLI - they wont have any overcloudrc files unless they saved them from the GUI. The command could look something like this:

    openstack overcloud generate rc

... except I don't like that name. Ideas?

Revision history for this message
Brad P. Crochet (brad-9) wrote :

@d0ugal agreed that we need a command and agreed that the name is not ideal. :) Nothing off the top of my head ATM.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to tripleo-common (master)

Reviewed: https://review.openstack.org/397211
Committed: https://git.openstack.org/cgit/openstack/tripleo-common/commit/?id=8aa57e2715b6988625981f4c93b693a0746ce7cb
Submitter: Jenkins
Branch: master

commit 8aa57e2715b6988625981f4c93b693a0746ce7cb
Author: Dougal Matthews <email address hidden>
Date: Mon Nov 14 13:28:02 2016 +0000

    Move the overcloudrc generation from tripleoclient to a Mistral action

    This change moves the code from tripleoclient to a new Mistral action.

    Partial-Bug: #1615720
    Change-Id: I1302dcfa83ee9eed8ebe721536dfc454b5da5b6c

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to tripleo-common (stable/newton)

Fix proposed to branch: stable/newton
Review: https://review.openstack.org/410255

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

Fix proposed to branch: stable/newton
Review: https://review.openstack.org/410272

Changed in tripleo:
milestone: ocata-2 → ocata-3
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on tripleo-common (stable/newton)

Change abandoned by Dougal Matthews (<email address hidden>) on branch: stable/newton
Review: https://review.openstack.org/410255

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

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

commit 3c8223cd5ed04ed12549a5ff9fe34ba4a05e82ea
Author: Dougal Matthews <email address hidden>
Date: Thu Nov 17 12:23:54 2016 +0000

    Use the overcloudrc generated in a Mistral action

    This removes the code responsible for creating the action in
    tripleoclient and replaces it with a call to a Mistral action.

    Closes-Bug: #1615720
    Change-Id: I33627cd3661193c0e7ac7fab174cfcbac6c8ab43

Changed in tripleo:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on python-tripleoclient (stable/newton)

Change abandoned by Dougal Matthews (<email address hidden>) on branch: stable/newton
Review: https://review.openstack.org/410272

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on tripleo-common (stable/newton)

Change abandoned by Dougal Matthews (<email address hidden>) on branch: stable/newton
Review: https://review.openstack.org/410255

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to tripleo-common (stable/newton)

Reviewed: https://review.openstack.org/410255
Committed: https://git.openstack.org/cgit/openstack/tripleo-common/commit/?id=f59d9d8664ee20fe522ef09757b2e6399b2d98ce
Submitter: Jenkins
Branch: stable/newton

commit f59d9d8664ee20fe522ef09757b2e6399b2d98ce
Author: Dougal Matthews <email address hidden>
Date: Mon Nov 14 13:28:02 2016 +0000

    Move the overcloudrc generation from tripleoclient to a Mistral action

    This change moves the code from tripleoclient to a new Mistral action.

    Closes-Bug: #1649576
    Partial-Bug: #1615720
    Change-Id: I1302dcfa83ee9eed8ebe721536dfc454b5da5b6c
    (cherry picked from commit 8aa57e2715b6988625981f4c93b693a0746ce7cb)

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

Reviewed: https://review.openstack.org/410272
Committed: https://git.openstack.org/cgit/openstack/python-tripleoclient/commit/?id=21f21fda4a4dd7888e67c8fc341710beec8d9e44
Submitter: Jenkins
Branch: stable/newton

commit 21f21fda4a4dd7888e67c8fc341710beec8d9e44
Author: Dougal Matthews <email address hidden>
Date: Thu Nov 17 12:23:54 2016 +0000

    Use the overcloudrc generated in a Mistral action

    This removes the code responsible for creating the action in
    tripleoclient and replaces it with a call to a Mistral action.

    Closes-Bug: #1615720
    Change-Id: I33627cd3661193c0e7ac7fab174cfcbac6c8ab43
    (cherry picked from commit 3c8223cd5ed04ed12549a5ff9fe34ba4a05e82ea)

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

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

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

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

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

Duplicates of this bug

Other bug subscribers

Remote bug watches

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