vube/vagrant-boxer

Create re-usable base boxes for Vagrant

Installs: 210

Dependents: 0

Suggesters: 0

Security: 0

Stars: 19

Watchers: 3

Forks: 4

Open Issues: 0

Type:project

0.6.1 2015-03-10 23:25 UTC

This package is not auto-updated.

Last update: 2024-11-09 17:03:46 UTC


README

Build Status Coverage Status Latest Stable Version Dependency Status

Application to manage boxing up Vagrant VMs to be used as base boxes for use in private box distribution systems.

A complete example can be found here: vagrant-boxer-example

Features

  • Automatically package up Virtual Machines into reusable base boxes for use by other Vagrant configs.

  • Automatically create/update vagrant-catalog metadata.json files so you can run your own private internal Vagrant Cloud.

  • Automatically upload VM box images and metadata files to your file server.

Installation

To install, clone this repository and put it wherever you want it to live on your machine.

$ git clone https://github.com/vube/vagrant-boxer
$ cd vagrant-boxer
$ composer update

Then you can optionally symlink something like /usr/local/bin/boxer.php to this so it will run from your path just by typing boxer.php

$ sudo ln -sf /path/to/vagrant-boxer/boxer.php /usr/local/bin/boxer.php

Example Usage

vagrant-boxer works either from command line switches or using a boxer.json config file. Here are examples of both.

Usage via command line

Note that the {BASENAME} below should be substituted with the name of the VM in your VirtualBox list.

$ boxer.php --verbose --base "{BASENAME}" --boxer-id "your-company/{BASENAME}"  --major-version 1.0 --url-prefix "http://your-file-server.com/" --upload-base-uri "username@your-file-server.com:/path/to/docroot"

Note: If you don't have rsync on your system, you can set the --upload-method scp flags on the command line to use scp instead. You can pass any command here that takes arguments in the form command src1..srcN destination

Usage via boxer.json

Here again, {BASENAME} should be substituted with the name of the VM in your VirtualBox list.

Running boxer.php using boxer.json

$ boxer.php --verbose --config-file /path/to/boxer.json

Contents of boxer.json

{
    "vm-name": "{BASENAME}",
    "boxer-id": "your-company/{BASENAME}",
    "version": "1.0",
    "download-url-prefix": "http://your-file-server.com/",
    "upload-base-uri": "username@your-file-server.com:/path/to/docroot"
}

Dependencies

  • PHP 5.3.2+
  • Composer