Too young too simple and too naive


fabric to deploy vagrant env

14 Apr 2013

Vagrant is a great tool that lets you create and destroy virtualbox vms. I will use fabric to the deployment stack, I will do all the fine grained post-install and post-configure tasks with it.

Below is step by step guide:

$ vagrant add box precise32

from fabric.api import *
def vagrant():
    result = local('vagrant ssh-config | grep IdentityFile', capture=True)
    env.key_filename = result.split()[1].trip('\"')
def uname():
    run('uname -a')
comments powered by Disqus