vagrant: update layout

This commit is contained in:
Rico Sta. Cruz 2017-10-18 20:33:52 +08:00
parent 2a13f9991c
commit 5db27db9dd
No known key found for this signature in database
GPG Key ID: CAAD38AE2962619A
2 changed files with 29 additions and 14 deletions

View File

@ -1,33 +1,44 @@
---
title: Vagrant
category: Devops
layout: 2017/sheet
intro: |
[Vagrant](http://vagrantup.com) lets you build isolated virtual environments for your apps.
---
### Get started
Add some base boxes:
{: .-setup}
$ vagrant box add precise32 http://files.vagrantup.com/precise32.box
$ vagrant box add precise64 http://files.vagrantup.com/precise64.box
```bash
vagrant box add precise64 http://files.vagrantup.com/precise64.box
```
Work it:
$ mkdir test_box
$ cd test_box
$ vagrant init precise64
```bash
mkdir test_box
cd test_box
vagrant init precise64
```
Run it:
$ vagrant up
$ vagrant ssh
```bash
vagrant up
vagrant ssh
```
To stop, use one of the following:
$ vagrant ssh # then: sudo shutdown -h now
$ vagrant suspend
$ vagrant destroy # !!
```bash
vagrant ssh # then: sudo shutdown -h now
vagrant suspend
vagrant destroy # !!
```
### Reference
* [Vagrant](http://vagrantup.com)
### Also see
* [Vagrant website](http://vagrantup.com) _(vagrantup.com)_
* [Vagrantfile cheatsheet](./vagrantfile)

View File

@ -1,8 +1,12 @@
---
title: Vagrantfile
category: Devops
layout: 2017/sheet
---
## Vagrantfile
{: .-one-column}
```rb
Vagrant.configure("2") do |config|
# All Vagrant configuration is done here. The most common configuration
@ -120,4 +124,4 @@ end
## Also see
* [Vagrant](vagrant.html)
* [Vagrant cheatsheet](./vagrant)