Skip to main content

Turbonomic Plan Engine

Project description

vmt-plan: Turbonomic API plan engine

vmt-plan is a companion library to vmt-connect for working with the Turbonomic API. The core purpose of the library is to provide interfaces for constructing and running plans within Turbonomic.

Installation

pip install vmtplan

Usage

# Basic Plan - Note the import is vmtplanner <!>
import vmtconnect as vc
import vmtplanner as vp

vmt = vc.Session(host='localhost', username='bob', password='*****')

# scoping to two groups by UUID
scope = ['430e28cbaabf35522a180859d4160562d123ac78',
        'e48fd3270917221d3e6290e1affead34b872e95b']
scenario = vp.PlanSpec('custom scenario', scope=scope)

# add 5 copies of a VM immediately using positional arguments
scenario.change_entity(vp.EntityAction.ADD, ['1341c28a-c9b7-46a5-ab25-321260482a91'], [0], 5)

# add 1 copy each month for 2 months using named arguments
scenario.change_entity(action=vp.EntityAction.ADD,
                      targets=['1341c28a-c9b7-46a5-ab25-321260482a91'],
                      count=1,
                      projection=[30, 60])

plan = vp.Plan(vmt, scenario)
plan.run()

Documentation

The user guide is a good place to start. Detailed documentation is also available here.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

vmtplan-2.3.0.tar.gz (25.1 kB view hashes)

Uploaded Source

Built Distribution

vmtplan-2.3.0-py3-none-any.whl (60.4 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page