Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 42 additions & 2 deletions Vagrantfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
# vi: set ft=ruby :

# Config Github Settings
github_username = "fideloper"
github_username = "n3r0-ch"
github_repo = "Vaprobash"
github_branch = "1.4.1"
github_branch = "develop"
github_url = "https://raw.githubusercontent.com/#{github_username}/#{github_repo}/#{github_branch}"

# Because this:https://developer.github.com/changes/2014-12-08-removing-authorizations-token/
Expand Down Expand Up @@ -100,6 +100,8 @@ Vagrant.configure("2") do |config|
config.hostmanager.manage_host = true
config.hostmanager.ignore_private_ip = false
config.hostmanager.include_offline = false
else
warn "The recommeded plugin 'vagrant-hostmanager' is currently not installed. You can install it by executing: 'vagrant plugin install vagrant-hostmanager'"
end

# Create a hostname, don't forget to put it to the `hosts` file
Expand Down Expand Up @@ -141,10 +143,22 @@ Vagrant.configure("2") do |config|
# to sleep for instance, then some 3rd party services will reject requests.
vb.customize ["guestproperty", "set", :id, "/VirtualBox/GuestAdd/VBoxService/--timesync-set-threshold", 10000]

# Allow symlinks inside shared folders
vb.customize ["setextradata", :id, "VBoxInternal2/SharedFoldersEnableSymlinksCreate/v-root", "1"]

# Prevent VMs running on Ubuntu to lose internet connection
# vb.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
# vb.customize ["modifyvm", :id, "--natdnsproxy1", "on"]

# Automatically update VirtualBox Guest Additions
if Vagrant.has_plugin?("vagrant-vbguest")
# set auto_update to false, if you do NOT want to check the correct
# additions version when booting this machine
config.vbguest.auto_update = true
else
warn "The recommeded plugin 'vagrant-vbguest' is currently not installed. You can install it by executing: 'vagrant plugin install vagrant-vbguest'"
end

end

# If using VMWare Fusion
Expand All @@ -167,6 +181,8 @@ Vagrant.configure("2") do |config|
type: :nfs,
mount_options: ['rw', 'vers=3', 'tcp', 'nolock']
}
else
warn "The recommeded plugin 'vagrant-cachier' is currently not installed. You can install it by executing: 'vagrant plugin install vagrant-cachier'"
end

# Adding vagrant-digitalocean provider - https://github.com/smdahlen/vagrant-digitalocean
Expand Down Expand Up @@ -205,6 +221,10 @@ Vagrant.configure("2") do |config|
# Provision Docker
# config.vm.provision "shell", path: "#{github_url}/scripts/docker.sh", args: "permissions"

# Provision docker-compose
# config.vm.provision "shell", path: "#{github_url}/scripts/docker-compose.sh"


####
# Web Servers
##########
Expand Down Expand Up @@ -247,6 +267,7 @@ Vagrant.configure("2") do |config|
# Provision Neo4J
# config.vm.provision "shell", path: "#{github_url}/scripts/neo4j.sh"


####
# Search Servers
##########
Expand Down Expand Up @@ -304,6 +325,7 @@ Vagrant.configure("2") do |config|
# Install RabbitMQ
# config.vm.provision "shell", path: "#{github_url}/scripts/rabbitmq.sh", args: [rabbitmq_user, rabbitmq_password]


####
# Additional Languages
##########
Expand All @@ -317,6 +339,10 @@ Vagrant.configure("2") do |config|
# Install Go Version Manager (GVM)
# config.vm.provision "shell", path: "#{github_url}/scripts/go.sh", privileged: false, args: [go_version]

# Install Oracle Java 8
# config.vm.provision "shell", path: "#{github_url}/scripts/oracle-java.sh"


####
# Frameworks and Tooling
##########
Expand Down Expand Up @@ -346,11 +372,25 @@ Vagrant.configure("2") do |config|
# Install Android
# config.vm.provision "shell", path: "#{github_url}/scripts/android.sh"

# Install Maven
# config.vm.provision "shell", path: "#{github_url}/scripts/maven.sh"

# Install M4
# config.vm.provision "shell", path: "#{github_url}/scripts/m4.sh"

# Install Puppet Client
# config.vm.provision "shell", path: "#{github_url}/scripts/puppet-client.sh"

# Install wkhtml2pdf
# config.vm.provision "shell", path: "#{github_url}/scripts/wkhtmltopdf.sh"


####
# Local Scripts
# Any local scripts you may want to run post-provisioning.
# Add these to the same directory as the Vagrantfile.
##########
# config.vm.provision "shell", path: "./local-script.sh"


end
14 changes: 14 additions & 0 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ Here's a quickstart screencast!
* PHP MsSQL (ability to connect to SQL Server)
* Screen
* Docker
* docker-compose
* Web Servers
* Apache
* HHVM
Expand All @@ -101,6 +102,7 @@ Here's a quickstart screencast!
* Additional Languages
* NodeJS via NVM
* Ruby via RVM
* Orcale Java 8
* Frameworks / Tooling
* Composer
* Laravel
Expand All @@ -109,6 +111,10 @@ Here's a quickstart screencast!
* MailCatcher
* Ansible
* Android
* Maven
* M4
* Puppet Client
* wkhtmltopdf

