Skip to content

Instantly share code, notes, and snippets.

@csarcom
Created July 11, 2014 18:07
Show Gist options
  • Save csarcom/10e1585d402a77fbcc2e to your computer and use it in GitHub Desktop.
Save csarcom/10e1585d402a77fbcc2e to your computer and use it in GitHub Desktop.
vagrantfile
# -*- mode: ruby -*-
# vi: set ft=ruby :
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing!
VAGRANTFILE_API_VERSION = "2"
$script = <<SCRIPT
echo I am provisioning...
echo Installing EPEL packages...
su -c 'rpm -Uvh http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm'
yum install -y python-devel python-pip python-virtualenv python-virtualenvwrapper gcc gcc-c++ postfix erlang
su -c 'rpm -Uvh http://www.rabbitmq.com/releases/rabbitmq-server/v3.3.4/rabbitmq-server-3.3.4-1.noarch.rpm'
gem install sass --version 3.2.14
gem install compass --version 0.12.2
iptables --flush
service iptables save
sudo chkconfig rabbitmq-server on
SCRIPT
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.box = "centos6.4"
config.vm.box_url = "http://developer.nrel.gov/downloads/vagrant-boxes/CentOS-6.4-x86_64-v20130731.box"
config.vm.network :forwarded_port, guest: 8080, host: 8080
config.vm.network :forwarded_port, guest: 9090, host: 9090
config.vm.network :private_network, ip: "192.168.33.15"
config.vm.synced_folder ".", "/vagrant", type: "nfs"
config.vm.provision "shell", inline: $script
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment