neilkidd / xubuntu-trusty-vagrant-environment

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

(X)Ubuntu Trusty Vagrant Environment

This repo is a vagrant vm container for (X)Ubuntu Trusty Dev Setup script development.

Introduction

I needed to create a set of scripts for fast and easy provisioning of a broad development environment.

I was inspired by the work from rails/rails-dev-box that uses Vagrant and Virtualbox (5) to achieve a rapidly, repeatable and disposable environment. Additionally, in theory, this should work from any host OS. I often find myself in both Windows ™ and Linux environments.

I already had a baseline xubuntu box hosted in Hashicorp's Atlas so "tying it all together" was natural progression.

Requirements

Usage

From a command line:

Login to Atlas , following the prompts.

$ vagrant login

Add the base box to your machine.

$ vagrant box add neil_kidd/xubuntu-14043-desktop

If you haven't already, clone this repo and cd into it.

$ git clone https://github.com/neilkidd/xubuntu-trusty-vagrant-environment.git
$ cd xubuntu-trusty-vagrant-environment

Clone the provisioning repo. ( Or create a fork 😄)

$ git clone https://github.com/neilkidd/xubuntu-trusty-dev-setup.git

Bring up the vm for the first time.
Important: '--no-provison' is required here as we intend to create an un-provisioned snapshot.

$ vagrant up --no-provision

Create a snapshot.

$ vagrant snapshot save clean_base

Excellent - we are now good to iterate. So stop the vm.

$ vagrant halt

Iterating

To bring up the vm with the shell provisioning specified in the Vagrantfile:

$ vagrant snapshot restore clean_base

From within your host, you can now edit the provisioning code as you wish and cleanly bring up the vm with the above command.

Cleaning Up

Issuing a $ vagrant destroy in the root directory will completely remove the local vm, along with any snapshots. This will not remove the base box from vagrant, so you may quickly start afresh.

Credits

License

Released under the MIT License, Copyright (c) 2016–ω Neil Kidd.

About

License:MIT License