## The Vagrantfile

Expand All @@ -132,6 +138,14 @@ The vagrant file does three things you should take note of:

Don't forget to reload your Vagrantfile running `vagrant reload --no-provision`, in case your virtual machine already exists.

## Recommended Plugins

For an optimal experience we are recommending the installation of the following Vagrant plugins:

* [vagrant-hostmanager](https://github.com/smdahlen/vagrant-hostmanager)
* [vagrant-cachier](https://github.com/fgrehm/vagrant-cachier)
* [vagrant-vbguest](https://github.com/dotless-de/vagrant-vbguest) (VirtualBox users only)

## Connecting to MySQL from Sequel Pro:

Change your IP address as needed. The default IP address is now `192.168.22.10`
Expand Down
15 changes: 14 additions & 1 deletion scripts/base.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ sudo apt-get update

# Install base packages
# -qq implies -y --force-yes
sudo apt-get install -qq curl unzip git-core ack-grep software-properties-common build-essential
sudo apt-get install -qq curl unzip git-core ack-grep software-properties-common build-essential telnet dnsutils


echo ">>> Installing *.xip.io self-signed SSL"
Expand Down Expand Up @@ -79,3 +79,16 @@ fi

# Enable case sensitivity
shopt -u nocasematch

# Edit MOTD
echo '
__ __ _ _
\ \ / / | | | |
\ \ / /_ _ _ __ _ __ ___ | |__ __ _ ___| |__
\ \/ / _ | _ \| __/ _ \| _ \ / _ / __| _ \
\ / (_| | |_) | | | (_) | |_) | (_| \__ \ | | |
\/ \__,_| .__/|_| \___/|_.__/ \__,_|___/_| |_|
| |
|_|

' > /etc/motd
7 changes: 7 additions & 0 deletions scripts/docker-compose.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/usr/bin/env bash

echo ">>> Installing docker-compose"

#Install docker-compose
curl -L -s https://github.com/docker/compose/releases/download/1.3.3/docker-compose-`uname -s`-`uname -m` > /usr/local/bin/docker-compose
chmod +x /usr/local/bin/docker-compose
6 changes: 6 additions & 0 deletions scripts/m4.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#!/usr/bin/env bash

echo ">>> Installing m4"

#Install maven
apt-get install -qq m4
6 changes: 6 additions & 0 deletions scripts/maven.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#!/usr/bin/env bash

echo ">>> Installing Maven"

# Install maven
apt-get install -qq maven
9 changes: 9 additions & 0 deletions scripts/oracle-java.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#!/usr/bin/env bash

echo ">>> Installing Oracle Java 8"

# Install Oracle Java 8
add-apt-repository ppa:webupd8team/java
apt-get update
echo oracle-java8-installer shared/accepted-oracle-license-v1-1 select true | /usr/bin/debconf-set-selections
apt-get install -qq oracle-java8-installer >> /dev/null 2>&1
2 changes: 1 addition & 1 deletion scripts/php.sh
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ else

# Install PHP
# -qq implies -y --force-yes
sudo apt-get install -qq php5-cli php5-fpm php5-mysql php5-pgsql php5-sqlite php5-curl php5-gd php5-gmp php5-mcrypt php5-memcached php5-imagick php5-intl php5-xdebug
sudo apt-get install -qq php5-cli php5-fpm php5-mysql php5-pgsql php5-sqlite php5-curl php5-gd php5-gmp php5-mcrypt php5-memcached php5-imagick php5-intl php5-xdebug php5-common php5-cgi php5-imap php5-ldap php5-json

# Set PHP FPM to listen on TCP instead of Socket
sudo sed -i "s/listen =.*/listen = 127.0.0.1:9000/" /etc/php5/fpm/pool.d/www.conf
Expand Down
13 changes: 13 additions & 0 deletions scripts/puppet-client.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/usr/bin/env bash

echo ">>> Installing Puppet Client"

#Add puppetlabs sources
cd ~; wget https://apt.puppetlabs.com/puppetlabs-release-trusty.deb
dpkg -i puppetlabs-release-trusty.deb
apt-get update
rm puppetlabs-release-trusty.deb

#Install puppet
#Puppet installation returns wrong error code
apt-get -qq install puppet || true
9 changes: 9 additions & 0 deletions scripts/wkhtmltopdf.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#!/usr/bin/env bash

echo ">>> Installing wkhtmltopdf"

# Installwkhtmltopdf
apt-get install -qq wkhtmltopdf xvfb xfonts-75dpi
wget http://download.gna.org/wkhtmltopdf/0.12/0.12.2.1/wkhtmltox-0.12.2.1_linux-trusty-amd64.deb
dpkg -i wkhtmltox-0.12.2.1_linux-trusty-amd64.deb
rm wkhtmltox-0.12.2.1_linux-trusty-amd64.deb