OpenStackClient is a command-line client for OpenStackOpenStackClient (aka OSC) is a command-line client for OpenStack that brings the command set for Compute, Identity, Image, Object Storage and Block Storage APIs together in a single shell with a uniform command structure.
First of all make sure you have python 2.7 or later installed.
Install pip on the machine using the command matching your operating system.
After pip is installed you can install the python-openstack client by running the following command.
If you don`t want to install it via pip it is possible to install it from packages. RDO, Debian, and Ubuntu have client packages that can be installed without pip.
- When you have a client installed you need to create an API user. To do this login to https://citycontrolpanel.com and click on API and then on "Native Openstack API"
- Here you will se current users and you can see all endpoints where to connect for different clients. Focus on the openstack client and wont bother with anything else for now.
- To create a new user click on the "+Add new user" button. Fill in the username and password for your user and drag the project you want that user to have access to into the correct box. Several projects can be chosen. Then Click on "Save".
- To be able to use the openstack client you have to authenticate with our new API user. To do this you first have to download an RC file. To do this click on the gear icon next to your API user and then on "Download RC-File"
- Download the file. Then yiu have to change the password in this file before doing anything else.
- When this is done we have to make sure our client program can find the OS_ variables. To do this we need to source the file. Simply run "source openstack.rc" in a terminal and after that you are good to go. Try running an openstack command.
- Installation is now done and you can start to use the different openstack commands.
You can find some examples of Openstack commands to use here: https://docs.openstack.org/ocata/user-guide/cli-cheat-sheet.html