Vagrant - Create Custom Virtual Machines for Web Development
4.3 (10 ratings)
Instead of using a simple lifetime average, Udemy calculates a course's star rating by considering a number of different factors such as the number of ratings, the age of ratings, and the likelihood of fraudulent ratings.
47 students enrolled
Wishlisted Wishlist

Please confirm that you want to add Vagrant - Create Custom Virtual Machines for Web Development to your Wishlist.

Add to Wishlist

Vagrant - Create Custom Virtual Machines for Web Development

using Vagrant and Virtualbox, ideal for PHP or other web projects
4.3 (10 ratings)
Instead of using a simple lifetime average, Udemy calculates a course's star rating by considering a number of different factors such as the number of ratings, the age of ratings, and the likelihood of fraudulent ratings.
47 students enrolled
Last updated 5/2017
Current price: $10 Original price: $95 Discount: 89% off
5 hours left at this price!
30-Day Money-Back Guarantee
  • 4.5 hours on-demand video
  • 4 Articles
  • Full lifetime access
  • Access on mobile and TV
  • Certificate of Completion
What Will I Learn?
  • Create custom development environments (Vagrant boxes) per project requirements.
View Curriculum
  • You should have a recent Windows or Mac computer, with enough CPU and memory
  • You should have a Administrator right for installing / configuring software
  • You should have a very good computer skills
  • Basic git skills are recommended

Welcome to this course where I you will teach how to create a custom development environment that fits your needs with Vagrant and Virtualbox.

My name is Valentine, I am a web developer , I have been working with Vagrant for some years now and I will be leading you through the course.

The problem

Before Vagrant was introduced, the preferred method of developing a web application was either by uploading files to a web server or by manually installing and configuring all the software needed locally on the development machine (usually Apache, MySQL, PHP) or using already packed and ready to use solutions such as XAMPP.

Unfortunately in the recent years the number of technologies used to create web applications has increased dramatically, having multiple relational and nonrelational databases (just to mention PostgreSQL, Redis, Cassandra), different web servers (Apache, Nginix), messaging queues (like RabbitMQ) or search platforms like Solr and much more. Not too mention all the different configurations.

Vagrant has emerged as part of the solution for this problem and together with Virtualbox has become the defacto standard for building local development environments. Now I cannot imagine doing it the “old way” anymore.

If you are currently using PHP, think for a second what it would mean for your current setup to use PHP7 instead of PHP 5.5? How about just editing a configuration file, typing a command and while automation does its work, you grab a cup of coffee and relax?


Vagrant brings the development environment setup time to a minimum, increases productivity and introduces the idea of disposable compute resources (similar to the cloud) but for desktop computers by encouraging the use of automation.

Even if your needs are not that complex (yet), you will still benefit from this course, by improving your workflow, learning more about Linux environments and maybe changing the way you see things.

Together we will install all the tools needed, understand their purpose and learn to maintain them but most valuably we will be creating custom configurations which fit you own needs using an online GUI.

The goal of this course is not to make you a Vagrant expert, but to give you enough information in order to feel comfortable working with Vagrant as a web developer. I will also try to keep you engaged with a lot of practical exercises and quizzes.

While this course uses examples with PHP and MySQL running on Linux, the principles explained here will apply to other languages such as Java, Python, Ruby or JavaScript.

Thank You
Feel free to look over the course description and I am looking forward to seeing you inside.

Who is the target audience?
  • Web developers who want to have a state of the art development environment.
  • Interest in virtualised enviroments
Students Who Viewed This Course Also Viewed
Curriculum For This Course
38 Lectures
Introduction to the Course
2 Lectures 08:58

In this lecture I will give a short introduction to the course, tell you how you can get the most out of it and will directly start by showing how it is possible to create a virtual machine and to install WordPress by investing just 2 minutes of work.

Preview 06:57

In this lecture we will look over the course objectives:

  • Get very familiar with Vagrant and Virtualbox by understanding what the tools do
  • Have an overview of what is possible with Vagrant
  • Understand the advantages and disadvantages of such a setup (virtual machines)
  • Create automatic, repeatable  development environments
  • Build the development box that you need

We will do a lot of exercises, to make sure that you learn as much as possible.

Course Objectives
Advantages and disadvantages of using virtual machines
3 Lectures 16:30

A virtual machine is a machine that sits on top of your own machine. The operating system has no idea that it is not working directly with a real computer.

What is a virtual machine anyway?

In this lecture you will lear the most important advantages of virtual machines (and disadvantages of (X)AMP solutions).


In this lecture we have a look at some of the disadvantages of using a virtual machine (VM).


Advantages and disadvantages of using virtual machines

Quiz - Advantages and disadvantages of using virtual machines
7 questions
Tools overview & Quick Installation
7 Lectures 44:06

In this lecture we will briefly introduce the tools that we will use throughout this course: Vagrant and Virtualbox, try to understand what each is doing and why we need them and after this proceed with the installation.

