» Cloud

Command: vagrant cloud

This is the command used to manage anything related to Vagrant Cloud.

The main functionality of this command is exposed via subcommands:

» Cloud Auth

Command: vagrant cloud auth

The cloud auth command is for handling all things related to authorization withVagrant Cloud.

» Cloud Auth Login

Command: vagrant cloud auth login

The login command is used to authenticate with HashiCorp's Vagrant Cloudserver. Logging in is only necessary if you are accessing protected boxes.

Logging in is not a requirement to use Vagrant. The vast majorityof Vagrant does not require a login. Only certain features such as protectedboxes.

The reference of available command-line flags to this commandis available below.

» Options

  • —check - This will check if you are logged in. In addition to outputtingwhether you are logged in or not, the command exit status will be 0 if you arelogged in, or 1 if you are not.

  • —logout - This will log you out if you are logged in. If you are alreadylogged out, this command will do nothing. It is not an error to call thiscommand if you are already logged out.

  • —token - This will set the Vagrant Cloud login token manually to the providedstring. It is assumed this token is a valid Vagrant Cloud access token.

» Examples

Securely authenticate to Vagrant Cloud using a username and password:

  1. $ vagrant cloud auth login
  2. # ...
  3. Vagrant Cloud username:
  4. Vagrant Cloud password:

Check if the current user is authenticated:

  1. $ vagrant cloud auth login --check
  2. You are already logged in.

Securely authenticate with Vagrant Cloud using a token:

  1. $ vagrant cloud auth login --token ABCD1234
  2. The token was successfully saved.

» Cloud Auth Logout

Command: vagrant cloud auth logout

This will log you out if you are logged in. If you are alreadylogged out, this command will do nothing. It is not an error to call thiscommand if you are already logged out.

» Cloud Auth Whomi

Command: vagrant cloud auth whoami [TOKEN]

This command will validate your Vagrant Cloud token and will print the user whoit belongs to. If a token is passed in, it will attempt to validate it insteadof the token stored stored on disk.

» Cloud Box

Command: vagrant cloud box

The cloud box command is used to manage life cycle operations for all boxentities on Vagrant Cloud.

» Cloud Box Create

Command: vagrant cloud box create ORGANIZATION/BOX-NAME

The box create command is used to create a new box entry on Vagrant Cloud.

» Options

» Cloud Box Delete

Command: vagrant cloud box delete ORGANIZATION/BOX-NAME

The box delete command will permanently delete the given box entry on Vagrant Cloud. Beforemaking the request, it will ask if you are sure you want to delete the box.

» Cloud Box Show

Command: vagrant cloud box show ORGANIZATION/BOX-NAME

The box show command will display information about the latest version for the given Vagrant box.

» Cloud Box Update

Command: vagrant cloud box update ORGANIZATION/BOX-NAME

The box update command will update an already created box on Vagrant Cloud with the given options.

» Options

» Cloud Provider

Command: vagrant cloud provider

The cloud provider command is used to manage the life cycle operations for allprovider entities on Vagrant Cloud.

» Cloud Provider Create

Command: vagrant cloud provider create ORGANIZATION/BOX-NAME PROVIDER-NAME VERSION [URL]

The provider create command is used to create a new provider entry on Vagrant Cloud.The url argument is expected to be a remote URL that Vagrant Cloud can useto download the provider. If no url is specified, the provider entry can be updatedlater with a url or the upload command can be used toupload a Vagrant box file.

» Cloud Provider Delete

Command: vagrant cloud provider delete ORGANIZATION/BOX-NAME PROVIDER-NAME VERSION

The provider delete command is used to delete a provider entry on Vagrant Cloud.Before making the request, it will ask if you are sure you want to delete the provider.

» Cloud Provider Update

Command: vagrant cloud provider update ORGANIZATION/BOX-NAME PROVIDER-NAME VERSION [URL]

The provider update command will update an already created provider for a box onVagrant Cloud with the given options.

» Cloud Provider Upload

Command: vagrant cloud provider upload ORGANIZATION/BOX-NAME PROVIDER-NAME VERSION BOX-FILE

The provider upload command will upload a Vagrant box file to Vagrant Cloud forthe specified version and provider.

» Cloud Publish

Command: vagrant cloud publish ORGANIZATION/BOX-NAME VERSION PROVIDER-NAME [PROVIDER-FILE]

