Skip to content

mbgiord/vagrant-mulesoft-devenv

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

A Vagrantized MuleSoft Development Environment

What is this?

This is a simple virtualized development environment that gets MuleSoft's Anypoint Studio up and running... FAST!

It is intended to get you started. It can easily be enhanced and configured to fit your specific requirements.

Sample Use Cases

  1. I want to kick the tires. I'm a technologist that's interested in MuleSoft. Seeing is believing. I've talked with people and read documentation but that's not good enough for me.
  2. I want to train people. I'm commited to MuleSoft as a technology and I need to educate my team. I don't want them to waste their time installing basic prerequisites.
  3. I want a common development environment. I'm a tech lead looking for consistency and efficiency. I don't want developers to ever use the excuse "it works on my machine"!

Success Criteria

Upon completion you will have two things:

  1. A fully functioning environment that includes the following technologies.

    Technology Purpose Version
    Chromium Web Browser See debian package
    debian Operating System jessie
    GIT Source Code Management See debian package
    Java JDK Software Platform 1.8
    Maven Java Build Tool See debian package
    MuleSoft Anypoint Studio Integrated Development Environment 6.4
    Mule Runtime Engine for Anypoint Platform (Server) 3.9
    lxde Desktop Environment See debian package
  2. A built and locally deployed MuleSoft application.

    Github Repository Branch Project
    mulesoft/anypoint-examples 3.9 hello-world

Prerequisites

The following prerequisites are based on:

  1. Release Notes provided by MuleSoft.
  2. Specifications of the host machine used to develop these scripts.

The software components below are requirements, they are needed. Other configurations/versions will most likely work with little to no modification.

The hardware specs and any versions should be viewed as guidelines and not requirements.

1) Hardware

Item Spec Notes
RAM (for the VM alone) 4GB Based on MuleSoft Release Notes.
CPU 2GHz Based on MuleSoft Release Notes.
Available Hard Drive 10GB Based on MuleSoft Release Notes.
OS Windows 7 Vagrant and VirtualBox supports many other Operating Systems.

2) Software

You need to install the following before getting started.

Technology Purpose Version Installation Instructions
Vagrant Portable Development Environments 2.0.2 Provided by Vagrant.
VirtualBox Virtual Machine Provider 5.1.22 Provided by VirtualBox.
Virtual Box Guest Additions Better performance and usability 0.15.1 Provided via Vagrant Plugin vagrant-vbguest.
From a command prompt run vagrant plugin install vagrant-vbguest

Create the Virtual Machine

The next few steps should be performed from the host (Windows) machine.

1) Verify Vagrant is properly installed

From a command prompt, run vagrant -v to see the version.

C:\>vagrant -v
Vagrant 2.0.2

2) Download (this) GIT repository

From a command prompt:

C:\Projects>git clone https://github.com/mbgiord/vagrant-mulesoft-devenv.git

3) Create and configure the VM using Vagrant

From a command prompt, navigate to the Vagrantfile and run vagrant up.

C:\Projects>cd vagrant-mulesoft-devenv
C:\Projects\vagrant-mulesoft-devenv>vagrant up
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Checking if box 'debian/jessie64' is up to date...

Depending on the speed of your machine and internet connection this might take a few minutes. Upon completion you should see:

==> default: If this is your first time running 'vagrant up' please run 'vagrant reload'. 
 
C:\Projects\vagrant-mulesoft-devenv>

If you did receive errors, fix them and rerun vagrant up. If you want to restart clean, run vagrant destroy first.

If you did not receive errors, run vagrant reload to restart the VM.

Upon completion you should be presented with a debian login screen.

Debian Login Screen Image

4) Smoke Test the VM

Login using the credentials vagrant/vagrant.
Launch a terminal via System Tools -> LXTerminal.

Debian Start Terminal Image

Running MuleSoft's "Hello World" Application

The following steps should be performed within the newly created virtual machine.

1) Download MuleSoft's Anypoint-Examples

From a terminal:

  • Clone the source code via GIT.
  • Nagivate to the anypoint-examples directory.
  • Checkout the 3.9 branch.

For example:

vagrant@jessie:~$ git clone https://github.com/mulesoft/anypoint-examples.git
Cloning into 'anypoint-examples'...
remote: Counting objects: 15992, done.
remote: Total 15992 (delta 0), reused 0 (delta 0), pack-reused 15992
Receiving objects: 100% (15992/15992), 3.27 MiB | 0 bytes/s, done.
Resolving deltas: 100% (9064/9064), done.
Checking connectivity... done.

vagrant@jessie:~$ cd anypoint-examples/

vagrant@jessie:~/anypoint-examples$ git checkout 3.9
Branch 3.9 set up to track remote branch 3.9 from origin.
Switched to a new branch '3.9'

2) Launch MuleSoft's Anypoint Studio

  • From the File Manager navigate to the /home/vagrant/AnypointStudio directory.
  • Double click AnypointStudio
  • Select the workspace /home/vagrant/AnypointStudio/workspace

Debian Start Anypoint Studio Image

3) Import Hello World Application into Anypoint Studio

  • Create project via File -> Import -> Maven-based Mule Project from pom.xml
  • Select pom file via /home/vagrant/anypoint-examples/hello-world/pom.xml
  • Accept the defaults and click Finish
  • Continue with the instructions found here... and good luck!

Debian Create Project Image

Next Steps

  • Run more examples. MuleSoft provides many sample projects for demonstration purposes.
  • Map a shared folder?

About

A Vagrantized MuleSoft Development Environment

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages