We are pleased to announce we released the ITS Cloud API v3.13.1 with the following improvements and bug fixes:
Improvements
VM/SCSI support sharing mode (create, update) (#1431)
Endpoints
- /v2/vm/<vm-id>/controller/scsi (POST)
- /v2/vm/<vm-id>/controller/scsi/<bus>/sharing (PUT)
- /v2/vss/vm-disk-scsi-controller-sharing (GET)
Description
SCSI controllers now support advanced settings such as sharing for both new controllers and existing controllers. SCSI controllers can be created using the following payloads:
["lsilogic", "paravirtual"]
[ {"type": "lsilogic"}, {"type": "paravirtual", "sharing": "virtualSharing"} ]
Supported sharing is available in the following resource.
This is NOT a breaking change. Current method to create SCSI controllers with a list of SCSI types is still supported. The API will transform the list of valid capacities into objects.
VM/Disk support backing_mode in disk payload (create and update disk) (#1432)
VM/Disk support backing_sharing in disk payload (create and update disk) (#1433)
Endpoints
- /v2/vm/<vm-id>/disk (POST)
- /v2/vm/<vm-id>/spec (GET)
- /v2/vm (POST)
Description
Before this version, disks were created by providing an array or list of numbers which defined the new disk capacity, however in some cases there might be the need of creating a disk with a different backing mode such as independent_persistent or which are excluded from snapshots and make the revert or removal faster.
From now on, disk definition support two payloads:
[40, 500]
[ {"capacity_gb": 40}, {"capacity_gb": 500, "backing_mode": "independent_persistent" } ]
With this improvement, a disk can be created with a given backing mode from the beginning instead of creating the disk and then updating the backing mode to a desired setup. If backing_mode is not included, defaults persistent.
This is NOT a breaking change. Current method to create disks with a list of numbers is still supported. The API will transform the list of valid capacities into objects.
Advanced configuration also supports backing_sharing modes in the disk specification as follows:
[ { "backing_mode": "persistent", "backing_sharing": "sharingnone", "capacity_gb": 10 }, { "backing_mode": "independent_persistent", "backing_sharing": "sharingnone", "capacity_gb": 100 }, { "backing_mode": "persistent", "backing_sharing": "sharingnone", "capacity_gb": 200 } ]
Supported sharing is available in the following resource.
VM/Add last_powered_on, last_powered_off, last_shutdown_on and decommissioned_on attributes (#1437)
Endpoints
- /v2/vm
Description
Virtual Machine summary provides last_powered_on, last_powered_off, last_shutdown which are updated based on VSS API tasks or vSphere events.
Bug Fixes
VM/Remove VSS option from vm causes ValueError: list.remove(x): x not in list (#1434)
Endpoints
- /vm/<vm-id>/vss/option/<option> (DELETE)
VM/Performance throws IndexError: list index out of range when performance manager not providing metrics (#1435)
Endpoints
- /vm/<vm-id>/performance (GET)
VM/Release IP issues when decommissioning a VM (#1435)
Endpoints
- /vm/<vm-id> (DELETE)
VSS-CLI v0.9.0 is available for download viaΒ PyPIΒ orΒ GitLab. Latest version includes the following improvements and bug fixes:
Improvements
core
:Β pyvss
Β v0.15.1 -> v0.16.0 (#358)
οΈcompute vm set controller scsi up --sharing
: update SCSI sharing mode (#359)
Commands:
compute vm set controller scsi up
For example
vss-cli compute vm set vm-2177 controller scsi up --sharing nosharing 0
οΈcompute vm set disk up --sharing
: update Disk sharing mode (#360)
Commands:
compute vm set disk up
For example
vss-cli compute vm set vm-2177 disk up --sharing sharingnone 1
compute vm set controller scsi mk
: create SCSI controller with new spec <type>=<sharing>
. (#361)
Commands:
compute vm set controller scsi mk
For example
# backwards compatibility # defaults: # type to persistent # sharing to nosharing vss-cli compute vm set vm-2177 controller scsi mk --scsi paravirtual # new scsi spec vss-cli compute vm set vm-2177 controller scsi mk --scsi paravirtual=virtualsharing
compute vm set disk mk
: create Disk with new spec <capacity>=<backing_mode>=<backing_sharing>. (#362)
Commands:
compute vm set disk mk
For example
# backwards compatibility # defaults: # backing_mode to persistent # backing_sharing to sharingnone vss-cli compute vm set vm-2177 disk mk --disk 100 # new disk spec vss-cli compute vm set vm-2177 disk mk --disk 100=independent_persistent=sharingnone
compute vm mk:
create vm with Disks new spec <capacity>=<backing_mode>=<backing_sharing>. (#363)
Commands:
compute vm mk shell
compute vm mk from-clone
compute vm mk from-file
compute vm mk from-image
compute vm mk from-template
For example
# backwards compatibility # defaults: # backing_mode to persistent # backing_sharing to sharingnone vss-cli compute vm set vm-2177 disk mk --disk 100 # new disk spec vss-cli compute vm set vm-2177 disk mk --disk 100=independent_persistent=sharingnone
--wait/--no-wait
: add option to the main cli instead of per sub-command that submits requests.Β (#364)
Description:
This change provides the ability to better handle the --wait/--no-wait option for the global cli context instead of per sub-command. The --wait/--no-wait option is also settable via VSS_WAIT_FOR_REQUESTS environment variable.
Commands:
vss-cli
For example
vss-cli --wait compute vm set vm-2177 state on # or VSS_WAIT_FOR_REQUESTS=1 vss-cli compute vm set vm-21777 state on
config set
: add wait_for_requests
option in general settings in configuration file (config.yaml). (#364)
Description:
After running for the first time v0.9.0 of the VSS-CLI the wait_for_requests option in the configuration file will show up and can be set by either executing either one of the following commands:
Commands:
configure set wait_for_requests 1
configure edit
For example
vss-cli configure set wait_for_requests 1 Updating wait_for_requests from True -> True. ~/.vss-cli/config.yaml updated πΎ # or vss-cli configure edit general: check_for_updates: true check_for_messages: true default_endpoint_name: vss-api-dev debug: false output: auto table_format: simple timeout: 60 verbose: false columns_width: -1 wait_for_requests: true ...
compute
: remove --wait/--no-wait
option from the following commands (#364)
Description:
Since now the --wait/--no-wait option lives at the main cli level, it has been removed from the following subcommand contexts:
Commands:
compute vm set
compute vm mk
compute vm rm
compute template rm
compute folder set
compute folder mk
compute folder rm
compute inventory mk
For example
vss-cli --wait compute inventory mk id : 25 status : SUBMITTED task_id : 4b877caa-c64c-487d-b797-9e65459f23cc message : Request has been accepted for processing β³ Waiting for request 25 to complete... π Request 25 completed successfully: warnings : Inventory Report has been created 9d8a8f86-9f69-4428-b39a-1acf3870cd99.csv errors : Would you like to download? [y/N]: y FILE : ./9d8a8f86-9f69-4428-b39a-1acf3870cd99.csv