The publish command is a complete solution for creating and updating aVagrant box on Vagrant Cloud. Instead of having to create each attribute of a Vagrantbox with separate commands, the publish command instead asks you to provide allthe information required before creating or updating a new box.

» Options

» Examples

Creating a new box on Vagrant Cloud:

  1. $ vagrant cloud publish briancain/supertest 1.0.0 virtualbox boxes/my/virtualbox.box -d "A really cool box to download and use" --version-description "A cool version" --release --short-description "Download me!"
  2. You are about to create a box on Vagrant Cloud with the following options:
  3. briancain/supertest (1.0.0) for virtualbox
  4. Automatic Release: true
  5. Box Description: A really cool box to download and use
  6. Box Short Description: Download me!
  7. Version Description: A cool version
  8. Do you wish to continue? [y/N] y
  9. Creating a box entry...
  10. Creating a version entry...
  11. Creating a provider entry...
  12. Uploading provider with file /Users/vagrant/boxes/my/virtualbox.box
  13. Releasing box...
  14. Complete! Published briancain/supertest
  15. tag: briancain/supertest
  16. username: briancain
  17. name: supertest
  18. private: false
  19. downloads: 0
  20. created_at: 2018-07-25T17:53:04.340Z
  21. updated_at: 2018-07-25T18:01:10.665Z
  22. short_description: Download me!
  23. description_markdown: A really cool box to download and use
  24. current_version: 1.0.0
  25. providers: virtualbox

» Cloud Search

Command: vagrant cloud search QUERY

The cloud search command will take a query and search Vagrant Cloud for any matchingVagrant boxes. Various filters can be applied to the results.

» Options

  • —json - Format search results in JSON.
  • —page PAGE - The page to display. Defaults to the first page of results.
  • —short - Shows a simple list of box names for the results.
  • —order ORDER - Order to display results. Can either be desc or asc.Defaults to desc.
  • —limit LIMIT - Max number of search results to display. Defaults to 25.
  • —provider PROVIDER - Filter search results to a single provider.
  • —sort-by SORT - The field to sort results on. Can be created, downloads, or updated. Defaults to downloads.

» Examples

If you are looking for a HashiCorp box:

  1. vagrant cloud search hashicorp --limit 5
  2. | NAME | VERSION | DOWNLOADS | PROVIDERS |
  3. +-------------------------+---------+-----------+---------------------------------+
  4. | hashicorp/precise64 | 1.1.0 | 6,675,725 | virtualbox,vmware_fusion,hyperv |
  5. | hashicorp/precise32 | 1.0.0 | 2,261,377 | virtualbox |
  6. | hashicorp/boot2docker | 1.7.8 | 59,284 | vmware_desktop,virtualbox |
  7. | hashicorp/connect-vm | 0.1.0 | 6,912 | vmware_desktop,virtualbox |
  8. | hashicorp/vagrant-share | 0.1.0 | 3,488 | vmware_desktop,virtualbox |
  9. +-------------------------+---------+-----------+---------------------------------+

» Cloud Version

Command: vagrant cloud version

The cloud version command is used to manage life cycle operations for all versionentities for a box on Vagrant Cloud.

» Cloud Version Create

Command: vagrant cloud version create ORGANIZATION/BOX-NAME VERSION

The cloud create command creates a version entry for a box on Vagrant Cloud.

» Options

» Cloud Version Delete

Command: vagrant cloud version delete ORGANIZATION/BOX-NAME VERSION

The cloud delete command deletes a version entry for a box on Vagrant Cloud.Before making the request, it will ask if you are sure you want to delete the version.

» Cloud Version Release

Command: vagrant cloud version release ORGANIZATION/BOX-NAME VERSION

The cloud release command releases a version entry for a box on Vagrant Cloudif it already exists. Before making the request, it will ask if you are sure youwant to release the version.

» Cloud Version Revoke

Command: vagrant cloud version revoke ORGANIZATION/BOX-NAME VERSION

The cloud revoke command revokes a version entry for a box on Vagrant Cloudif it already exists. Before making the request, it will ask if you are sure youwant to revoke the version.

» Cloud Version Update

Command: vagrant cloud version update ORGANIZATION/BOX-NAME VERSION

» Options