vagrant 1

by Malik BOUGACHA, EBU on 14 Sep 2013

Developpement sandboxing

Vagrant is a way to sandbox the devloppement environement. I will take python as an example of sandbox and explain how we come from a simple os based devloppement environement and test to a vm env.


Let's start with a simple machine environement


The being a very simple flask server:

from Flask import Flask 

app = Flask() 

if __name__ == "__main__": 

Great right ?
But what happens if we add more dependencies, for example requests, a python module for doing http request.

from Flask import Flask 
import requests 

app = Flask() 

def main(): 
    return request.get("").json() 

if __name__ == "__main__": 

The example is pretty simple right ? What does happen when we want to deploy it ? It will crash depending on the version of the requests module we have. As we have a stable version of debian, we don't have the right version of the library and of course we don't want to install it at a system wide level But there is a solution for this in python: virtualenv.

dependencies python vagrant virtualenv


  • Malik BOUGACHA

Recent posts

23 May 2016
OSCON 2016
Michael Barroco

15 Jan 2015
Version support
Frans De Jong

03 Jan 2015
Quality Wishes for 2015
Frans De Jong

22 Dec 2014

17 Dec 2014
Responsive QC
Frans De Jong

30 Sep 2014
Open Source Meetup at IBC

25 Mar 2014 - February Update
Michael Barroco

31 Jan 2014 - January Update
Michael Barroco