# OpenStack CLI

## Overview

<code class="expression">space.vars.product\_acronym</code> Compute, Block Storage, Network, and Identity services expose OpenStack APIs. You can use the [OpenStack CLI](https://docs.openstack.org/python-openstackclient/latest/cli/command-list.html) to perform a wider set of operations than the <code class="expression">space.vars.product\_name</code> UI supports.

This article covers how to install and configure the OpenStack CLI.

Alternatively, you can use `pcdctl`, which provides a convenient wrapper for all OpenStack CLI commands exposed by <code class="expression">space.vars.product\_name</code>services. For more information, see [PCD CLI (pcdctl)](https://docs.platform9.com/private-cloud-director/reference/pcdctl-command-line).

### **Install the OpenStack CLI**

Run the following command to install the OpenStack CLI on your local machine.

```bash
apt install python3-openstackclient -y
```

### **Authenticate the OpenStack CLI**

The <code class="expression">space.vars.product\_name</code> UI provides a `pcdctl RC` file configured for your <code class="expression">space.vars.product\_name</code> environment.&#x20;

You can use the same RC file with the OpenStack CLI.

1. In the <code class="expression">space.vars.product\_name</code> UI, navigate to **Settings** and select **API Access**.
2. Locate the `pcdctl RC` file listed on the page.
3. Copy the contents to a new file named `openstackrc` and update `OS_PASSWORD` with your <code class="expression">space.vars.product\_name</code> account password.
4. Run the following command to set the environment variables.

```bash
source openstackrc
```

### **Run the OpenStack CLI**

To verify your setup, run the following command to list all virtual machines in your current tenant.

```bash
openstack server list
```
