-
Notifications
You must be signed in to change notification settings - Fork 2
/
virtualbox_ubuntu.json
98 lines (90 loc) · 3.4 KB
/
virtualbox_ubuntu.json
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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
{
"variables": {
"ssh_name": "ubuntu",
"ssh_pass": "hpccdemo",
"hostname": "hpcc-vm",
"vm_name": "Ubuntu-18",
"packer_type": "virtualbox-iso",
"image_format": "ova",
"guest_os_type": "Ubuntu_64",
"iso_url":"http://us.cdimage.ubuntu.com/releases/18.04/release/ubuntu-18.04.3-server-amd64.iso",
"iso_checksum":"cb7cd5a0c94899a04a536441c8b6d2bf",
"iso_checksum_type":"md5",
"cpu": "4",
"memory": "2048",
"disk_size" : "10000"
},
"builders": [{
"vm_name":"Ubuntu18",
"type": "virtualbox-iso",
"format": "{{ user `image_format`}}",
"guest_os_type": "{{ user `guest_os_type`}}",
"vboxmanage": [
["modifyvm", "{{.Name}}", "--memory", "{{user `memory`}}"],
["modifyvm", "{{.Name}}", "--cpus", "{{user `cpu`}}"],
["modifyvm", "{{.Name}}", "--rtcuseutc", "on"],
["modifyvm", "{{.Name}}", "--natpf1", "ssh, tcp,,2222,,22"],
["modifyvm", "{{.Name}}", "--natpf1", "tcp8002, tcp,,8002,,8002"],
["modifyvm", "{{.Name}}", "--natpf1", "tcp8010, tcp,,8010,,8010"],
["modifyvm", "{{.Name}}", "--natpf1", "tcp8015, tcp,,8015,,8015"],
["modifyvm", "{{.Name}}", "--natpf1", "tcp8050, tcp,,8050,,8050"]
],
"disk_size" : "{{user `disk_size`}}",
"iso_url": "{{ user `iso_url`}}",
"iso_checksum": "{{ user `iso_checksum`}}",
"iso_checksum_type": "{{ user `iso_checksum_type`}}",
"http_directory" : "../../tools/preseeds",
"http_port_min" : 9001,
"http_port_max" : 9001,
"ssh_username": "{{user `ssh_name`}}",
"ssh_password": "{{user `ssh_pass`}}",
"ssh_wait_timeout": "40m",
"shutdown_command": "echo {{user `ssh_pass`}} | sudo -S shutdown -P now",
"boot_command" : [
"<esc><esc><enter><wait>",
"/install/vmlinuz noapic ",
"preseed/url=http://{{ .HTTPIP }}:{{ .HTTPPort }}/preseed_ubuntu18.cfg ",
"debian-installer=en_US auto locale=en_US kbd-chooser/method=us ",
"hostname={{user `hostname`}} ",
"fb=false debconf/frontend=noninteractive ",
"keyboard-configuration/modelcode=SKIP keyboard-configuration/layout=USA ",
"keyboard-configuration/variant=USA console-setup/ask_detect=false ",
"initrd=/install/initrd.gz -- <enter>"
]
}],
"provisioners": [
{
"type":"file",
"source":"../../hpcc-systems/bionic/",
"destination":"/tmp/"
},
{
"type": "shell",
"inline": [
"sleep 15",
"sudo apt-get update -y",
"sudo apt-get -y install xterm",
"sudo apt-get -y install g++",
"sudo apt-get -y install expect",
"sudo apt-get -y install libapr1",
"sudo apt-get -y install python",
"sudo apt-get -y install libpython3.6",
"sudo apt-get -y install libpython2.7",
"sudo apt-get -y install curl",
"sudo apt-get -y install libaprutil1",
"sudo apt-get -y install libatlas3-base",
"sudo apt-get -y install libboost-system1.62.0",
"sudo apt-get -y install libmemcached11",
"sudo apt-get -y install libmemcachedutil2",
"sudo apt-get -y install libmysqlclient20",
"sudo apt-get -y install r-base-core",
"sudo apt-get -y install r-cran-rcpp",
"sudo apt-get -y install r-cran-inline",
"sudo apt-get -y install libv8-3.14.5",
"sudo apt-get -y install libboost-regex1.65.1",
"sudo apt-get -y install libcurl3-gnutls",
"sudo apt-get -y install libxslt1.1",
"sudo dpkg -i /tmp/*.deb"
]
}]
}