---
updatedAt: 2026-01-04T13:23:46.000Z
agentTools:
  siteIndex: https://docs.jfrog.com/llms.txt
  projectIndex: https://docs.jfrog.com/artifactory/llms.txt
---

# Vagrant Repositories

Vagrant is a tool for building and managing virtual machine environments in a single workflow, making it simple to create reproducible development environments. A Vagrant box is a packaged base image of an operating system ready to be cloned and configured. You can use Vagrant repositories in Artifactory to store private, customized boxes with all necessary software and security configurations pre-installed. For more information, see <Anchor label="Vagrant documentation" target="_blank" href="https://developer.hashicorp.com/vagrant/docs">Vagrant documentation</Anchor>.

<Image alt="vagrant_storage.png" border={false} src="https://files.readme.io/c6c232538cb1f0c511ae3aa6ec46cdd483f853dbfe37d15fdfeff6aa456b5608-uuid-137e9218-360a-8f73-621b-309d52263c92.png" />

Artifactory supports the following capabilities for Vagrant repositories:

* **Robust Metadata Capabilities**: Calculate metadata for Vagrant boxes hosted in Artifactory's local repositories.
* **Fine-Grained Access Control**: Extensive security features and flexible repository layouts allow you to assign access privileges according to project or development teams.
* **Centralized Storage and Management**: Use Artifactory as your source of truth and single location for distributing and sharing Vagrant boxes and other artifact and package types.

## Get Started with Vagrant

To get started working with Vagrant in Artifactory, complete the following main steps:

1. [Create a Vagrant Repository](#create-a-vagrant-repository)
2. [Connect Vagrant to Artifactory](#connect-vagrant-to-artifactory)
3. [Deploy](#deploy-vagrant-boxes) and [provision](#provision-vagrant-boxes) Vagrant boxes
   ![](https://files.readme.io/3c0f5e89d2fec8f08d30c9fbbdad30ddffd3a62f59121d67e317fe7c70e8f50b-uuid-0acd2220-b655-1c6d-77c2-240c22ebf4e4.png)

## Create a Vagrant Repository

This topic describes how to create a Vagrant repository. This is required before publishing and installing Vagrant boxes. Artifactory supports local Vagrant repositories, allowing you to store and share first- and second-party packages with your organization.

For more information on JFrog repositories, see [Repository Management](https://docs.jfrog.com/artifactory/docs/repository-management).

**Prerequisite**: You need Admin or Project Admin permissions in Artifactory to create a repository.

**To create a Vagrant repository**:

1. In the **Administration** tab, click **Repositories | Create a Repository**.

   <Image alt="CreateAnsibleLocal1.png" border={false} src="https://files.readme.io/831e939b2d050ab10d8a49327edaed6233d1c3ec63f44668b580e4dd59e8065a-uuid-4e754006-6b4a-217a-b03a-89facc6db079.png" />
2. Select **Local**.
3. Select the **Vagrant** package type.
4. In the **Repository Key** field, type a meaningful name for the repository. For example, `vagrant-local`. For more information on local repositories and their settings, see [Local Repositories](https://docs.jfrog.com/artifactory/docs/local-repositories).
5. Click **Create Repository**. The repository is created and the Repositories window is displayed.

## Connect Vagrant to Artifactory

If your Vagrant repository requires authentication, you need to set environment variables to connect your Vagrant client to Artifactory.

**Prerequisite**: Before connecting Vagrant to Artifactory, you must have an existing Vagrant repository in Artifactory. For more information, see [Create a Vagrant Repository](#create-a-vagrant-repository).

**Logged in vs. Anonymous User**: You can work with Vagrant and Artifactory as a logged-in user or anonymously. To work with Artifactory using Anonymous Access, configure that access under **Admin** | **Security** | **General**. For details, refer to [Allow Anonymous Access](/administration/docs/security-configuration).

**To connect Vagrant to Artifactory:**

Run the following commands to set the `ATLAS_TOKEN` and `VAGRANT_SERVER_URL` environment tokens:

```
export ATLAS_TOKEN=<AUTH>
export VAGRANT_SERVER_URL=https://[JFrogPlatformURL]/artifactory/api/vagrant/<REPO_NAME>
```

Where:

* `<AUTH>`: Your Artifactory identity token
* `[JFrogPlatformURL]`: The URL of your JPD
* `<REPO_NAME>`: The name of the target repository

For example:

```
export ATLAS_TOKEN=51HnvD0A1g2q3n4b5F6g7H8j9K0l1m2N3o4P5q6R7s8T9u0V1w2X3y4
export VAGRANT_SERVER_URL=https://company.jfrog.io/artifactory/api/vagrant/vagrant-local
```

<Callout icon="📘" theme="info">
  **Note**

  You can also use JFrog Set me up to copy the snippet populated with your token and environment. For more information, see [Use Artifactory Set Me Up for Configuring Package Manager Clients](https://docs.jfrog.com/artifactory/docs/use-artifactory-set-me-up-for-configuring-package-manager-clients).
</Callout>

**Next steps:**

* [Deploy Vagrant Boxes](#deploy-vagrant-boxes)
* [Provision Vagrant Boxes](#provision-vagrant-boxes)

## Deploy Vagrant Boxes

**To deploy Vagrant boxes:**

Run the following command:

```
curl -L -u<USERNAME>:<AUTH> -T <PATH_TO_FILE> "https://[JFrogPlatformURL]/artifactory/<REPO_NAME>/<BOX_PATH>;box_name=<NAME>;box_provider=<PROVIDER>;box_version=<VERSION>"
```

Where:

* `<USERNAME>`: Your Artifactory username
* `<AUTH>`: Your Artifactory identity token
* `<PATH_TO_FILE>`: The path to the `.box` file on your local machine
* `[JFrogPlatformURL]`: The URL of your JPD
* `<REPO_NAME>`: The name of the target repository
* `<BOX_PATH>`: The path to the `.box` file within the repository structure
* `<NAME>`: The name of the box
* `<PROVIDER>`: The Vagrant box provider. For more information, see <Anchor label="Providers" target="_blank" href="https://developer.hashicorp.com/vagrant/docs/providers">Providers</Anchor>
* `<VERSION>`: The Vagrant box version. For more information, see <Anchor label="Box Versioning" target="_blank" href="https://developer.hashicorp.com/vagrant/docs/boxes/versioning">Box Versioning</Anchor>

For example:

```
curl -L -ujeffry:51HnvD0A1g2q3n4b5F6g7H8j9K0l1m2N3o4P5q6R7s8T9u0V1w2X3y4 -T /home/jeffry/Downloads/precise64-virtualbox-1.0.0.box "https://company.jfrog.io/artifactory/vagrant-local/precise64-virtualbox-1.0.0.box;box_name=precise64;box_provider=virtualbox;box_version=1.0.0"
```

<Callout icon="📘" theme="info">
  **Note**

  You can also use JFrog Set me up to copy the snippet populated with your token and environment. For more information, see [Use Artifactory Set Me Up for Configuring Package Manager Clients](https://docs.jfrog.com/artifactory/docs/use-artifactory-set-me-up-for-configuring-package-manager-clients).
</Callout>

## Provision Vagrant Boxes

**To provision a Vagrant box**:

Run this command:

```
vagrant box add "https://[JFrogPlatformURL]/artifactory/api/vagrant/<REPO_NAME>/<BOX_NAME>"
```

Where:

* `[JFrogPlatformURL]`: The URL of your JPD
* `<REPO_NAME>`: The name of the repository where the box is located
* `<BOX_NAME>`: The name of the box you want to provision

For example:

```
vagrant box add "https://company.jfrog.io/artifactory/api/vagrant/vagrant-local/precise64"
```

<Callout icon="✅" theme="okay">
  **Tip**

  You can also use parameters like `--provider` and `--box-version`, or any custom properties you added, to identify a specific version. For more information, see [Using Properties in Deployment and Resolution](https://docs.jfrog.com/artifactory/docs/jfrog-properties#using-properties-in-deployment-and-resolution).
</Callout>

<Callout icon="📘" theme="info">
  **Note**

  You can also use JFrog Set me up to copy the snippet populated with your token and environment. For more information, see [Use Artifactory Set Me Up for Configuring Package Manager Clients](https://docs.jfrog.com/artifactory/docs/use-artifactory-set-me-up-for-configuring-package-manager-clients).
</Callout>

## Additional Vagrant Information

The following pages provide additional information about using Vagrant repositories in Artifactory:

* [Deploy a Vagrant Package Using the JFrog Platform WebUI](#deploy-a-vagrant-package-using-the-jfrog-platform-webui)
* [Set the Vagrant Target Path](#set-the-vagrant-target-path)

### Deploy a Vagrant Package Using the JFrog Platform WebUI

To deploy a Vagrant box to Artifactory:

1. In the **Application** module, under **Artifactory** | **Artifacts** select the repository to which you want to deploy your Vagrant box.
2. Click **Deploy**.

   <Image alt="deploy-button.png" border={false} src="https://files.readme.io/5742c10e8613661695d1fd35c18750fa290310ea996dc2d57401885092e1e769-uuid-ab1d0183-741b-baf4-7a19-a1bf8e74afb5.png" />
3. In the **Deploy** window, verify or provide fill in the required details and attach files for upload.

   <Image alt="deploy_vagrant.png" border={false} src="https://files.readme.io/f700c43b68e5f6b6ad0dfc2d915d5dd86bdf8c0cd390742d3d6cbfff95ecc40a-uuid-98a3d030-352d-16c3-32e1-57730bd465e3.png" />
4. For target path, enter any parameters you want to add to the box as properties. For example, to upload the box `precise64-virtualbox-1.0.0.box`, and specify its name as `precise64`, its provider as `virtualbox`, and its version as `1.0.0`, enter the following target path:

   ```
   /precise64-virtualbox-1.0.0.box;box_name=precise64;box_provider=virtualbox;box_version=1.0.0
   ```
5. Click **Deploy**.

### Set the Vagrant Target Path

When deploying a Vagrant box to Artifactory, you need to specify the target path. The target path can be anywhere in the repository, but it must contain at minimum these three mandatory properties:

* `box_name`: The name of the box
* `box_provider`: The box provider. For more information, see <Anchor label="Providers" target="_blank" href="https://developer.hashicorp.com/vagrant/docs/providers">Providers</Anchor> in the Vagrant documentation
* `box_version`: The box version. For more information, see <Anchor label="Box Versioning" target="_blank" href="https://developer.hashicorp.com/vagrant/docs/boxes/versioning">Box Versioning</Anchor> in the Vagrant documentation

Optionally, you can add additional properties as matrix parameters. For more information, see [JFrog Properties](https://docs.jfrog.com/artifactory/docs/jfrog-properties).