Vagrant helpers

fabtools.vagrant.version()[source]
Get the Vagrant version.
fabtools.vagrant.sshconfig(_name=’’)[source]
Get the SSH parameters for connecting to a vagrant VM.
fabtools.vagrant.vagrant[source]
Run the following tasks on a vagrant box.
First, you need to import this task in your fabfile.py:
from fabric.api import from fabtools.vagrant import vagrant @task def sometask(): run(‘echo hello’)
Then you can easily run tasks on your current Vagrant box:
$ fab vagrant some_task
**fabtools.vagrant.vagrant_settings(_name=’’
, _
args, kwargs_)[source]
Context manager that sets a vagrant VM as the remote host.
Use this context manager inside a task to run commands on your current Vagrant box:
from fabtools.vagrant import vagrantsettings with vagrant_settings(): run(‘hostname’)
**fabtools.vagrant.status(_name=’default’
)[source]
Get the status of a vagrant machine
fabtools.vagrant.machines()[source]
Get the list of vagrant machines
fabtools.vagrant.base_boxes()**[source]
Get the list of vagrant base boxes