SlideShare a Scribd company logo
1 of 10
Working with Vagrant in my 
WordPress development 
workflow 
James Bundey @jamesbundey 
Melbourne WordPress Developer Meetup November ‘14
What is Vagrant? 
Create and configure lightweight, reproducible, and 
portable development environments 
https://www.vagrantup.com
Why bother? 
• Simple to set-up 
• Enables you to easily recreate local development 
configurations 
• Enables easy and total management of each 
environments 
• Keeps development clean - run one set-up for 
WordPress projects another for another CMS 
• Take advantage of the open source configurations 
created by people far smarter than me.
Getting started 
1. Install Virtual Box - We need this to create the virtual machines 
that are going to house our development environments - 
https://www.virtualbox.org/wiki/Downloads 
2. Install Vagrant - https://www.vagrantup.com/downloads.html 
3. Install two extremely useful plugins via the command line 
• Vagrant Hostsupdater - enables you to access your 
development server via a web browser without additional 
configuration 
$ vagrant plugin install vagrant-hostsupdater 
• Vagrant Triggers - backs up and restores the database after 
every shutdown and boot up. 
$ vagrant plugin install vagrant-triggers
Vagrant & WordPress configuration 
• Once Vagrant is set-up we need to create a configuration file to set-up 
the development environment 
• Thankfully there’s lots already out there - here’s a great overview of some 
http://wptavern.com/13-vagrant-resources-for-wordpress-development 
• I’m using Varying Vagrant Vagrants - https://github.com/Varying-Vagrant- 
Vagrants/VVV 
• To set-up our WordPress environment, we simply git clone VVV to a 
folder and run 
cd ~/new-folder 
vagrant up 
• Sit back and grab a cup of tea (I am british after all) while it works its 
magic
Vagrant & WordPress 
• Once completed you’ll have four WordPress site 
configurations installed in the www folder 
• WordPress Stable: local.wordpress.dev (typically what I’m going to use) 
• WordPress Trunk:local.wordpress-trunk.dev 
• WordPress Develop: src.wordpress-develop.dev & build.wordpress-develop.dev 
• You can now access & freely develop as required - 
http://local.wordpress.dev 
• To access phpMyAdmin - http://vvv.dev/database-admin/
Some useful extensions 
• VVV Site Wizard - saves time by enabling you to easily 
create additional WordPress installs. The wizard guides 
you through the set-up & creates the database, host 
names etc - https://github.com/aliso/vvv-site-wizard 
• VVV Dashboard - creates a dashboard that can be 
viewed in the browser, that enables you to easily view 
and manage all your installs 
• Vagant Manager - OSX app for managing Vagrant 
installs - http://www.vagrantmanager.com
Integrating with my workflow 
1. Using the VVV wizard I create a new install on the same 
server - standard install 
2. I store the plugins that I use 99.9% of the time in all 
projects in a Git repository, which I clone to the wp-content 
folder 
3. I clone my framework, to the themes folder as my base 
4. I then remove the .git file as I will be creating a new repo 
to host this theme 
5. I install my Bower & Grunt dependencies and start 
developing
Any problems 
• So far none. I’ve found it extremely useful to set-up and 
much quicker than Mamp Pro 
• Highly recommend the app, as it makes things easy 
• Keeping each environment separate has been a bonus 
and for those using other CMS there are very similar 
configuration files. 
• Experimented with sharing the environment across 
multiple machines using Dropbox and sym links, with 
mixed success.
Questions? 
Connect with me 
@jamesbundey 
www.linkedin.com/in/jamesbundey

More Related Content

Recently uploaded

Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
vu2urc
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 

Recently uploaded (20)

Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 

Featured

How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
ThinkNow
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
Kurio // The Social Media Age(ncy)
 

Featured (20)

How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
 
12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work
 
ChatGPT webinar slides
ChatGPT webinar slidesChatGPT webinar slides
ChatGPT webinar slides
 

Introduction to Vagrant & using it for WordPress development

  • 1. Working with Vagrant in my WordPress development workflow James Bundey @jamesbundey Melbourne WordPress Developer Meetup November ‘14
  • 2. What is Vagrant? Create and configure lightweight, reproducible, and portable development environments https://www.vagrantup.com
  • 3. Why bother? • Simple to set-up • Enables you to easily recreate local development configurations • Enables easy and total management of each environments • Keeps development clean - run one set-up for WordPress projects another for another CMS • Take advantage of the open source configurations created by people far smarter than me.
  • 4. Getting started 1. Install Virtual Box - We need this to create the virtual machines that are going to house our development environments - https://www.virtualbox.org/wiki/Downloads 2. Install Vagrant - https://www.vagrantup.com/downloads.html 3. Install two extremely useful plugins via the command line • Vagrant Hostsupdater - enables you to access your development server via a web browser without additional configuration $ vagrant plugin install vagrant-hostsupdater • Vagrant Triggers - backs up and restores the database after every shutdown and boot up. $ vagrant plugin install vagrant-triggers
  • 5. Vagrant & WordPress configuration • Once Vagrant is set-up we need to create a configuration file to set-up the development environment • Thankfully there’s lots already out there - here’s a great overview of some http://wptavern.com/13-vagrant-resources-for-wordpress-development • I’m using Varying Vagrant Vagrants - https://github.com/Varying-Vagrant- Vagrants/VVV • To set-up our WordPress environment, we simply git clone VVV to a folder and run cd ~/new-folder vagrant up • Sit back and grab a cup of tea (I am british after all) while it works its magic
  • 6. Vagrant & WordPress • Once completed you’ll have four WordPress site configurations installed in the www folder • WordPress Stable: local.wordpress.dev (typically what I’m going to use) • WordPress Trunk:local.wordpress-trunk.dev • WordPress Develop: src.wordpress-develop.dev & build.wordpress-develop.dev • You can now access & freely develop as required - http://local.wordpress.dev • To access phpMyAdmin - http://vvv.dev/database-admin/
  • 7. Some useful extensions • VVV Site Wizard - saves time by enabling you to easily create additional WordPress installs. The wizard guides you through the set-up & creates the database, host names etc - https://github.com/aliso/vvv-site-wizard • VVV Dashboard - creates a dashboard that can be viewed in the browser, that enables you to easily view and manage all your installs • Vagant Manager - OSX app for managing Vagrant installs - http://www.vagrantmanager.com
  • 8. Integrating with my workflow 1. Using the VVV wizard I create a new install on the same server - standard install 2. I store the plugins that I use 99.9% of the time in all projects in a Git repository, which I clone to the wp-content folder 3. I clone my framework, to the themes folder as my base 4. I then remove the .git file as I will be creating a new repo to host this theme 5. I install my Bower & Grunt dependencies and start developing
  • 9. Any problems • So far none. I’ve found it extremely useful to set-up and much quicker than Mamp Pro • Highly recommend the app, as it makes things easy • Keeping each environment separate has been a bonus and for those using other CMS there are very similar configuration files. • Experimented with sharing the environment across multiple machines using Dropbox and sym links, with mixed success.
  • 10. Questions? Connect with me @jamesbundey www.linkedin.com/in/jamesbundey