Book Image

Creating Development Environments with Vagrant

By : MICHAEL KEITH PEACOCK
Book Image

Creating Development Environments with Vagrant

By: MICHAEL KEITH PEACOCK

Overview of this book

Table of Contents (17 chapters)
Creating Development Environments with Vagrant Second Edition
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Managing Vagrant boxes


We can manage Vagrant boxes using the vagrant box command. Let's run this command with the help flag (--help) and see what subcommands are available:

vagrant box --help

Running this command gives the following result:

There are six available box-related subcommands. With each of these, we can provide the --help flag to see what additional arguments are available. The available box-related subcommands are:

  • add: This command adds a new box

  • list: This command lists all boxes installed

  • outdated: This command checks whether any boxes have updates available

  • remove: This command removes a box from the host

  • repackage: This command converts a Vagrant environment into a distributable box

  • update: This command will update the box being used by the current running Vagrant environment

Adding Vagrant boxes

The add subcommand allows us to add a new box. It takes a single argument and a number of optional flags. The argument is a name, URL, or path to a box file. If a name is provided...