This repository contains Packer templates for creating Ubuntu Vagrant/Virtualbox boxes for use within Enterprise environment.
The packer build creates an Ubuntu Server/Desktop that comes built in with:
- An updated CA certificate authority based on the certificates provided in the
files/certificates
directory - CNTML installed with an automated configuration setup to inject username/password into the CNTLM configuration and inject the correct ENV variables into the setup
- Docker installed and verified
In order to build a VM using this process, you will need the following install on your computer:
1. An account with elevated privileges to install and run these applications
2. [VirtualBox](https://www.virtualbox.org/wiki/Downloads)
3. [CNTML](https://sourceforge.net/projects/cntlm/files/cntlm/)
4. [Packer](https://www.packer.io/downloads.html)
5. [PowerShell](https://github.com/PowerShell/PowerShell/releases)
The builds in this setup are optimized for Virtualbox - if you want to use one of the other available Packer builders, that is something you will need to sort out.
To build the VM (in powershell terminal):
# Setup the CNTLM proxy env for the packer build to use
$env:http_proxy="127.0.0.1:3128"
$env:https_proxy="127.0.0.1:3128"
# Run the packer process
packer build -only=virtualbox-iso -var-file=ubuntu1710.json ubuntu.json
The -var-file
is a file that contains variables specific to the build of ubuntu 17.10 while the ubuntu.json
file is a more generic build that can support multiple versions of ubuntu.
The VM that this build creates should be shared via uploading to a publicly available repository within your enterprise. This then provides all users within your company a common place to pull down the latest build of this environment for their own usage.
The templates respect the following network proxy environment variables and forward them on to the virtual machine environment during the box creation process, should you be using a proxy:
- http_proxy
- https_proxy
- ftp_proxy
- rsync_proxy
- no_proxy
Automated tests are written in goss - they are run in the custom script goss.sh
and the tests are defined in the files/goss base directory.
This repo is a heavily modified version of the https://github.com/boxcutter/ubuntu repository with a lot of the available customization ripped out.