VBox
License: BSD.
Yet another Python library of Python bindings for Virtual Box CLI (Command Line Interface).
Motivation
It appears that VirtualBox binary API is rather unstable, while CLI interface is quite stable. Plus, using binary interface means that one has to compile bindings library for particular host being used. This can be not as simple as it should be on some systems (e.g. Windows). Binary bindings are also of a concern when packaging ones’ program in to the redistributable packages.
To the best of my current knowledge, the only competing project worth noting is pyvb. But it seems to be rather dead at the moment with last release dating back to the 2008. And its GPL license is sadly not really suitable for my current needs.
Features
The main difference of this library of bindings is that I am making “smart” objective bindings rather just set of Python functions that call corresponding CLI commands.
I am attempting to hide as much of low-level VM management as possible and to represent all VM–related entities (NICs, HDDs, etc. ) as Python objects with functions of their own and properties parsed to their corresponding Python objects. Plus, I am attempting to make more consistent interface than VirtualBox’es CLI is.
Requirements
Just a reasonably recent version of Python.
How do I use it?
Deployment
You should be able to install this project via easy_install vbox route.
Alternatively, you can include this library as git submodule. If you do that, please make sure to include this projects’ release branch, not master. As release is the one that will contain versions of code that were actually released to the VBox pypy package page , so you will get automatic code updates than, but won’t get all the frustration of me accidentally breaking something via committing stuff to the master branch (that is development/testing branch).
API
I will write this part eventually. Please refer to the VBox tests for now.
Creating VM
VM with no drives and default amounts of RAM for the selected OS type is created with the following command:
import vbox
vm = vbox.VM(
vbox.General(
name="foo",
osType="Windows95",
),
vbox.Storage(),
)
VM with 10gb HDD and an empty DVD drive
import vbox
vm = vbox.VM(
vbox.General(
name="foo",
osType="Windows95",
),
vbox.Storage(
api.HDD(size=10*1024),
api.DVD(),
),
)
VM object API
vm.start()
vm.powerOff()
vm.wait(timeout=None) – wait for machine to get from running state to some other state.
Contributions
Please do feel free to email me your suggestions on how to improve this library. Just email me (address can be found in the setup.py file or just googled for).
Can I has code?
Sure. That is why I am hosting VBox on the GitHub. :-)
Metadata
Release files for vbox 0.2.5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| vbox-0.2.5.zip | 36.1 kB | Without provenance | Details for vbox-0.2.5.zip |
Built distributions (wheels)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| vbox-0.2.5.win-amd64.exe | Details for vbox-0.2.5.win-amd64.exe | |||
| vbox-0.2.5-py2.7.egg | Legacy Egg format | - | - | Details for vbox-0.2.5-py2.7.egg |
Total release size: 462.7 kB
Release files / vbox-0.2.5.zip
| Download URL | vbox-0.2.5.zip |
|---|---|
| Size | 36.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
fa4d37cc3e545c9ecc9dada62d8e65142d8a1faa75a6a8ce8f8355a04090265c
|
|
BLAKE2b-256 checksum How to use checksums |
ef05ccc27b006d83653decc5f1c6abfb90cd828178769eabf23f2b1c6d09d8ed
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Release files / vbox-0.2.5.win-amd64.exe
| Download URL | vbox-0.2.5.win-amd64.exe |
|---|---|
| Size | 281.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
15b71b8dfded09a5eaa1021c7ad2ac8dbe80522ccd2d8873e8ef60ba1d9c90f4
|
|
BLAKE2b-256 checksum How to use checksums |
09e60cfdf0712e511814e0d41745214a5f2796de2b39ff18aab534725b91b1d8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Release files / vbox-0.2.5-py2.7.egg
| Download URL | vbox-0.2.5-py2.7.egg |
|---|---|
| Size | 145.0 kB |
| Tags | Egg |
|
SHA-256 checksum How to use checksums |
44ff041ce8075ff3bcd8fbb7ac6ab2dc31ea0328f54472665af1955cef1a44a3
|
|
BLAKE2b-256 checksum How to use checksums |
32381e297b1be7cf5af762680e686dad9734cee1f02e411c2c095c0c50df670e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for vbox 0.2.5
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.