Virtualbox and Vagrant briefly explained

I will guide you in this lecture through the installation process for Windows. Together we will install Virtualbox, Vagrant, Git and a proper text editor, such as or Notepad++.

Installation for Windows

I will guide you in this lecture through the installation process for macOS. Together we will install Virtualbox, Vagrant and a proper text editor, such as

Installation for macOS

Additional Vagrant plugins needed

Briefly explaining that some examples might not work due to different configurations, software bugs etc.

Please do not hate me

This is the first exercise where we do an integration test between your computer, Vagrant and Virtualbox to see if all component work properly together. 

Exercise: Creating your first VM with Vagrant (OPTIONAL)

With this lecture we conclude this section. Any encountered problems while using Vagrant and Virtualbox are welcome. 

Installation Problems?
6 Lectures 37:15

This lecture will present the basics of working with the Virtualbox Manager, by creating, inspecting, editing and removing virtual machines.

Using Virtualbox

This lecture will discuss a couple of terms, such as machine, virtual machine, host OS, guest OS.


In this exercise we will install a virtual appliance in Virtualbox containing a Windows installation. Additionally working with snapshots and saving the current state will be presented as well.

Exercise: Running Internet Explorer version 8 on Windows 7 (OPTIONAL)

This lecture introduces VBoxManage, a CLI tool which can be used to control Virtualbox.

Short introduction to VBoxManage (OPTIONAL)

Updating and maintaining Virtualbox

Quiz - Virtualbox
2 questions

Learning more about Virtualbox
6 Lectures 56:06

This lecture introduces the most important command while dealing with the Vagrant command-line interface (Vagrant CLI). We will discuss vagrant status, up, halt, suspend/resume, version, reload.

Preview 19:59

Quiz - Interacting with the Virtual Machine
3 questions

This lecture will explain the Vagrantfile, which is a configuration file that instructs Vagrant how to create the virtual environment

The Vagrant File (and box)

Quiz - The Vagrant File
3 questions

This lecture will discuss the advantages and disadvantages of using shared folders with Vagrant.

Shared folders

In this lecture we will have a look at networking in Vagrant.

If you want to access with your browser the web server that is running on the virtual machine, you need to expose it to the outside world.

Vagrant offers 3 networking options to achieve that: forwarded ports, private networks and public networks.


In this lecture we will discuss the DOs and DONTs of sharing your VM. 

You can either share the Vagrantfile (preferably git) or repackage your virtual machine as a box.

Sharing your VM with others

In this lecture I will present some general advice regarding updating and maintaining Vagrant.

  • with vagrant status you can check if your installation is still up to date.

  • recommend making a note of your current version (Vagrant and/or Virtualbox)

  • needs to remain compatible with virtualbox

  • some boxes may get a newer version, so you may want to upgrade those as well.

Updating and maintaining
Provisioning basics
3 Lectures 28:05

This lecture will try to explain the meaning of the term "provisioning".

Automated provisioning shares many of the benefits: easy to use, repeating leads to the same result and brings the production configuration in sync with the development configuration.

What is provisioning?

This lecture will introduce you to shell scripts first, doing a basic example. If already familiar with shell scripting, this will give you the opportunity to see very fast some results. Shell scripts are easier to understand.

Provisioning using shell scripts (basic introduction)

This lecture will introduce and will demonstrate a simple provisioning example.

Provisioning using (basic introduction)

3 questions
Provisioning with puPHPet
8 Lectures 01:18:11

In this lecture I will introduce you to the section where we will create from scratch a custom virtual environment and automatically install Apache, MySQL, PHP and WordPress.


This lecture will discuss the available web servers (Ngnix and Apache) and the programming languages supported. 

Together we will install and configure Apache and PHP.

Web Servers and Languages

In this lecture we will install additional PHP modules and make some php.ini settings.

Fine-tuning PHP Settings

In this lecture we will discuss the available relational database engines and install MariaDB, a drop-in replacement for MySQL. 

Relational Databases

Using a custom bash script, in this lecture we will automatically install WordPress.

Custom Bash Scripts

In this lecture we are going to use version control (Git and Github), in order to keep track of the changes i the project.

Sharing your Project

In this lecture we will review the steps needed in order to maintain such a custom configuration on the long run.

Managing and Updating the Configuration

Sometimes things do not work as expected, so this is why it is important to know where to search for help. In this lecture we will do exactly that.

Getting Help
3 Lectures 01:03

Your Feedback

Introduce the private support group.

BONUS lecture
About the Instructor
Valentin-Andrei Despa
4.2 Average rating
16 Reviews
612 Students
3 Courses
​Enterprise Software Developer

Enterprise software developer with a strong background in computer science. 

I am a former member of the Joomla! CMS Bug Squad, Joomla! Stack Exchange moderator and current member in the TYPO3 CMS Security Team. As you can guess, I am dedicated software developer and open source lover.

I decided to join Udemy because of my desire to share my know-how in specific areas.