ITS Private Cloud CLI (vss-cli) Cheat Sheet
- 1 Global options
- 2 Global options (format)
- 3 Virtual Machine (update)
- 4 Virtual Machine (deployment)
- 5 Virtual Machine Snapshot
- 6 Virtual Machine Folders
- 7 Virtual Machine Inventory
- 8 Virtual Machine (restore)
- 9 Virtual Machine query
- 10 Virtual Machine query (advanced): The power of --columns with vss-cli
- 11 Decommission Virtual Machine
- 12 Initialize and Configure the vss-cli
- 13 Account MFA management
- 14 Account Notifications
- 15 Account Group Membership
- 16 OVF/OVA parsing
- 17 Raw requests
Global options
The following table includes global vss-cli
options related to account
username and password, API endpoint and MFA TOTP token.
Name | Option | Environment Variable | Description |
---|---|---|---|
Username |
|
| User to interact with the VSS API. |
Password |
|
| User password. |
MFA TOTP Token |
|
| If MFA enabled, will be prompted. |
Configuration Path |
|
| Alternative configuration path. |
Request Timeout |
|
| Request timeout in seconds. |
API endpoint |
|
| ITS Private Cloud endpoint instance. |
Global options (format)
The following table includes the global vss-cli
options to customize output format.
Name | Option | Environment Variable | Description |
---|---|---|---|
Table format to use |
|
|
|
Custom columns |
| - | Any VM attribute:
|
Truncates column values |
|
| 0: auto, -1: disable |
Don't use headers |
| - | When printing tables |
Sort output |
| - | Sort table by the jsonpath expression. |
Output |
|
|
|
Example 1. List virtual machines in yaml
format:
vss-cli --output yaml compute vm ls
Example 2. List virtual machines with only moref
, name
, cpu_count
, ip_address
with fancy_grid
in the table format.
vss-cli --columns moref,name,cpu_count,ip_address --table-format fancy_grid compute vm ls
Virtual Machine (update)
Manage virtual machine attributes with the vss-cli
.
Add --wait
to global vss-cli
and get immediate change request results.
Action | Description | Command |
---|---|---|
CPU | Update VM CPU count. | vss-cli compute vm set {id} cpu count {n} |
CPU hot-add | Update VM cpu hot-add settings. | |
Memory | Update VM memory size. | |
Memory hot-add | Update VM memory hot-add settings. | |
Disk New (basic) | Create single or multiple disks. | |
Power State: | Turn off, on, reset. Shutdown and reboot (VMware Tools required) | |
Disk New (adv.) | Create single or multiple disks using specific SCSI controller | |
Disk Copy (adv.) | Copy and attach disks to VM from | |
Disk Update | Update VM disk | |
Disk Update (adv.) | Update VM disk | |
Disk Delete | Delete VM disk(s). Confirmation will be prompted. | |
NIC New | Create new network interface specifying Network name. | |
NIC new (adv.) | Create new network interface specifying Network name and Type. | |
NIC Update Network: | Update network interface network. | |
NIC Update State | Update network interface state to either | |
NIC Update Type | Update network interface adapter type. defaults to | |
NIC Delete | Delete network interface adapter(s) | |
CD/ISO Create | Create CD drive with attached ISO image from Content Library or client. | |
CD/ISO Update | Update CD drive to connect to a different ISO or disconnect. | |
Floppy Drive Create | Create virtual floppy drive with given image or client. | |
Floppy Drive Update | Update virtual floppy backing with a different image or client. | |
Floppy Drive Remove | Remove virtual floppy | |
Storage Type | Update VM storage type to either | |
Domain | Update VM compute domain. This action will perform vMotion and storage vMotion. | |
Operating System | Update VM operating system settings. This setting is responsible to present the right virtual hardware to the guest OS. | |
Add vTPM | Add virtual Trusted Platform Module to VM. Virtualization Based Security, EFI and secure boot will be also en | |
Add vGPU | Add GPU to VM based on given profile. | |
Enable|Disable VBS | Enable or disable Virtualization Based Security. | |
Enable|Disable Secure Boot | Enable or Disable secure boot. | |
FIrmware | Update VM firmware to bios or EFI. | |
Convert to|from template | Mark VM as template or template as VM. | |
Administrator | Update VM admin metadata. | |
Informational Contacts | Add Informational Contacts in VM metadata. |
Virtual Machine (deployment)
Deploy virtual machines from content library, clone, template, shell, file specification and more.
Type | Description | Command |
---|---|---|
Content Library | Deploy a virtual machine from an OVA image with pre-installed operating system from our Content Library.
| Note. |
Shell VM | Deploy an empty virtual machine to be manually installed by the mounted iso. | |
Clone Virtual Machine or Deploy from Template | Clone virtual machine from another VM, template. | |
Deploy multiple Virtual Machine in batch | Deploy multiple virtual machines in a single command. | |
Clone Virtual machine from snapshot | Clone virtual machine from another VM snapshot id. | |
CLI Spec (existing) | Deploy a virtual machine from existing | |
CLI Spec (new) | Deploy a virtual machine from new | |
From Image |
| Note: Upload |
Retirement requests can be added to shell
, from-clone
, from-template
, from-clib
as follows: --retire-type {timedelta|datetime}
: Retirement request type. --retire-warning {n}
: Days before retirement date to notify. --retire-value {hours},{days},{months}
: Value for given retirement type.
Virtual Machine Snapshot
Virtual Machine Snapshot management:
Create virtual machine snapshot now |
Create virtual machine snapshot later |
List existing virtual machine snapshots |
Revert to existing virtual machine snapshots |
Remove existing virtual machine snapshot |
Extend virtual machine snapshot lifetime |
Remember that every change, new vm submission and snapshot request create a unique ID.
Virtual Machine Folders
Manage virtual machine vSphere folders.
Create Folder |
Rename Folder |
Move Folder with its contents |
Virtual Machine Inventory
Generate virtual machine inventory files.
Create Inventory File | |
Download Inventory File |
Virtual Machine (restore)
Restore virtual machine from ZFS snapshots. More information about Restore Requests available here: How-to Request Virtual Machine Restore
Action | Description | Command |
---|---|---|
Get Restore Points | List available restore points filtered by timestamp. | |
Submit Restore | Submit a restore request. |
Virtual Machine query
Action | Description | Command |
---|---|---|
List | List all virtual machines | |
Search | Search for vm by attribute | |
Attributes | Get additional info for specific attribute |
Virtual Machine query (advanced): The power of --columns
with vss-cli
Look for a VM by IP address |
List including storage type and preferences |
Decommission Virtual Machine
Show VM info before decommissioning |
Initialize and Configure the vss-cli
Initialize | |
List | |
Set |
Default configuration file is available at
Account MFA management
Enable MFA | |
Disable MFA | |
Verify |
Account Notifications
Format | |
Filter | |
Method |
Account Group Membership
Get Group membership | |
Get group details | |
Get group members |
OVF/OVA parsing
Get Deployment Option parameters | |
Generate additional-params spec | |
Get Property parameters |
Raw requests
For example:
University of Toronto - Since 1827