Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Getting Started with Vagrant
Search
Erika Heidi
March 02, 2014
Programming
5
1.2k
Getting Started with Vagrant
Talk presented at DevFest Women in Istanbul #womentechmakers
Erika Heidi
March 02, 2014
Tweet
Share
More Decks by Erika Heidi
See All by Erika Heidi
FreeCAD 101 Lightning Talk
erikaheidi
0
24
Learning Lab: WordPress
erikaheidi
0
95
Criando Container Runtimes mais Seguras com Wolfi
erikaheidi
0
170
Introducing Chainguard Images for Safer PHP Runtimes
erikaheidi
0
210
Automatizando documentação em PHP com Autodocs
erikaheidi
0
150
Building the World: The Story Behind Wolfi
erikaheidi
0
760
Hello Wolfi
erikaheidi
1
760
Container Images for the Cloud Native Era
erikaheidi
1
410
Creating Secure Container Images with apko
erikaheidi
0
580
Other Decks in Programming
See All in Programming
Google Opalで使える37のライブラリ
mickey_kubo
3
160
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
370
What Spring Developers Should Know About Jakarta EE
ivargrimstad
0
580
AkarengaLT vol.38
hashimoto_kei
1
130
Blazing Fast UI Development with Compose Hot Reload (Bangladesh KUG, October 2025)
zsmb
2
400
3年ぶりにコードを書いた元CTOが Claude Codeと30分でMVPを作った話
maikokojima
0
690
開発組織の戦略的な役割と 設計スキル向上の効果
masuda220
PRO
10
1.8k
AI駆動で0→1をやって見えた光と伸びしろ
passion0102
1
880
contribution to astral-sh/uv
shunsock
0
560
TransformerからMCPまで(現代AIを理解するための羅針盤)
mickey_kubo
7
5.7k
コードとあなたと私の距離 / The Distance Between Code, You, and I
hiro_y
0
200
フロントエンド開発のためのブラウザ組み込みAI入門
masashi
7
3.6k
Featured
See All Featured
Done Done
chrislema
185
16k
Principles of Awesome APIs and How to Build Them.
keavy
127
17k
Building Applications with DynamoDB
mza
96
6.7k
Cheating the UX When There Is Nothing More to Optimize - PixelPioneers
stephaniewalter
285
14k
Mobile First: as difficult as doing things right
swwweet
225
10k
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
37
2.6k
Speed Design
sergeychernyshev
32
1.2k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
36
6.1k
Learning to Love Humans: Emotional Interface Design
aarron
274
41k
Typedesign – Prime Four
hannesfritz
42
2.8k
Improving Core Web Vitals using Speculation Rules API
sergeychernyshev
21
1.2k
Fashionably flexible responsive web design (full day workshop)
malarkey
407
66k
Transcript
None
whoami • Brazilian, living in Amsterdam since 2012 • PHP
<independent> developer, eventually sysadmin • Author of Vagrant Cookbook on LeanPub
What to expect from this talk • Introduction to Vagrant
– Terminology, basic usage • Provisioning – Choosing a Provisioner – Practical Example with Ansible • ProTips • Useful Resources
None
“It works on my machine” - every developer, ever
1.1 Why Vagrant • Reproducible and portable development environment •
Enables easier code collaboration • Backend env tests / benchmark • Automation Tools learning and testing
1.2 What you need (basic) • Vagrant [1.4.x] • VirtualBox
[4.3.x]
None
1.3 Terminology • Boxes • Host and Guest • Provider
• Provisioner • Synced Folder • Vagrantfile
1.4 Getting Started Vagrant.configure("2") do |config| config.vm.box = "precise64" config.vm.box_url
= "http://files.vagrantup.com/precise64.box" config.vm.provision "shell", inline: "echo hello, this is a simple Shell Provisioner!" end
Output
None
None
2.1 Shell x Automation Tools • Automation Tools have powerful
built-in features – Clear language – Idempotent State – Templating – Modularization
2.2 Automation Tools PUPPET CHEF ANSIBLE Syntax Custom based on
Ruby Ruby YAML Terminology Manifests / Modules Recipes / CookBooks Playbooks / Roles Exec. Order Not sequential Sequential Sequential Documentation Confusing Chaotic Excellent Popularity 1st 2nd 3rd Extra Requirements - - ansible Overall Learning Curve Moderate High Low
Pratical Example Nginx + PHP5: Ansible
Vagrantfile config.vm.provision "ansible" do |ansible| ansible.playbook = "playbook.yml" end
Playbook --- - hosts: all sudo: true tasks: - name:
Update apt apt: update_cache=yes - name: Install Nginx apt: pkg=nginx state=latest - name: Install PHP5-fpm apt: pkg=php5-fpm state=latest
Output
None
3.1 Installing Packages • Package managers are usually outdated –
Make SURE you run apt-get update first
3.2 Debugging • Unknown Vagrant error – Use VirtualBox /
Vmware GUI • Unknown Provisioner error – Increase provisioner verbosity • Not working as expected – Login, fix, automate
None
Vagrant Cookbook Special discount coupon for DevFest Women: http://leanpub.com/vagrantcookbook/c/devfestw
puphpet.com
phansible.com
Comparing Provisioners • Sandbox-PHP – Ansible, Puppet and Chef provisionings
– https://github.com/vagrantee/sandbox-php
@erikaheidi