maier / vagrant-alpine

Vagrant plugin for Alpine Linux Guest
MIT License
137 stars 10 forks source link
alpine alpine-linux-guest guest vagrant-plugin

Vagrant Alpine Linux Guest

Gem Version Build Status

This is a Vagrant plugin adding support for Alpine Linux guests.

NOTE: The vagrant-alpine plugin requires Vagrant 1.7+

This plugin is now part of Vagrant core as of Vagrant 2.2.6. It is recommended that you uninstall the vagrant-alpine plugin if you are using Vagrant 2.2.6 or above.

Features

Changes

Installation

$ vagrant plugin install vagrant-alpine

Usage

$ vagrant init maier/alpine-3.3.1-x86_64
$ vagrant up

or

$ vagrant init maier/alpine-3.2.3-x86_64
$ vagrant up

or

$ vagrant init maier/alpine-3.1.3-x86_64
$ vagrant up

Configuration

The vagrant-alpine plugin does not offer any configuration options.

Development

To work on the vagrant-alpine plugin, clone this repository, and use Bundler to get the dependencies:

$ gem install bundler -v '~> 1.7.0'
$ bundle install --path vendor/bundle

Once you have the dependencies, verify the unit tests pass with rake:

$ bundle exec rake

If those pass, you're ready to start developing. You can test the plugin without installing it into your Vagrant environment by creating a Vagrantfile in teh top level directory (it is gitignored). There is an example supplied in this repository. (cp Vagrantfile.example Vagrantfile and edit.)

Use bundler to execute Vagrant:

$ bundle exec vagrant up

Notes

Alpine Linux boxes for testing are available on Atlas. Packer templates for building the boxes are in this GitHub repository.

  1. (Atlas)[https://atlas.hashicorp.com/maier/boxes/alpine-3.1.3-x86_64] Alpine 3.1.3 box v1.3.0 is for VirtualBox v5, use box v1.2.0 for VirtualBox v4. The v1.2.0 (built with VirtualBox v4) has intermittent kernel panic when used with VirtualBox v5 and CPUs are set to > 1.
  2. Alpine 3.2.3 box (built with VirtualBox v5) is available on (Atlas)[https://atlas.hashicorp.com/maier/boxes/alpine-3.2.3-x86_64] now.

Using VAGRANT_LOG=info, Vagrant's --debug switch, and vb.gui = true were all very useful when originally developing this guest plugin.