This repository has been archived on 2025-01-19. You can view files and clone it, but cannot push or open issues or pull requests.
oliverdavies.uk-old-sculpin/source/_posts/2013-11-27-useful-vagrant-commands.md

26 lines
1.5 KiB
Markdown
Raw Normal View History

2015-03-16 21:18:03 +00:00
---
title: Useful Vagrant Commands
description: Here are the basic commands that you need to adminster a virtual machine using <a href="http://vagrantup.com" title="The Vagrant Home page">Vagrant</a>.
2015-03-17 04:04:02 +00:00
tags:
2015-06-14 02:27:41 +00:00
- vagrant
2016-12-29 16:32:52 +00:00
use: [posts]
2015-03-16 21:18:03 +00:00
---
2015-06-18 00:52:29 +00:00
{% block excerpt %}
[Vagrant](http://www.vagrantup.com "About Vagrant") is a tool for managing virtual machines within [VirtualBox](https://www.virtualbox.org) from the command line. Here are some useful commands to know when using Vagrant.
{% endblock %}
{% block content %}
2015-03-16 21:18:03 +00:00
Command | Description
:-|:-
vagrant init {box} | Initialise a new VM in the current working directory. Specify a box name, or "base" will be used by default.
vagrant status | Shows the status of the Vagrant box(es) within the current working directory tree.
vagrant up (--provision) | Boots the Vagrant box. Including "provision" also runs the "vagrant provision" command.
vagrant reload (--provision) | Reloads the Vagrant box. Including "--provision" also runs the "vagrant provision" command.
vagrant provision | Provision the Vagrant box using Puppet.
vagrant suspend | Suspend the Vagrant box. Use "vagrant up" to start the box again.
vagrant halt (-f) | Halt the Vagrant box. Use -f to forcefully shut down the box without prompting for confirmation.
vagrant destroy (-f) | Destroys a Vagrant box. Use -f to forcefully shut down the box without prompting for confirmation.
2015-06-14 02:27:41 +00:00
The full Vagrant documentation can be found at <http://docs.vagrantup.com/v2/>.
2015-06-18 00:52:29 +00:00
{% endblock %}