summaryrefslogtreecommitdiff
path: root/Vagrantfile
blob: e6699424f38ae5bd33c1d468b41be1fe6e42298c (plain)
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
# -*- mode: ruby -*-
# vi: set ft=ruby :

Vagrant.configure("2") do |box|
  # Please verify the sha512 sum of the downloaded box before importing it into vagrant !
  # see https://leap.se/en/docs/platform/details/development#Verify.vagrantbox.download
  # for details


  box.vm.define :"jessie", primary: true do |config|

    config.vm.box = "LEAP/jessie"
    config.vm.provider "virtualbox" do |v|
      v.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
      v.name   = "jessie"
      v.memory = 1024
    end

    config.vm.provider "libvirt" do |v|
      v.memory = 1024
    end

    config.vm.provision "puppet" do |puppet|
      puppet.manifests_path = "./vagrant"
      puppet.module_path = "./puppet/modules"
      puppet.manifest_file = "install-platform.pp"
      puppet.options = "--verbose"
    end
    config.vm.provision "shell", path: "vagrant/configure-leap.sh"
    config.ssh.username = "vagrant"

    # forward leap_web ports
    config.vm.network "forwarded_port", guest: 80,  host:8080
    config.vm.network "forwarded_port", guest: 443, host:4443
  end

  box.vm.define :"wheezy", autostart: false do |config|

    config.vm.box = "LEAP/wheezy"
    config.vm.provider "virtualbox" do |v|
      v.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
      v.name   = "wheezy"
      v.memory = 1024
    end

    config.vm.provider "libvirt" do |v|
      v.memory = 1024
    end

    config.vm.provision "puppet" do |puppet|
      puppet.manifests_path = "./vagrant"
      puppet.module_path = "./puppet/modules"
      puppet.manifest_file = "install-platform.pp"
      puppet.options = "--verbose"
    end
    config.vm.provision "shell", path: "vagrant/configure-leap.sh"
    config.ssh.username = "vagrant"

    # forward leap_web ports
    config.vm.network "forwarded_port", guest: 80,  host:8080
    config.vm.network "forwarded_port", guest: 443, host:4443
  end
end