forked from karamanolev/WhatManager2
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Vagrantfile
28 lines (21 loc) · 1021 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
27
28
# -*- mode: ruby -*-
# vi: set ft=ruby :
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing!
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.box = "https://cloud-images.ubuntu.com/vagrant/trusty/current/trusty-server-cloudimg-i386-vagrant-disk1.box"
config.vm.network "forwarded_port", guest: 80, host: 8080
config.vm.network "private_network", ip: "192.168.33.10"
# config.vm.synced_folder "../data", "/vagrant_data"
end
# What Manager 2 setup
$script = <<SCRIPT
sudo apt-get update
sudo debconf-set-selections <<< 'mysql-server mysql-server/root_password password vagrant'
sudo debconf-set-selections <<< 'mysql-server mysql-server/root_password_again password vagrant'
sudo apt-get -y install mysql-server git apache2
mysql --user=root --password=vagrant -e 'CREATE DATABASE what_manager2 COLLATE utf8_unicode_ci;'
SCRIPT
Vagrant.configure("2") do |config|
config.vm.provision "shell", inline: $script, privileged: false
end