Install OpenStack client
The following step is installed for Mac OS X.
Note that on MacOS you need to wait for the Xcode CLI tools to finish to install first. and re-install the "six" package.
easy_install pip
pip uninstall six && easy_install six
pip install python-openstackclient
# wait for XCode CLI tools to install
pip install python-openstackclient
for project in nova neutron keystone cinder heat ceilometer swift glance
do
pip install python-$project"client"
done
Download and source the OpenStack RC file
- Log in to the dashboard and rom the drop-down list select the project for which you want to download the OpenStack RC file.
- On the Project tab, open the Compute tab click Access & Security.
- On the API Access tab, click Download OpenStack RC File v3 and save the file. The filename will be of the form PROJECT-openrc.sh where PROJECT is the name of the project for which you download the file.
- Copy the PROJECT-openrc.sh file to the computer from which you want to run OpenStack commands.
For example, copy the file to the computer from which you want to upload an image which a glance client command. - On any shell from which you want to run OpenStack commands, source the PROJECT-openrc-sh file for the respective project.
In the following example, the demo-openrc.sh file is sourced for the demo project:
$. demo-openrc.sh - When you are prompted for an OpenStack password, enter the password for the user who downloaded the PROJECT-openrc.sh file.
Since we now have single keystone to manage Linköping and Stockholm, you can find these two as two regions on the same dashboard.
Regions:
- RegionOne (Linköping)
- Stockholm
When RegionOne is selected, the OpenStack RC File v3 downloaded contains the region information.
If Stockholm is selected, the content will show as expected,
export OS_REGION_NAME="Stockholm"
You can refer the detail link as below:
http://docs.openstack.org/admin-guide/common/cli-install-openstack-command-line-clients.html
http://docs.openstack.org/admin-guide/common/cli-set-environment-variables-using-openstack-rc.html
Except where otherwise noted, this document is licensed under Creative Commons Attribution 3.0 License
Changes were made based on the original Openstack User guide
Comments
Article is closed for comments.