Setup Openstack Python Clients on CentOS

From Tech Wiki
Jump to navigation Jump to search

To set up and install the clients follow the below steps:

Create a file in /etc/yum.repos.d called rdo-release.repo

And place the following inside it:

name=OpenStack Liberty Repository

Then create another file in /etc/yum.repos.d called rdo-testing.repo

And place the following in it:

name=OpenStack Liberty Testing

Then to install the correct packages use the following command:

for i in nova keystone neutron heat cinder glance ; do sudo yum install python-${i}client -y ; done

Then create a file called my.rc in /root containing the following:

export OS_TENANT_NAME="Project-XXX"
export OS_AUTH_URL=
export OS_USERNAME="User.Name"
export OS_PASSWORD="myreallysecurepassword"

To get your details visit and look for the following:

Openstack Details.PNG

The Tenant ID is the long string of characters.

The Tenant Name is the Project Name

The Username and password are your login details.

Once the file has been set up with the correct details you will need to perform the following command every time you launch a new shell to set the environment variables:

source /root/my.rc

You could also place the contents of my.rc into your .bashrc file so the variables are launched on boot preventing you from having to source the file every time.

Once this has been done you can then perform commands such as the following:

nova list

For the full lists of commands you can use:

nova help
keystone help
neutron help
cinder help
heat help
glance help

You can also get help for a specific command using:

nova help command