OpenStack CLIs
OpenStack Client
OpenStackClient is a command-line client for OpenStack that brings the command set for many services (for example, Compute, Identity, Image, Object Storage and others) together in a single shell with a uniform command structure.
The recommended method of installation is by using pip
, but you can also install from a Linux distribution’s package manager (e.g. apt with Ubuntu), but you may not get the latest version.
Install the OpenStack Client with pip
Begin by installing the pip
package for your operating system.
Linux
Depending on your distrubution, the package installation method will vary.
For Ubuntu
or Debian
, the pip package could be installed by:
sudo apt install python-dev python3-pip
For Red Hat Enterprise Linux
, CentOS
or Fedora
:
yum install python-devel python3-pip
Mac OS
Mac OS users can use the easy_install
tool to install pip, and then a virtual environment:
sudo easy_install pip
sudo pip install virtualenv
Then create a virtual environment (first command), then activate it (second command).
virtualenv venv
source venv/bin/activate
Once you are finished using the OpenStack CLI and the virtual environment, you can exit by typing deactivate
in the terminal.
Microsoft Windows
Ensure that you have enabled Windows Subsystem for Linux by typing bash
in your Windows Terminal or Powershell first.
Pre-req check
If you have not installed Windows Subsystem for Linux yet, go back to the Overview page and do that now.
Now you can simply run the linux based command, and it will complete the install:
sudo apt install python-dev-is-python3 python3-pip
Finally, (all operating systems) install the OpenStack client package:
Once pip
is set up, you can install the client package with:
pip install python-openstackclient
Alternative: Install the OpenStack client package for your Linux distribution
It is only recommended to use this method if you are using the latest version of your Linux distribution.
For Ubuntu
or Debian
, the OpenStack client package could be installed by:
apt install python3-openstackclient