Currently, the developers machine is the holy kingdom in delivering the features and solutions of your company. In front there is the developers IDE and in the back the server, services, queue system and the database. In a multi project setup with branches there are now multiple servers, services and queue systems and databases or just one server and database. Either the developer switches services between projects or redeploys any time he switches the project's context.
In any way it seems cumbersome and it is cumbersome and especially it's a waste of time. Although starting a complex application server running on a developer's machine can be easy as typing:
$ vagrant init mycompany/websphere-7
$ vagrant up
The installation and configuration complexity now plays out for each team member and just multiplies. Now let's put that effort inside vagrant boxes and distribute them throughout the team! Actually Backend servers and services should be installed and maintained inside vagrant boxes. I have seen this approach fail in teams. The reasons are manifold:
* The installation process is often not reproduce able and not transparent for team members. There is a lack of trust and team members tend to fall back to old procedures.
* The time to setup a virtual machine in a non automatic manner is very costly. It hurts if it breaks, corrupts or does not boot anymore. Next time team members will fall back to old procedures.
* The virtual machine is maintained and supported by someone that has a tight schedule. Team members can not wait for updates and fall back to old procedures.
* Discordance: Some team members like virtual machines done with Virtualbox but others would never work without VMWare.
Vagrant is a tool where the installation process itself can be scripted or in Vagrant slang "Provisioned". Vagrant is a management console for creating, starting and stopping "Providers" which can be popular virtual machine technologies like Virtualbox, VMWare, Docker and many more. Furthermore, Boxes can be maintained as composites, e.g. managing servers and databases as local clusters. What's left is a powerful host machine but that should be granted for a serious developer.
Realizing a Vagrant box for Websphere, JBoss, MySQL, DB2, PostgreSQL, MongoDB is no wasted effort. It can be easily scripted by console commands inside the Vagrantfile and put under source control and version management. It also supports popular scripting languages like Puppet, Chef, Salt and Ansible. This can be done by team members or operation specialists. The installation is transparent and highly editable.
The Box itself is handled like the software you produce. It is usually enough to simply provision the box by your team. You can also pay external specialists in order to do the provisioning for you and then use review tool in order to accept the installation procedure. Remember, you pay for transparent and readable Vagrantfiles and installation scripts.
$ vagrant up
Boxes can be versioned for any development scenario, projects and customers:
$ vagrant init myimages/mongodb https://myrespository/myimages/mongodb/versions/2.4.14
$ vagrant up
The whole stack can be implemented inside your company, behind your firewall and in accordance with your operational guidelines. The tools are free to use and open source. My personal preference for an on-premise solution is the following technology stack:
- Gitlab as the Git Source/Version Control System.
- Jenkins as the CI- and Build-System with Build Slaves for Vagrant boxes.
- Artifactory the Artifact Repository for Vagrant Boxes.
- Virtualbox as the free Open Source VM-Technology.