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
|
{
"variables": {
"iso_url": "https://downloads.archlinux.de/iso/2017.05.01/archlinux-2017.05.01-x86_64.iso",
"iso_checksum_type": "sha1",
"iso_checksum": "91a195bf1395694151fc3f7f766e9d1233e2aed9"
},
"builders": [
{
"type": "virtualbox-iso",
"boot_wait": "10s",
"http_directory": "http",
"disk_size": 20480,
"guest_os_type": "ArchLinux_64",
"iso_checksum": "{{user `iso_checksum`}}",
"iso_checksum_type": "{{user `iso_checksum_type`}}",
"iso_url": "{{user `iso_url`}}",
"ssh_username": "vagrant",
"ssh_password": "vagrant",
"ssh_port": 22,
"ssh_wait_timeout": "10000s",
"shutdown_command": "sudo systemctl poweroff",
"guest_additions_mode": "disable",
"vboxmanage": [
[
"modifyvm",
"{{.Name}}",
"--memory",
"1024"
],
[
"modifyvm",
"{{.Name}}",
"--cpus",
"2"
]
],
"boot_command": [
"<enter><wait10><wait10><wait10><wait10>",
"curl -O 'http://{{.HTTPIP}}:{{.HTTPPort}}/install{,-chroot}.sh'<enter><wait>",
"bash install.sh < install-chroot.sh && systemctl reboot<enter>"
]
}
],
"provisioners": [
{
"type": "shell",
"scripts": [
"provision/postinstall.sh",
"provision/virtualbox.sh",
"provision/cleanup.sh"
],
"execute_command": "echo 'vagrant'|sudo -S sh '{{.Path}}'"
}
],
"post-processors": [
{
"type": "vagrant",
"output": "Arch-Linux-x86_64-{{ .Provider }}-{{isotime \"1970-01-01\"}}.box"
}
]
}
|