20160330 DevOps series: Vagrant 1 -- What is Vagrant and what problem it tires to resolve

System Blog

DevOps series: Vagrant 1 -- What is Vagrant and what problem it tires to resolve


 

What Vagrant is?
It is a tool for building complete and identical development envrionments in a virtual machine, where it is compatible with VMware workstation and VirtualBox and EC2 (Amazon Elastic Compute Cloud).



What problems it tries to resolve?
A tool is used to resolved a problem.

if you don't have any issue on building development environment, then don't use it.


1 Build complete and identical development environment for a group of developers.

Two points here,
complete, Vagrant can be used all together with CM tools such as Ansible or Puppet, so to build a complete development environment is quick and automated (include both installation and configuration)


Identical, imagine that one dude checked out a dependent package developed by another developer from Nexus, imported into his project, sadly, it is not working, but the other developer claimed "it works fine on my computer"...sound familiar?


By saying identical, we are not just focus on dev environment among developers, but also focus on making dev environment as identical as production environment as we possibly can.

To prevent classic "I don't know, it works on my computer" (I will talk the power of using container to form immutable system in other article)


Does you developer looks like this when we deployed their code to Production



 

 

2 Be adaptive to technologies

Back to the old days, if you are a Java developer, all you need to setup is probably just JDK and a database of somebody's flavor

it is not the case today as new technology flux into the market, you will have to work on different project which using different set of technology (you might have to use different programming language even in the same project as micro-service is now on most decision makes' favorite book)


For instance, you might have to develop a python project by using 2.6 but another python project requires you to use python 3.4.

One project requires you to use nodejs, but another want you to use java

For sure you can have all of them installed on your computer, but it make your PC Fat and Slow, and you have to waste a great amount of time to make sure the environment setting for those projects are accurate as it has to be, that's probably not something we want to end up with

So you need some level of isolation for different projects, and desirably, make your development environment some sort of disposable.

So that you can shutdown one virtual machine and foget the apache/ruby on rails/mysql and concentrate on another VM which has JEE and DB2 installed, of course, once a project done, you can safely "destroy" the VM for this project without breaking anything.

 


To be continued

 

Posted by: leaonow on: Mar 30, 2016

 

Your Name:

OneTime Password:



Pic of the day