Debian Codegraph @

benchmark/martinus/Vagrantfile

raw
1 # -*- mode: ruby -*-
2 # vi: set ft=ruby :
3
4 # All Vagrant configuration is done below. The "2" in Vagrant.configure
5 # configures the configuration version (we support older styles for
6 # backwards compatibility). Please don't change it unless you know what
7 # you're doing.
8 Vagrant.configure("2") do |config|
9 # The most common configuration options are documented and commented below.
10 # For a complete reference, please see the online documentation at
11 # https://docs.vagrantup.com.
12
13 # Every Vagrant development environment requires a box. You can search for
14 # boxes at https://atlas.hashicorp.com/search.
15 config.vm.box = "ubuntu/xenial64"
16 # sudo apt-get update
17 # sudo apt-get install -y build-essential
18 # sudo apt-get install -y cmake
19 # sudo apt-get install pkg-config zip g++ zlib1g-dev unzip python
20 # sudo apt-get install -y libboost1.55-dev
21 # wget https://github.com/bazelbuild/bazel/releases/download/0.22.0/bazel-0.22.0-installer-linux-x86_64.sh
22 # chmod +x ./bazel-0.22.0-installer-linux-x86_64.sh
23 # ./bazel-0.22.0-installer-linux-x86_64.sh
24 # ./bazel-bin/hashtable_benchmarks --benchmark_format=json > benchmark-results.json
25
26
27 # Disable automatic box update checking. If you disable this, then
28 # boxes will only be checked for updates when the user runs
29 # `vagrant box outdated`. This is not recommended.
30 # config.vm.box_check_update = false
31
32 # Create a forwarded port mapping which allows access to a specific port
33 # within the machine from a port on the host machine. In the example below,
34 # accessing "localhost:8080" will access port 80 on the guest machine.
35 # config.vm.network "forwarded_port", guest: 80, host: 8080
36
37 # Create a private network, which allows host-only access to the machine
38 # using a specific IP.
39 # config.vm.network "private_network", ip: "192.168.33.10"
40
41 # Create a public network, which generally matched to bridged network.
42 # Bridged networks make the machine appear as another physical device on
43 # your network.
44 # config.vm.network "public_network"
45
46 # Share an additional folder to the guest VM. The first argument is
47 # the path on the host to the actual folder. The second argument is
48 # the path on the guest to mount the folder. And the optional third
49 # argument is a set of non-required options.
50 # config.vm.synced_folder "../data", "/vagrant_data"
51
52 # Provider-specific configuration so you can fine-tune various
53 # backing providers for Vagrant. These expose provider-specific options.
54 # Example for VirtualBox:
55 #
56 config.vm.provider "virtualbox" do |vb|
57 vb.customize ["modifyvm", :id, "--cableconnected1", "on"]
58
59 # Display the VirtualBox GUI when booting the machine
60 vb.gui = false
61
62 # Customize the amount of memory on the VM:
63 vb.memory = "16384"
64 end
65 #
66 # Define a Vagrant Push strategy for pushing to Atlas. Other push strategies
67 # such as FTP and Heroku are also available. See the documentation at
68 # https://docs.vagrantup.com/v2/push/atlas.html for more information.
69 # config.push.define "atlas" do |push|
70 # push.app = "YOUR_ATLAS_USERNAME/YOUR_APPLICATION_NAME"
71 # end
72
73 # Enable provisioning with a shell script. Additional provisioners such as
74 # Puppet, Chef, Ansible, Salt, and Docker are also available. Please see the
75 # documentation for more information about their specific syntax and use.
76 config.vm.provision "shell", inline: <<-SHELL
77 sudo apt-get update
78 sudo apt-get install -y build-essential
79 sudo apt-get install -y cmake
80 sudo apt-get install -y ninja-build
81 sudo apt-get install -y pkg-config zip zlib1g-dev unzip python python-pip
82 # for folly
83 sudo apt-get install -y libboost-all-dev libevent-dev libdouble-conversion-dev \
84 libgoogle-glog-dev libgflags-dev libiberty-dev liblz4-dev liblzma-dev \
85 libsnappy-dev zlib1g-dev binutils-dev libjemalloc-dev libssl-dev pkg-config
86 sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test
87 sudo apt-get install -y python3 python3-pip
88 sudo apt-get update
89 sudo apt-get install -y gcc-8 g++-8
90 python3 -m pip install --upgrade pip
91 python3 -m pip install perf
92 cd /vagrant
93 git clone --recurse-submodules https://github.com/greg7mdp/map_benchmark.git
94 ./map_benchmark/tools/build.sh
95 sudo apt install -y ruby-full
96 SHELL
97 end