Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: turbonomic/vmt-connect
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v3.2.0
Choose a base ref
...
head repository: turbonomic/vmt-connect
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: master
Choose a head ref
Loading
19 changes: 19 additions & 0 deletions .bumpversion.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
[bumpversion]
current_version = 3.6.2
commit = False
parse = (?P<major>\d+)\.(?P<minor>\d+)\.(?P<patch>\d+)(\.(?P<release>[a-z]+)(?P<build>\d*))?
serialize =
{major}.{minor}.{patch}.{release}{build}
{major}.{minor}.{patch}

[bumpversion:part:release]
optional_value = prod
first_value = dev
values =
dev
prod

[bumpversion:file:vmtconnect/__about__.py]

[bumpversion:file:docs/source/conf.py]

4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -8,3 +8,7 @@ scratch
tests
*.pyc
vmtconnect.egg-info
archive
resources
bin
docs/source/_build
28 changes: 28 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# vmt-connect: Turbonomic API Connection Wrapper

*vmt-connect* is a user-friendly wrapper around the second generation Turbonomic
API. The wrapper provides useful helper functions for handling general tasks within
the API, such as searching, filtering, and error checking. This module is not
intended to be a full API client implementation.


## Installation

```bash
pip install vmtconnect
```

## Usage

```python
import vmtconnect as vc

conn = vc.Connection('localhost', 'administrator', '<password>')
vms = conn.get_virtualmachines()
print([x['displayName'] for x in vms])
```

## Documentation

The [user guide](https://turbonomic.github.io/vmt-connect/userguide.html) is a
good place to start. Detailed documentation is also available [here](https://turbonomic.github.io/vmt-connect).
41 changes: 0 additions & 41 deletions README.rst

This file was deleted.

4 changes: 4 additions & 0 deletions docs/Makefile
Original file line number Diff line number Diff line change
@@ -7,6 +7,7 @@ SPHINXBUILD = python -msphinx
SPHINXPROJ = vmt-connect
SOURCEDIR = source
BUILDDIR = ../../vmt-connect-docs
LINKCHECKDIR = source/_build/linkcheck
#PYTHONPATH = ../

#export PYTHONPATH
@@ -18,6 +19,9 @@ help:
clean:
@echo "Clean disabled."

linkcheck:
@sphinx-build -b linkcheck "$(SOURCEDIR)" "$(LINKCHECKDIR)"

.PHONY: help Makefile clean

# Catch-all target: route all unknown targets to Sphinx using the new
12 changes: 12 additions & 0 deletions docs/field.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
https://tabatkins.github.io/railroad-diagrams/generator.html

ComplexDiagram(
Comment('field'),
NonTerminal('string'),
Optional(
Sequence(
'[',
Choice(0, Skip(), '*', NonTerminal('slice')),
']'),
'skip')
)
8 changes: 8 additions & 0 deletions docs/filter.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
https://tabatkins.github.io/railroad-diagrams/generator.html

ComplexDiagram(
Comment('filter'),
NonTerminal('field'),
Optional(Group(OneOrMore(Sequence('.', NonTerminal('field'))), 'child'), 'skip'),
Optional(Group(OneOrMore(Sequence(',', NonTerminal('field'))), 'sibling'), 'skip'),
)
8 changes: 8 additions & 0 deletions docs/slice.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
https://tabatkins.github.io/railroad-diagrams/generator.html

ComplexDiagram(
Comment('slice'),
Optional(Group(NonTerminal('integer'), 'start'), 'skip'),
Optional(Sequence(':', Optional(Group(NonTerminal('integer'), 'stop'), 'skip'), Optional(Sequence(':',
Optional(Group(NonTerminal('integer'), 'step'), 'skip')), 'skip')), 'skip'),
)
64 changes: 64 additions & 0 deletions docs/source/_static/action.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
[
{
"uuid": "9223304850035275760",
"actionImpactID": 9223304850035276000,
"createTime": "2020-08-04T12:21:44-04:00",
"actionType": "RIGHT_SIZE",
"actionState": "PENDING_ACCEPT",
"actionMode": "MANUAL",
"details": "Scale down VMem for VirtualMachine cert58 from 14 GB to 12 GB",
"importance": 0,
"target": {
"uuid": "421c5dac-3d10-6d6d-2183-5c01f7b2ace9",
"displayName": "cert58",
"className": "VirtualMachine",
"discoveredBy": {
"uuid": "_UFCnUMYUEeqw6vcwGrTNAw",
"displayName": "vcenter.demo.example.com",
"type": "vCenter",
"readonly": false
}
},
"currentEntity": {
"uuid": "_lmEJ8tZuEeqG6vS3wpTEow",
"className": "VMem"
},
"newEntity": {
"uuid": "_t9Euw9dLEeqG6vS3wpTEow",
"className": "VMem",
"aspects": {
"virtualMachineAspect": {
"os": "Linux (Free)",
"type": "VMEntityAspectApiDTO"
}
}
},
"currentValue": "14680064.0",
"newValue": "12582912.0",
"resizeToValue": "12582912.0",
"stats": [
{
"name": "costPrice",
"filters": [
{
"type": "savingsType",
"value": "savings"
}
],
"units": "$",
"value": 100
}
],
"currentLocation": {
"uuid": "a600946a2bdb36c3527fa57bd35a5b8db76dd552",
"displayName": "DemoDC",
"className": "DataCenter"
},
"newLocation": {
"uuid": "a600946a2bdb36c3527fa57bd35a5b8db76dd552",
"displayName": "DemoDC",
"className": "DataCenter"
},
"actionID": 3208600312656
}
]
125 changes: 125 additions & 0 deletions docs/source/_static/rrfield.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading