Skip to content

Instantly share code, notes, and snippets.

@patheard
Created September 15, 2019 17:32
Show Gist options
  • Save patheard/f6d0d79e5d6049554d6ae7e07e31f961 to your computer and use it in GitHub Desktop.
Save patheard/f6d0d79e5d6049554d6ae7e07e31f961 to your computer and use it in GitHub Desktop.
ubuntu/trusty64 with Docker
# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant.configure("2") do |config|
config.vm.box = "ubuntu/trusty64"
# Expose port 80 on guest vis port 8080 on host
config.vm.network "forwarded_port", guest: 80, host: 8080, host_ip: "127.0.0.1"
# Set guest IP address on host network
config.vm.network "private_network", ip: "192.168.10.101"
# Additional folders to sync between host and guest
config.vm.synced_folder "D:\\Development\\Projects\\DTF", "/home/vagrant/DTF"
# Config VM
config.vm.provider "virtualbox" do |vb|
vb.name = 'trusty-dev'
vb.memory = 4096
vb.cpus = 1
vb.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
vb.customize ["modifyvm", :id, "--natdnsproxy1", "on"]
end
# Install git
config.vm.provision "shell", inline: <<-SHELL
apt-get update
apt-get install -y git
SHELL
# Install Docker
config.vm.provision :docker
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment