forked from crystal-lang/crystal
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Vagrantfile
26 lines (22 loc) · 943 Bytes
/
Vagrantfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant.configure("2") do |config|
%w(precise trusty vivid).product([32, 64]).each do |dist, bits|
box_name = "#{dist}#{bits}"
config.vm.define(box_name) { |c| c.vm.box = "ubuntu/#{box_name}" }
end
config.vm.provider "virtualbox" do |vb|
vb.memory = 4096
vb.cpus = 2
end
config.vm.provision :shell, inline: %(
curl -s http://dist.crystal-lang.org/apt/setup.sh | bash
apt-get install -y crystal git libgmp3-dev zlib1g-dev libedit-dev libxml2-dev libssl-dev libyaml-dev libreadline-dev
curl -s http://crystal-lang.s3.amazonaws.com/llvm/llvm-3.5.0-1-linux-`uname -m`.tar.gz | tar xz -C /opt
echo 'export LIBRARY_PATH="/opt/crystal/embedded/lib"' > /etc/profile.d/crystal.sh
echo 'export PATH="$PATH:/opt/llvm-3.5.0-1/bin"' >> /etc/profile.d/crystal.sh
)
config.vm.provision :shell, privileged: false, inline: %(
git clone /vagrant crystal
)
end